Posts: 77
Threads: 23
Joined: Aug 2012
Reputation:
0
Can someone tell me how to make team cars? i made one but its working only 1 car ...
Posts: 912
Threads: 116
Joined: Jun 2012
Reputation:
0
new BlueTeamCars[3];
OnGameModeInt
BlueTeamCars[0] = CAR 1
BlueTeamCars[1] = CAR 2
BlueTeamCars[2] = CAR 3
If you want to kick them out of the other vehicles just comment
Posts: 77
Threads: 23
Joined: Aug 2012
Reputation:
0
but how to make the check?
Posts: 912
Threads: 116
Joined: Jun 2012
Reputation:
0
It would help if you told us what you mean by "CHECK"
Posts: 77
Threads: 23
Joined: Aug 2012
Reputation:
0
This:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(newstate == 2)
{
new CarCheck = GetPlayerVehicleID(playerid);
if(CarCheck == Cars[Police] )
{
if(gTeam[playerid] != 1)
{
RemovePlayerFromVehicle(playerid);
SendClientMessage(playerid, COLOR_RED, "You Don't have the keys for this car!");
return 1;
}
}
if(CarCheck == Cars[Mafia] )
{
if(gTeam[playerid] != 2)
{
RemovePlayerFromVehicle(playerid);
SendClientMessage(playerid, COLOR_RED, "You Don't have the keys for this car!");
return 1;
}
}
return 1;
}
return 1;
}
How to fix it to checks if player is police to been kicked removed from ANY mafia cars