06.10.2012, 15:16
pawn Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
for(new i = 0; i < MAX_PLAYERS;i++) {
if(GetPlayerState(i) == PLAYER_STATE_PASSENGER) {
new driver;
driver = GetPlayerState(i);
if(driver == PLAYER_STATE_DRIVER && IsPlayerInVehicle(i, vehicleid) && IsPlayerConnected(i)) {
GivePlayerMoney(driver, 12);
GivePlayerMoney(playerid, -12);
}
}
}
return 1;
}