Code causing errors:
PHP Code:
new raptorreallife = get_user_health(id);
new raptorinvis = ((raptorreallife*100)/(raptorlife));
set_hudmessage(255, 255, 0, 0.02, 0.87, 0, 6.0, 1.0)
show_hudmessage(id, "Invisibility:%d/100^n Health: %d", raptorinvis, raptorreallife)
set_user_rendering(id,kRenderFxGlowShell,0,0,0,kRenderTransAlpha, (raptorinvisi-(raptorinvis*2)))
Log:
Anyone know how to fix it? I've got everything else fixed and running so far but this.
New Issue:
Okay, after some more debugging I've discovered another issue.
PHP Code:
if(israptor[attacker]!=0 && attacker!=id && is_user_alive(attacker)){
new victimhealth = get_user_health(id)
set_user_health(id, victimhealth-raptordomage)
new Float:vVel[3]
for(new i = 0;i <= 2;i++)
vVel[i] = random_float(-10.0,10.0)
entity_set_vector(id,EV_VEC_punchangle,vVel)
pain(id)
}
Error Log:
Quote:
L 03/15/2009 - 15:12:20: [AMXX] Displaying debug trace (plugin "revoraptor5.amxx")
L 03/15/2009 - 15:12:20: [AMXX] Run time error 4: index out of bounds
L 03/15/2009 - 15:12:20: [AMXX] [0] revoraptor5.sma::damaging (line 340)
|
Much appreciated if someone could help me out with this issue. I've just finished fixing the gun menu and this came up so I'm not quite sure on how to fix it.