Core/Scripts: Replace rand with urand in most cases (using regexp)
Used: perl -pi -e 's/([0-9]+) \+ rand\(\)\%([0-9]+)/"urand(".$1.", ".($1+$2).")"/ge'
This commit is contained in:
+4
-4
@@ -691,8 +691,8 @@ public:
|
||||
|
||||
void Reset()
|
||||
{
|
||||
Mindblast_Timer = 3000 + rand()%5000;
|
||||
Earthshock_Timer = 5000 + rand()%5000;
|
||||
Mindblast_Timer = urand(3000, 8000);
|
||||
Earthshock_Timer = urand(5000, 10000);
|
||||
|
||||
if (instance)
|
||||
{
|
||||
@@ -764,7 +764,7 @@ public:
|
||||
|
||||
if (target)DoCast(target, SPELL_MINDBLAST);
|
||||
|
||||
Mindblast_Timer = 10000 + rand()%5000;
|
||||
Mindblast_Timer = urand(10000, 15000);
|
||||
} else Mindblast_Timer -= diff;
|
||||
|
||||
if (Earthshock_Timer <= diff)
|
||||
@@ -787,7 +787,7 @@ public:
|
||||
}
|
||||
}
|
||||
}
|
||||
Earthshock_Timer = 8000 + rand()%7000;
|
||||
Earthshock_Timer = urand(8000, 15000);
|
||||
} else Earthshock_Timer -= diff;
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user