how to make a /giveplayerweapon command using strtok?
#1

ok my idea didnt work this is what i tried:
pawn Код:
if(strcmp(cmd,"/setweapon",true)==0)
    {
        new giveplayerweapon,giveplayerammo;
        tmp = strtok(cmdtext,idx);
        if(!strlen(tmp))return SendClientMessage(playerid,0xFFF0000FF,"USAGE: /setweapon [PLAYERID] [WEAPONID]");
        {
            giveplayerid = strval(tmp);
            giveplayerweapon = strval(tmp);
            giveplayerammo = strval(tmp);
            GivePlayerWeapon(giveplayerid,giveplayerweapon,giveplayerammo);
        }
        return 1;
    }

and well it epicly failed, so how might i make a command like that with strtok?
Reply


Messages In This Thread
how to make a /giveplayerweapon command using strtok? - by CSMajor - 16.08.2010, 22:37
Re: how to make a /giveplayerweapon command using strtok? - by [XST]O_x - 16.08.2010, 22:44
Re: how to make a /giveplayerweapon command using strtok? - by Injection - 16.08.2010, 22:48

Forum Jump:


Users browsing this thread: 3 Guest(s)