20.01.2013, 12:10
Hey there!
I'm trying to create a command that will give you some specific weapons (their ID's).
I'm having a problem that the pawno does't recognize the var and I don't know why..
What am I doing wrong here? Am I coding the variable wrong?
I'm trying to create a command that will give you some specific weapons (their ID's).
I'm having a problem that the pawno does't recognize the var and I don't know why..
What am I doing wrong here? Am I coding the variable wrong?
PHP код:
CMD:spawnweapons(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >= 1 && Logged[playerid])
{
new weaponlist[] = { 24, 27, 31, 34, 35, 43 };
for(new i = 0; i < sizeof(weaponlist); i++) //<- line 2413
{
GivePlayerWeapon(playerid, i, 10010);
}
GameTextForPlayer(playerid,"~w~Weapons ~g~Gained", 5000, 1);
}
else return SendErrorMessage(playerid, ERROR_ADMIN);
return 1;
}
PHP код:
GameModes.pwn(2413) : warning 204: symbol is assigned a value that is never used: "weaponlist"