diff options
Diffstat (limited to 'npc/functions/siege.txt')
-rw-r--r-- | npc/functions/siege.txt | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/npc/functions/siege.txt b/npc/functions/siege.txt index 72566549e..9149cfaa4 100644 --- a/npc/functions/siege.txt +++ b/npc/functions/siege.txt @@ -26,25 +26,26 @@ function script siege_calcdiff { .@highest=getarg(1, false); .@c = getunits(BL_PC, .@players, false, getarg(0)); for (.@i = 0; .@i < .@c; .@i++) { - .@b=;readparam(BaseLevel, .@players[.@i]) + .@b=readparam(BaseLevel, .@players[.@i]); .@bsum+=.@b; if (.@b > .@highest) .@highest=.@b; } + debugmes "calcdiff: Total %d Average %d Highest %d", .@bsum, (.@bsum/.@c), .@highest; if (getarg(1,false)) return .@highest; else return (.@bsum/.@c); } -// push to $@SIEGE_TMPMOBS the <mobID> if their level is within a 20 level range +// push to $@SIEGE_TMPMOBS the <mobID> if their level is within a 15 levels range // above or below <level> // siege_push ( mobID, level ) function script siege_push { .@mi=getarg(0); .@lv=getarg(1,0); - if (is_between(.@lv-20, .@lv+20, atoi(strmobinfo(3, .@mi)) ) ) + if ( is_between(.@lv-15, .@lv+15, strmobinfo(3, .@mi)) ) array_push($@SIEGE_TMPMOBS, .@mi); return; } |