Moving cameras problem. - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Moving cameras problem. (
/showthread.php?tid=189192)
Moving cameras problem[calculation help please] -
0ne - 10.11.2010
Problem SOLVED
Re: Moving cameras problem. -
smeti - 10.11.2010
Try:
pawn Код:
new Float:camera_x = -2007.9738;
new Float:camera_y = -320.7323;
new Float:camera_z = 82.7880;
new Float:camera_x2 = -2002.2924;
new Float:camera_y2 = 1120.0116;
new Float:camera_z2 = 82.7880;
public OnPlayerConnect(playerid)
{
SetPlayerCameraPos(playerid, camera_x - 5 * floatsin(-camera_x2, degrees), camera_y - 15 * floatcos(-camera_y2, degrees), camera_z + 6);
SetPlayerCameraLookAt(playerid, camera_x2, camera_y2, camera_z2 + 0.5);
return 1;
}
Or,
delete -
Код:
SetPlayerCameraPos(playerid, camera_x - 5 * floatsin(-camera_x2, degrees), camera_y - 15 * floatcos(-camera_y2, degrees), camera_z + 6);
Quote:
This is the code that the compiler will see and convert into the AMX file. This is a purely text based replacement. All macros are of the form:
Код:
#define <search string><space(s)><replacement>
|
https://sampforum.blast.hk/showthread.php?tid=166680
Re: Moving cameras problem. -
0ne - 10.11.2010
Camera stands still, doesn't move. I put on a timer but still
Re: Moving cameras problem. -
0ne - 11.11.2010
Help please, maybe the calculation is wrong or smth? I think i need to increase x,y at the timer but have no idea how