17.09.2009, 09:38
Quote:
Originally Posted by 0ne
Save a vehicle where you would like to, then add it to your gamemode, Search for OnPlayerStateChange callback, in that callback write like this:
Код:
public OnPlayerStateChange(playerid, newstate, oldstate) { if (newstate == PLAYER_STATE_DRIVER) { if (GetVehicleModel(GetPlayerVehicleID(playerid)) == gangcar1) { if(gTeam[playerid] == TEAM_YOURGANGNAME) { return 1; } else if(gTeam[playerid] != TEAM_YOURGANGNAME) { SendClientMessage(playerid, COLOR_ORANGE, "[INFO] This car is only for gang members of YOURGANGNAME "); RemovePlayerFromVehicle(playerid); } } } return 1; } Код:
new gangcar; Код:
gangcar = The addstaticvehicle function from savedpositions.txt |