29.09.2011, 16:28
pawn Code:
//Global - On top of script
new VIP_CAR1;
//GameModeInit
VIP_CAR1 = AddStaticVehicle(561,2170.4277,1973.5856,10.6340,88.5622,1,255);
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(newstate == PLAYER_STATE_DRIVER && GetPlayerVehicleID(playerid) == VIP_CAR1)
{
if(pInfo[playerid][VIPLevel] < 2)
{
SendClientMessage(playerid, 0xFF0000FF, "You need to be VIP Member (Level 2) to use this vehicle.");
RemovePlayerFromVehicle(playerid);
}
}
return 1;
}
Sorry for the bad indentation, can't be bothered about that right now.