From 766246648d900f1539677224fb1042489caa06d7 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Mon, 4 Oct 2004 20:10:27 +0000 Subject: [PATCH] Fixed runtime error bugs --- plugins/dod/stats.sma | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/plugins/dod/stats.sma b/plugins/dod/stats.sma index 4a7a8bf1..551d6cb1 100755 --- a/plugins/dod/stats.sma +++ b/plugins/dod/stats.sma @@ -281,7 +281,8 @@ getAttackers(id) { new amax = get_maxplayers() for(new a = 1; a <= amax; ++a){ - if(get_user_astats(id,a,stats,body,wpn,31)){ + if(is_user_connected(a) && get_user_astats(id,a,stats,body,wpn,31)) + { found = 1 if (stats[0]) format(wpn,31," -- %s",wpn) @@ -301,7 +302,8 @@ getVictims(id) { new pos = format(g_Buffer,2047,"%L^n",id,"VICTIMS") new amax = get_maxplayers() for(new a = 1; a <= amax; ++a){ - if(get_user_vstats(id,a,stats,body,wpn,31)){ + if(is_user_connected(a) && get_user_vstats(id,a,stats,body,wpn,31)) + { found = 1 if (stats[1]) format(wpn,31," -- %s",wpn)