1 question
#1

How can i make an command with /car [vehicle id] and have vehicles on blacklist like players cant spawn hydra and more? When player spawns, i want the old vehicle to disappear. please help me and thanks
Reply
#2

pawn Код:
new getveh[ MAX_PLAYERS ];

CMD:getveh( playerid, params[ ] )
{
    new v1;
    if ( sscanf( params, "i", v1 ) )
    {
        return SendClientMessage(playerid, -1, "Syntax: /getveh <vehicle ID>");
    }
    if ( getveh[playerid] > 0 ) {
    DestroyVehicle(getveh[playerid]);
    getveh[playerid] = 0;
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x, y, z);
    getveh[playerid] = CreateVehicle(v1, x, y, z, 90, 0, 0, false);
    PutPlayerInVehicle(playerid, getveh[playerid], 0);
    SendClientMessage(playerid, -1, "You already had a vehicle created. It has been deleted and a new one spawned.");
    }
    else {
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x, y, z);
    getveh[playerid] = CreateVehicle(v1, x, y, z, 90, 0, 0, false);
    PutPlayerInVehicle(playerid, getveh[playerid], 0);
    SendClientMessage(playerid, -1, "Your vehicle has been created.");
    }
    return 1;
}
For your "blacklists", just add a "if (v1 != hydra id here) {"
Reply
#3

How do i make if player types the half name or full, it will also spawn
Reply
#4

Quote:
Originally Posted by tanush
Посмотреть сообщение
How do i make if player types the half name or full, it will also spawn
Take a look into the Ladmin FS, theres an neat /vehicle or /car command there, can't remember what ever it is defined as.
Reply
#5

http://forum.sa-mp.com/showthread.ph...ghlight=LAdmin wont work and i really would like one for zcmd
Reply
#6

Quote:
Originally Posted by tanush
Посмотреть сообщение
http://forum.sa-mp.com/showthread.ph...ghlight=LAdmin wont work and i really would like one for zcmd
Zcmd and Dcmd works the same way, though Zcmd is easier to use, easier to manage and is proven faster.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)