SA-MP Forums Archive
InterpolateCameraLookAt - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: InterpolateCameraLookAt (/showthread.php?tid=615610)



InterpolateCameraLookAt - MerryDeer - 24.08.2016

Hi,

How to change camera angle? i set InterpolateCameraLookAt coordinates same as InterpolateCameraPos, but camera view is not in that side what to do?


Re: InterpolateCameraLookAt - SickAttack - 24.08.2016

You can use this filterscript: https://sampforum.blast.hk/showthread.php?tid=330879


Re: InterpolateCameraLookAt - MerryDeer - 24.08.2016

But that coordinates is using getplayerpos and getxyinfrontofplayer ..


Re: InterpolateCameraLookAt - SickAttack - 24.08.2016

No, it doesn't use those functions. It uses the interpolate functions. Projects go into scriptfiles.


Re: InterpolateCameraLookAt - MerryDeer - 24.08.2016

I mean that i'am in server getting player pos calculating xyinfront and setcamerapos using that, too i need calculate lookat to look straight player facing angle.


Re: InterpolateCameraLookAt - AbyssMorgan - 24.08.2016

PHP код:
GetPointInFrontOfCamera3D(playerid,&Float:tx,&Float:ty,&Float:tz,Float:radius,&Float:rx=0.0,&Float:rz=0.0); 
3DTryg:
https://sampforum.blast.hk/showthread.php?tid=591010

Example:
PHP код:
new Float:tx,Float:ty,Float:tz;
GetPointInFrontOfCamera3D(playerid,tx,ty,tz5.0); //5 meters
SetPlayerCameraLookAt(playerid,tx,ty,tz,CAMERA_CUT); 



Re: InterpolateCameraLookAt - SickAttack - 24.08.2016

Interpolate functions are to move the camera to one point to another.


Re: InterpolateCameraLookAt - MerryDeer - 24.08.2016




Re: InterpolateCameraLookAt - Threshold - 25.08.2016

Are your InterpolateCameraPos and InterpolateCameraLookAt final coordinates the same? Because your LookAt function should be the coordinates of where you 'want' the camera to be looking when it finishes moving. You've probably set the coordinates wrong for the LookAt function. Try moving the LookAt coordinates 100 units further ahead.