View Single Post
  #3  
Old 03-13-2013, 03:29 AM
NatedogEZ's Avatar
NatedogEZ
Developer
 
Join Date: Dec 2012
Posts: 515
Default

this part is what i'm asking secrets


Code:
    int random = MakeRandomInt(0, count-1);
    iterator.Reset();
    for (int i = 0; i < random-1; i++)
        iterator.Advance();
    return iterator.GetData()->ent;


I understand it would be 0 to 5 for a 6 man party

But INSIDE the for loop ... it removes another 1!

Code:
for (int i = 0; i < random-1; i++)
So for a 6 man party it would be 0 to 4 .. which leaves someone off...

Ive been testing it for awhile.. it never casts on the LAST person to aggro they never get picked by GetHateRandom
Reply With Quote