camera turning strange

Posted By: Progger

camera turning strange - 12/17/10 21:41

Hi Community i have a big problem using this code

Code:
function handle_camera() 
{	

   
	camera.pan += (my.pan - camera.pan) * time_step * smooth_;
	camera.tilt += (my.tilt - camera.tilt) * time_step * smooth_;
	camera.roll += ((my.roll - camera.roll)/2) * time_step * smooth_;
	camera.x = my.x + fcos((camera.pan),fcos(camera.tilt,-50));
	camera.y = my.y + fsin((camera.pan),fcos(camera.tilt,-50));
	camera.z = my.z+2.5 + fsin(camera.tilt,-500);	
}




when i use this in my multiplayer game everything is fine if you use the server but if i choose a client the camera is turning bad why is it so im using this in both exactly the same code
IF someone has a solution it would be great because i really need to know why it is so laugh
THanks for rading and for ur help laugh
WFG Progger
Posted By: Pappenheimer

Re: camera turning strange - 12/18/10 11:14

Maybe, you need a different VIEW (for each client?).
While 'player' is the "Global pointer to the player entity on the current machine."[from the manual], camera doesn't get such a definition...
© 2024 lite-C Forums