Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- new faccion[MAX_PLAYERS]; // variable de faccion.
- public OnPlayerSpawn(playerid)
- {
- faccion[playerid] = 2; // al spawnear se le asigna la facción 2
- return 1;
- }
- public OnPlayerStateChange(playerid, newstate, oldstate)
- {
- if (newstate == PLAYER_STATE_DRIVER /* si entra a un vehículo como conductor */ && faccion != 1 /* y no es de la facción 1 */)
- {
- RemovePlayerFromVehicle(playerid); // se expulsará del vehículo.
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement