13.01.2014, 12:32
I have debug problems like this
in this public
and here ..
pawn Код:
[09:38:26] [debug] Accessing element at negative index -1
[09:38:26] [debug] AMX backtrace:
[09:38:26] [debug] #0 000fd52c in public IsLaw (playerid=0) at C:\Users\Filip\Desktop\SERVER\no boombox\rp.pwn:20682
[09:38:26] [debug] #1 000a86f4 in public OPJV_OnPlayerKeyStateChange (playerid=0, newkeys=0, oldkeys=4) at C:\Users\Filip\Desktop\SERVER\no boombox\rp.pwn:11190
[09:38:26] [debug] #2 0000d454 in public OnPlayerKeyStateChange (playerid=0, newkeys=0, oldkeys=4) at C:\Users\Filip\Desktop\SERVER\pawno\include\opjv.inc:85
pawn Код:
public IsLaw(playerid)
{
//herenew slot = GetFactionSlot(CharacterInfo[playerid][active_character[playerid]][cFaction]);
if(slot > -1)
{
if(FactionInfo[slot][fType] == FAC_TYPE_LAW) { return true; } else { return false; }
}
return false;
}
and here ..
pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnectedEx(i) && i != playerid)
{
new PlayerText3D:playertextid;
new Float:X, Float:Y, Float:Z;
GetPlayerPos( playerid, X, Y, Z );
playertextid = CreatePlayer3DTextLabel(playerid,"Hello\nI'm at your position",0x008080FF,X,Y,Z,40.0);
}
}
}
pawn Код:
C:\Users\Filip\Desktop\SERVER\no boombox\rp.pwn(9404) : warning 204: symbol is assigned a value that is never used: "playertextid"