Entering Rc vehicles
#1

Код:
public enterrc (playerid,vehicleid)
{
	new Float:vehx, Float:vehy, Float:vehz;
	GetVehiclePos(vehicleid, vehx, vehy, vehz);
	if(IsPlayerInRangeOfPoint(playerid, 5, vehx, vehy, vehz))
	{
		if(GetVehicleModel(vehicleid) == 464 | 465 | 501 | 564 | 594)
		{
			GetPlayerVehicleSeat(playerid);
   			PutPlayerInVehicle(playerid, vehicleid, 0);
			return 1;
		}
		else return 0;
	}
	else return 0;
}
The scriptpiece above is for entering RC vehicles when you hit enter vehicle button..
What did i do wrong?
Here is the other part:
Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
	if (PRESSED( KEY_SECONDARY_ATTACK ))
	{
		SetTimer("enterrc",0,0);
	}
}
I dont get errors when i compile, but when i go close to an Rc vehicle and click the enter button nothing happens.
Reply


Messages In This Thread
Entering Rc vehicles - by RedFusion - 26.08.2010, 19:26
Re: Entering Rc vehicles - by ScottCFR - 26.08.2010, 19:43
Re: Entering Rc vehicles - by RedFusion - 26.08.2010, 19:46
Re: Entering Rc vehicles - by RedFusion - 27.08.2010, 14:24
Re: Entering Rc vehicles - by RedFusion - 27.08.2010, 16:27
Re: Entering Rc vehicles - by WillyP - 27.08.2010, 16:37
Re: Entering Rc vehicles - by Hiddos - 27.08.2010, 16:42
Re: Entering Rc vehicles - by Mean - 27.08.2010, 18:58
Re: Entering Rc vehicles - by RedFusion - 27.08.2010, 23:10

Forum Jump:


Users browsing this thread: 3 Guest(s)