orderturns()
src.turns=src.battlers.Copy()
for(var/mob/M in src.turns)
for(var/mob/Q in src.turns)
if(M==Q) continue
if(M.agi>Q.agi)
src.turns.Swap(M,Q)
else if(M.agi<Q.agi)
src.turns.Swap(Q,M)
else if(M.agi==Q.agi)
if(rand(1,2)==2)
src.turns.Swap(M,Q)
else
src.turns.Swap(Q,M)
for(var/a in src.turns)
world<<a
*cough*
I can't seem to get this right... =/
Sorry for being a nub...but, meh.
Thanks for reading...
Also, I have no idea why you're using if(rand(1,2)==2) rather than if(prob(50)). Of course, neither is really right here. If you want all items with the same agi value to be randomly positioned in their part of the list, mere one-pass swaps won't do.
Lummox JR