private static void OnTick(EventArgs args) { //recall debug //if (SingedSpell.isRecalling()) //{ // Chat.Print("Recalling..."); //} if (Me.IsDead || SingedSpell.isRecalling()) { return; //IGNORES REST OF CODE ON TICK WHEN DEAD OR RECALLING } //Handles buffered Q casting without stalling thread SingedSpell.checkQTogglePending(); SingedSpell.setPoisonStatus(); WaitRun.updateTick(wrlist, Game.Time); }
public static void updateTick(List <WaitRun> wrl, float cTime) //cTime(Current Time) { for (int i = 0; i < wrl.Capacity; i++) { try { WaitRun wr = wrl[i]; if (wr != null) { if (wr.waiting == false) { wrl.Remove(wr); } else { if (!(cTime < wr.startTime)) { wr.elapsed = cTime - wr.startTime; if (wr.elapsed >= wr.waitSec) { wr.waiting = false; wr.waitRun(); } } } } else { break; } } catch (ArgumentOutOfRangeException e) { break; } } }