Jump command
#1

Hi, i am trying to make a jump command but eacht time i compile it says something about the facing angle.. what is the problem ?
Код:
	// Jump
	if (strcmp("/jump", cmdtext, true, 10) == 0)
		{
				if(IsPlayerInAnyVehicle(playerid)) {
  				new Float:X;
					new Float:Y;
					new Float:Z;
				  new VehicleID;
				  GetPlayerPos(playerid, X, Y, Z);
				  VehicleID = GetPlayerVehicleID(playerid);
					SetVehiclePos(VehicleID, X, Y, Z + 800.00);
					SetPlayerFacingAngle(playerid,Ang);
					GivePlayerWeapon(playerid,46,1);
					}
				 	else
					{
					new Float:X;
					new Float:Y;
					new Float:Z;
					GetPlayerPos(playerid, X, Y, Z);
					SetPlayerPos(playerid, X, Y, Z + 800.00);
					SetPlayerFacingAngle(playerid,Ang);
					GivePlayerWeapon(playerid,46,1);
					GameTextForPlayer(playerid, "~w~Cya !",8000,5);
 				 	}
				return 1;
Error:
Код:
Untitled.pwn(153) : error 017: undefined symbol "Ang"
Untitled.pwn(163) : error 017: undefined symbol "Ang"
Thanks !
Reply
#2

add

pawn Код:
new Float:Ang;
GetPlayerFacingAngle(playerid,Ang);
Reply
#3

Yay it works ^^ thanks (:
Reply
#4

You could do it with less lines.. :S,
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)