Hi, I have a problem with a few logs that I have a plugin
L 10/12/2014 - 20:58
9: Invalid array handle provided (0)
L 10/12/2014 - 20:58
9: [AMXX] Displaying debug trace (plugin "zombie_plague40.amxx")
L 10/12/2014 - 20:58
9: [AMXX] Run time error 10: native error (native "ArraySize")
L 10/12/2014 - 20:58
9: [AMXX] [0] zombie_plague40.sma::get_user_group (line 9912)
L 10/12/2014 - 20:58
9: [AMXX] [1] zombie_plague40.sma::client_putinserver (line 2266)
Say, the code works perfectly, but it does not check well the groups, this is the line, and get_user_group
PHP Code:
get_user_group(id)
{
new szAuthID[35]
get_user_authid(id, szAuthID, charsmax(szAuthID))
new aData[AMIGOS_INFO]
for(new i = 0; i < ArraySize(g_grupos); i++)
{
ArrayGetArray(g_grupos, i, aData)
if(TrieKeyExists(aData[GRUPO_AMIGOS], szAuthID))
return i;
}
return -1;
}
PHP Code:
g_igroups[id] = get_user_group(id) // Line 2266
thanks