Advertisement
Guest User

Untitled

a guest
Aug 31st, 2015
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.12 KB | None | 0 0
  1. ; #FUNCTION# ====================================================================================================================
  2. ; Name...........: _castAreaInstantSpell
  3. ; Description ...: Swaps bars to perform an instant spell and swaps back.
  4. ; Parameters ....: $hotKeySwap - The in game keybinding of weapon swap.
  5. ; $hotKeyBuff - The in game keybinding of the spell.
  6. ; ===============================================================================================================================
  7. Func _castAreaInstantSpell($hotKeySpell)
  8.  
  9. ; Initialising variables
  10. Local $timer = TimerInit()
  11. Local $state = 1
  12.  
  13. If $fStateCritical = True Then
  14.  
  15. ; Critical state start
  16. $fStateCritical = False
  17.  
  18. While TimerDiff($timer) < 800
  19.  
  20. If TimerDiff($timer) < 2 and $state = 1 Then
  21. _controlSend($hotKeySpell)
  22. $state = 2
  23. EndIf
  24.  
  25. If TimerDiff($timer) < 100 and $state = 2 Then
  26. _controlSend($hotKeySpell)
  27. $state = 3
  28. EndIf
  29. Sleep(10)
  30. WEnd
  31.  
  32. ; Reset Variables
  33. $timer = 0
  34. $state = 1
  35.  
  36. ; Critical state end
  37. $fStateCritical = True
  38.  
  39. EndIf
  40.  
  41. EndFunc ;==>_castAreaInstantSpell
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement