How to create a car that is on the map but locked to someones name?
#6

Top of script
Код:
#define team_example   1
new pTeam[MAX_PLAYERS];

new EXAMPLE1;
Код:
EXAMPLE1 = AddStaticVehicleEx(596,1538.6521,-1643.8551,5.6114,0.3763,0,1,100000);
Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
    if(IsPlayerInVehicle(playerid, EXAMPLE1) || IsPlayerInVehicle(playerid, EXAMPLE2) || IsPlayerInVehicle(playerid,EXAMPLE))
    {
        SCM(playerid, RED, "you are not part of this group.");
        RemovePlayerFromVehicle(playerid);
    }
    else
    {
        if(pTeam[playerid] == team_example)
        {
            SCM(playerid, GREEN, "/engine to start the vehicle");
        }
    }
    return 1;
}
That should work, haven't tested.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)