13.11.2010, 16:22
(
Последний раз редактировалось armyoftwo; 13.11.2010 в 16:39.
)
pawn Код:
CMD:dropweapon(playerid)
{
new gunID = GetPlayerWeapon(playerid);
new gunAmmo = GetPlayerAmmo(playerid);
new WID;
if(gunID != 0 && gunAmmo != 0)
{
format(string, sizeof(string), "%s trows his %s away", AccountData[playerid][PlayerName], GetPlayerWeaponName(gunID));
SendLocalMessage(playerid, string, 20.0, COLOR_ME, COLOR_ME);
RemovePlayerWeapon(playerid, gunID);
Itter_Add(Weapons,Iter_Count(Weapons)+1);
GetPlayerPos(playerid, WeaponInfo[Iter_Count(Weapons)][wPos][0], WeaponInfo[Iter_Count(Weapons)][wPos][1], WeaponInfo[Iter_Count(Weapons)][wPos][2]); // ERROR!!
WeaponInfo[Iter_Count(Weapons)][wObject] = GunObjects[gunID][0];
WID = CreateObject(WeaponInfo[Iter_Count(Weapons)][wPos][0], WeaponInfo[Iter_Count(Weapons)][wPos][1], WeaponInfo[Iter_Count(Weapons)][wPos][2]-1,93.7,120.0,120.0);
WeaponInfo[Iter_Count(Weapons)][wObjectID] = WID;
return 1;
}
return 1;
}
Error line has been COMMENTED
Код:
C:\Users\D\Desktop\samp03bsvr_win32\gamemodes\GSRP.pwn(5310) : error 001: expected token: ",", but found "[" C:\Users\D\Desktop\samp03bsvr_win32\gamemodes\GSRP.pwn(5310) : error 029: invalid expression, assumed zero C:\Users\D\Desktop\samp03bsvr_win32\gamemodes\GSRP.pwn(5310) : warning 215: expression has no effect C:\Users\D\Desktop\samp03bsvr_win32\gamemodes\GSRP.pwn(5310) : error 001: expected token: ";", but found "]" C:\Users\D\Desktop\samp03bsvr_win32\gamemodes\GSRP.pwn(5310) : fatal error 107: too many error messages on one line
it's on this line
Код:
GetPlayerPos(playerid, WeaponInfo[Iter_Count(Weapons)][wPos][0], WeaponInfo[Iter_Count(Weapons)][wPos][1], WeaponInfo[Iter_Count(Weapons)][wPos][2]); // ERROR!!