I dont get it, why can this error occur? Seems like its crashing the server after some time.
Is there any way to fix it?
line 574: new plrHealth = get_user_health(id)
L 06/19/2007 - 13:14:48: [AMXX] Run time error 4: index out of bounds
L 06/19/2007 - 13:14:48: [AMXX] [0] phpy4ngxv.sma::doDamage (line 574)
L 06/19/2007 - 13:14:48: [AMXX] Displaying debug trace (plugin "weapons.amxx")
Code:
public doDamage(id){
if (get_cvar_num("sv_xweapons")==0){
return PLUGIN_CONTINUE
}
new plrDmg = read_data(2)
new plrWeap
new plrPartHit
new plrAttacker = get_user_attacker(id, plrWeap, plrPartHit)
if (!xmp5_carrier[plrAttacker] && !xm3_carrier[plrAttacker] && !xarmor_carrier[plrAttacker] && !xkevlar_carrier[plrAttacker] && !xknife_carrier[plrAttacker] && !xrevolver_carrier[plrAttacker]){
return PLUGIN_CONTINUE
}
if (!is_user_alive(id)){
return PLUGIN_CONTINUE
}
new plrHealth = get_user_health(id)
new plrNewDmg
...