[Help]Angle
#4

When you are in a vehicle, you should use
pawn Код:
GetVehicleZAngle(vehicleid);
When you are on foot you should use
pawn Код:
GetPlayerFacingAngle(playerid);
If you are wanting to get the opposite facing angle (such as behind you or to your side) you can always use simple math:
pawn Код:
new Float:angle = GetPlayerFacingAngle(playerid)-90.0;
It is important to note that when you get these values they are placed as a float, so you should use them when appropriate. If you need/want to make them an integer use
pawn Код:
floatround(angle); //Or whatever float variable you want to be made into an integer
Reply


Messages In This Thread
[Help]Angle - by PowerF - 13.06.2014, 06:08
Re: [Help]Angle - by Mriss - 13.06.2014, 06:10
Re: [Help]Angle - by Lynn - 13.06.2014, 06:11
Re: [Help]Angle - by nmader - 13.06.2014, 06:17

Forum Jump:


Users browsing this thread: 1 Guest(s)