Help with "camera" and character movement.

So, I am working on a pseudo 3d scrolling beat em up much like double dragon. also like castle crashers though. I have used the egg breaker example code to get a basic “camera” working so that the character appears to be running along on my map. The issue I’m having that at certain points I stop tracking the player and allow him to move freely around the screen and fend off waves of enemies.
This all works, but what I’m having an issue with is that if all the enemies die and the player starts to move, the map is JERKED to him and he is put in the middle. So I guess, my question to all of you. Is there anyway I can find the center X point at all times, to use in my stage moving code. I have attempted several different things to no avail, the best thing I have done is used a transition.to to try and ease the camera jerk as he is “re-tracked” by my map movement.
I would love to be able to do something like screenH*0.5; , but I can’t, seeing how my players X climbs into the 1000s as well as my map moves into the -1000s, the center of the screen is never really "screenW*0.5; cause that just gives me 512 in every case. So, you math guru’s, any idea how I could maintain a smooth camera AFTER allowing the player to move freely amongst the screen? [import]uid: 120372 topic_id: 31041 reply_id: 331041[/import]