problem with /giveweapon name
#5

I am actually creating it with name parameter

this are my codes

Код:
new WeaponNames[47][] =
{
        {"Unarmed"},{"Brass Knuckles"},{"Golf Club"},{"Nite Stick"},{"Knife"},{"Baseball Bat"},{"Shovel"},{"Pool Cue"},{"Katana"},{"Chainsaw"},{"Purple Dildo"},
        {"Smal White Vibrator"},{"Large White Vibrator"},{"Silver Vibrator"},{"Flowers"},{"Cane"},{"Grenade"},{"Tear Gas"},{"Molotov Cocktail"},
        {""},{""},{""}, // Empty spots for ID 19-20-21 (invalid weapon id's)
        {"9mm"},{"Silenced 9mm"},{"Desert Eagle"},{"Shotgun"},{"Sawn-off Shotgun"},{"Combat Shotgun"},{"Micro SMG"},{"MP5"},{"AK-47"},{"M4"},{"Tec9"},
        {"Country Rifle"},{"Sniper Rifle"},{"Rocket Launcher"},{"HS Rocket Launcher"},{"Flamethrower"},{"Minigun"},{"Satchel Charge"},{"Detonator"},
        {"Spraycan"},{"Fire Extinguisher"},{"Camera"},{"Nightvision Goggles"},{"Thermal Goggles"},{"Parachute"}
};
Код:
stock GetWeaponModelIDFromName(wname[])
{
    for(new i = 0; i < 48; i++) {
        if (i == 19 || i == 20 || i == 21) continue;
        if (strfind(WeaponNames[i], wname, true) != -1) {
        return i;
        }
    }
    return -0;
}
Reply


Messages In This Thread
problem with /giveweapon name - by Nabster - 09.03.2015, 07:37
AW: problem with /giveweapon name - by Kaliber - 09.03.2015, 07:47
Re: problem with /giveweapon name - by Nabster - 09.03.2015, 08:46
AW: Re: problem with /giveweapon name - by Kaliber - 09.03.2015, 08:50
Re: problem with /giveweapon name - by Nabster - 09.03.2015, 08:56
AW: Re: problem with /giveweapon name - by Kaliber - 09.03.2015, 09:04
Re: problem with /giveweapon name - by Nabster - 09.03.2015, 09:12
Re: problem with /giveweapon name - by X337 - 09.03.2015, 09:21
Re: problem with /giveweapon name - by WildWave - 09.03.2015, 09:22
Re: problem with /giveweapon name - by Nabster - 09.03.2015, 09:27

Forum Jump:


Users browsing this thread: 1 Guest(s)