Car lock [NOTOK] =D
#2

i check about the team, but by name i make some changes to this...


first i define a red color...

Код:
#define COLOR_RED 0xAA3333AA
and on callback OnPlayerStateChange you put..
Код:
public OnPlayerStateChange(playerid,newstate,oldstate)
 {
   if(newstate==PLAYER_STATE_DRIVER)
    {
      new name;
	  GetPlayerName(playerid, name, sizeof(name));

	  // swat vehicles
      if(GetVehicleModel(vehicleid) == 427 || GetVehicleModel(vehicleid) == 601)
       {
         if(name != "batman")
          {
            RemovePlayerFromVehicle(playerid);
            SendClientMessage(playerid, COLOR_RED, "This car is reserved for batman!");
            SetPlayerWantedLevel(playerid, 2); // coment this line if you dont want set the wanted level
          }
       }
   } 
  return 1;   
 }
Reply


Messages In This Thread
Car lock [NOTOK] =D - by med93100 - 01.03.2008, 06:09
Re: Car lock - by alexiis - 01.03.2008, 06:44
Re: Car lock - by PinkFloydLover - 01.03.2008, 06:50
Re: Car lock - by alexiis - 01.03.2008, 06:58
Re: Car lock - by eldiablo1337 - 01.03.2008, 07:27
Re: Car lock - by med93100 - 01.03.2008, 07:57
Re: Car lock - by robhol - 01.03.2008, 08:11
Re: Car lock - by Stinovlas - 01.03.2008, 09:21
Re: Car lock - by med93100 - 01.03.2008, 18:59
Re: Car lock - by Lenda - 01.03.2008, 19:32

Forum Jump:


Users browsing this thread: 1 Guest(s)