OnPlayerEnterVehicle
#1

How to make when player enter in the gsf vehicle to say "You Dont Have Keys from this vehicle" i make something but didnt work look what i made


Код:
new gsf1
gsf = AddStaticVehicle(Co-ordinates bla bla....)
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
	new name[MAX_PLAYER_NAME];
	GetPlayerName(playerid,name,sizeof(name));
	new vehicle;
	vehicle = GetPlayerVehicleID(playerid);
	if(vehicle == gsf1)
	{
		if(!strcmp(name, "gsf1", false, 0))
		{
		  SendClientMessage(playerid,COLOR_WHITE, "You Dont Have Key from this vehicle.");
		}
	}
Reply
#2

pawn Код:
if(GetVehicleModel(GetPlayerVehicleID(playerid)) == vehicleid)   //change vehicle id
     {
         SendClientMessage(playerid, Property, "You Dont Have Key for this vehicle.");
     }
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)