A command resetting ALL vehicles (unoccupied) crashes the server...
#2

pawn Код:
stock IsVehicleEmpty(vehicleid)
{
    new rst = 0;
    for(new i; i < GetMaxPlayers(); i++)
    {
        if(GetPlayerVehicleID(i) == vehicleid) rst = 1;
        if(GetVehicleTrailer(GetPlayerVehicleID(i)) == vehicleid) rst = 1;
    }
    if(rst == 1) return 0;
    return 1;
}
and what's this? "HMOD_CHECK;"

edit: uh wait.. I guess your version would work same good..
however I would add a "IsPlayerConnected" above^^
Reply


Messages In This Thread
A command resetting ALL vehicles (unoccupied) crashes the server... - by Ash. - 22.06.2011, 17:37
Re: A command resetting ALL vehicles (unoccupied) crashes the server... - by Sascha - 22.06.2011, 18:36
Re: A command resetting ALL vehicles (unoccupied) crashes the server... - by Ash. - 22.06.2011, 19:03
Re: A command resetting ALL vehicles (unoccupied) crashes the server... - by Ash. - 26.06.2011, 15:25

Forum Jump:


Users browsing this thread: 1 Guest(s)