Advertisement
RaZgRiZ

Autobot Player Balancer 1.2 SVN

Mar 21st, 2012
207
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.69 KB | None | 0 0
  1. "++" = [$arg1 = (+ (getalias $arg1) 1)]
  2.  
  3. autobot = [
  4.     local bots players maxbots total
  5.     _abp_balance = $arg1 ; bots = 0 ; players = 0
  6.     maxbots = (? (isconnected) (? (ismaster (getclientnum)) (? (isadmin (getclientnum)) 32 8) 0) 32)
  7.     looplist l (listclients 1) [
  8.         cond (> $l 127) [++ bots] (&& (< $l 128) (! (isspectator $l))) [++ players]
  9.     ]
  10.     if (&& (> $arg1 0) $maxbots) [
  11.         total = (+ $bots $players)
  12.         cond (&& (< $bots $maxbots) (< $total $_abp_balance)) [
  13.             loop i (min (- $_abp_balance $total) $maxbots) addbot
  14.         ] (&& (< $_abp_balance $total) (> $bots 0)) [
  15.             loop i (min (- $total $_abp_balance) $bots) delbot
  16.         ]
  17.         sleep 500 [autobot $_abp_balance]
  18.     ] [loop i $bots delbot]
  19. ]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement