cmd wont work
#2

Quote:
Originally Posted by thefatshizms
Посмотреть сообщение
Hello, i have this command i just made was kinda in a rush and did really quick so i apologise for any silly mistakes as i cant see them :/
pawn Код:
CMD:plate(playerid, params[])
{
    new currentveh, newveh, msg[128], Float:X, Float:Y, Float:Z, Float:A;
    if(PlayerInfo[playerid][Padmin] >=1)
    {
        if(sscanf(params,"s[128]",msg)) return SendClientMessage(playerid, COLOR_GREEN, "USAGE: /plate <message>");
        currentveh = GetPlayerVehicleID(playerid);
        GetPlayerPos(playerid, X, Y, Z);
        GetPlayerFacingAngle(playerid, A);
        newveh = CreateVehicle(currentveh, X, Y, Z, A, 2, 0, -1);
        SetVehicleNumberPlate(newveh, msg);
        DestroyVehicle(currentveh);
        PutPlayerInVehicle(playerid,newveh,0);
        return 1;
    }
    else if(PlayerInfo[playerid][Padmin] < 1)
    {
        SendClientMessage(playerid, COLOR_RED, "You must be admin to use this command");
        return 1;
    }
    return 1;
}
it shows the usage message then destroys my vehicle but doesn't create a new one
Why are you destroying the vehicle ?
Reply


Messages In This Thread
cmd wont work - by thefatshizms - 22.08.2012, 15:00
Re: cmd wont work - by Glint - 22.08.2012, 15:03
Re: cmd wont work - by HuSs3n - 22.08.2012, 15:05
Re: cmd wont work - by thefatshizms - 22.08.2012, 15:05
Re: cmd wont work - by thefatshizms - 22.08.2012, 15:07
Re: cmd wont work - by Glint - 22.08.2012, 15:07
Re: cmd wont work - by thefatshizms - 22.08.2012, 15:15
Re: cmd wont work - by HuSs3n - 22.08.2012, 15:23
Re: cmd wont work - by thefatshizms - 22.08.2012, 15:45

Forum Jump:


Users browsing this thread: 2 Guest(s)