Guest User

Untitled

a guest
Nov 23rd, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.71 KB | None | 0 0
  1. #IfWinActive, Darkfall Online ahk_class SFMainWindow
  2. {
  3.  
  4. $SC04E::
  5. Suspend Permit ; allow this code to remain active
  6.  
  7. if (GuiMode()) ; if mouse pointer visible ie. in gui mode
  8. {
  9. Suspend Off ; reactivate the script
  10. SendInput {SC04E} ; Exit to game mode
  11. Sleep 100
  12.  
  13. if (GuiMode()) ; if still in gui mode (chat)
  14. {
  15. SendInput {SC04E} ; Send Esc key, exit to game mode
  16. Sleep 100
  17. } ; end if
  18. } ; end if
  19.  
  20. else ; if mouse pointer not visible ie. we are in game mode
  21. {
  22. Suspend On ; temporarily disable the script
  23. SendInput {SC04E} ; Enter GUI mode
  24. Sleep 100
  25. } ; end else
  26. return ; end subroutine
  27.  
  28. ; this procedure checks for gui mode, and returns either 1 or 0 (true or false)
  29. ; it is called by the above routine each time you need to know
  30. ; if you are in the GUI or not.
  31.  
  32. GuiMode()
  33. {
  34. VarSetCapacity(mi,20,0)
  35. mi:=chr(20)
  36. DllCall("GetCursorInfo","Uint",&mi)
  37. hCursor:=NumGet(mi,8) ; returns 0 for game-mode
  38. return hCursor
  39. }
  40.  
  41. ; SINGLE BUTTON MULTI SKILL HOTKEYS
  42. 1:: ;Power Attack
  43. Send {1}
  44. Send {SC04A}
  45. Send {Shift Down}{F1}{Shift Up} ; Mana too stam
  46. click
  47. return
  48.  
  49. 2:: ;Whirl Wind
  50. Send {2}
  51. send {=}
  52. Send {,}
  53. if (healSelfCycle = "0") { ; Witches Brew Stam to health
  54. send {F6}
  55. click
  56. healSelfCycle = 1
  57. } ELSE if (healSelfCycle = "1") {
  58. send {F5}
  59. click
  60. healSelfCycle = 0
  61. } ELSE {
  62. healSelfCycle = 0
  63. }
  64. return
  65.  
  66. ;Shift 2 used for R90 nuke
  67. +2:: ;Exploding Charge then que's Virtuous Wrath
  68. send {;}
  69. send {RShift Down}{2}{RShift Up}
  70. KeyWait, LButton, D
  71. KeyWait, LButton
  72. send {Alt Down}{2}{Alt Up} ;Virtuous wrath
  73. return
  74.  
  75. 3:: ;Disabling Blow
  76. Send {3}
  77. Send {F12} ; Bind disarming shot to F1, and disabling blow to 3
  78. Send {F7} ; Health to Mana
  79. return
  80.  
  81. 4:: ; Knock back Heal self
  82. Send {4}
  83. Send {F8}
  84. click
  85. return
  86.  
  87. ;DEBUFF SPAM MACRO
  88. 7:: ;Melee Debuffs
  89. Send {;}
  90. if (MeleeDebuffCycle = "0") {
  91. send 7
  92. MeleeDebuffCycle = 1
  93. } ELSE if (MeleeDebuffCycle = "1") {
  94. send {Shift Down}{F9}{Shift Up}
  95. MeleeDebuffCycle += 1
  96. } ELSE if (MeleeDebuffCycle = "2") {
  97. send {Shift Down}{F10}{Shift Up}
  98. MeleeDebuffCycle = 0
  99. } ELSE {
  100. MeleeDebuffCycle = 0
  101. }
  102. return
  103. +7:: ;Archery Debuffs
  104. Send {;}
  105. if (ArchDebuffCycle = "0") {
  106. send {RShift Down}{7}{RShift Up}
  107. ArchDebuffCycle = 1
  108. } ELSE if (ArchDebuffCycle = "1") {
  109. send {Shift Down}{F11}{Shift Up}
  110. ArchDebuffCycle = 0
  111. } ELSE {
  112. ArchDebuffCycle = 0
  113. }
  114. return
  115.  
  116. Numpad2::
  117. send {/}
  118. sleep 300
  119. if (buffCycle = "0") {
  120. Send {Alt down}{Numpad0}{Alt up}
  121. buffCycle = 1
  122. } ELSE if (buffCycle = "1") {
  123. Send {Alt down}{Numpad1}{Alt up}
  124. buffCycle += 1
  125. buffCycle += 1
  126. } ELSE if (buffCycle = "2") {
  127. Send {Alt down}{F2}{Alt up}
  128. } ELSE if (buffCycle = "3") {
  129. Send {Alt down}{Numpad3}{Alt up}
  130. buffCycle += 1
  131. } ELSE if (buffCycle = "4") {
  132. Send {Alt down}{Numpad4}{Alt up}
  133. buffCycle += 1
  134. } ELSE if (buffCycle = "5") {
  135. Send {Alt down}{Numpad5}{Alt up}
  136. buffCycle += 1
  137. } ELSE if (buffCycle = "6") {
  138. Send {Alt down}{Numpad6}{Alt up}
  139. buffCycle += 1
  140. } ELSE if (buffCycle = "7") {
  141. Send {Alt down}{Numpad7}{Alt up}
  142. buffCycle += 1
  143. } ELSE if (buffCycle = "8") {
  144. Send {Alt down}{Numpad8}{Alt up}
  145. buffCycle += 1
  146. } ELSE if (buffCycle = "9") {
  147. Send {Alt down}{Numpad9}{Alt up}
  148. buffCycle += 1
  149. } ELSE if (buffCycle = "10") {
  150. Send {Alt down}{F12}{Alt up}
  151. buffCycle += 1
  152. } ELSE if (buffCycle = "11") {
  153. Send {Alt down}{F11}{Alt up}
  154. buffCycle += 1
  155. } ELSE if (buffCycle = "12") {
  156. Send {Alt down}{F10}{Alt up}
  157. buffCycle += 1
  158. } ELSE if (buffCycle = "13") {
  159. Send {Alt down}{F9}{Alt up}
  160. buffCycle += 1
  161. } ELSE if (buffCycle = "14") {
  162. Send {Alt down}{F8}{Alt up}
  163. buffCycle = 0
  164. } ELSE {
  165. buffCycle = 0
  166. }
  167. return
  168.  
  169. ;HEAL OTHER SPAM MACRO
  170. SC151::
  171. if (healCycle = "0") {
  172. send {;}
  173. send {Alt Down}{1}{Alt Up}
  174. sleep 100
  175. click
  176. healCycle = 1
  177. } ELSE if (healCycle = "1") {
  178. send {;}
  179. send {Alt Down}{3}{Alt Up}
  180. sleep 100
  181. healCycle += 1
  182. } ELSE if (healCycle = "2") {
  183. send {;}
  184. send {Alt Down}{4}{Alt Up}
  185. sleep 100
  186. click
  187. healCycle += 1
  188. } ELSE if (healCycle = "3") {
  189. send {;}
  190. send {Alt Down}{5}{Alt Up}
  191. healCycle = 0
  192. } ELSE {
  193. healCycle = 0
  194. }
  195. return
  196.  
  197. ;BUFF OTHER MACRO
  198. SC152::
  199. if (buffOtherCycle = "0") {
  200. send {/}
  201. sleep 300
  202. send {Alt Down}{6}{Alt Up}
  203. buffOtherCycle = 1
  204. } ELSE if (buffOtherCycle = "1") {
  205. send {/}
  206. sleep 300
  207. send {Alt Down}{7}{Alt Up}
  208. buffOtherCycle += 1
  209. } ELSE if (buffOtherCycle = "2") {
  210. send {/}
  211. sleep 300
  212. send {Alt Down}{8}{Alt Up}
  213. buffOtherCycle += 1
  214. } ELSE if (buffOtherCycle = "3") {
  215. send {/}
  216. sleep 300
  217. send {Alt Down}{9}{Alt Up}
  218. buffOtherCycle += 1
  219. } ELSE if (buffOtherCycle = "4") {
  220. send {/}
  221. sleep 300
  222. send {-}
  223. buffOtherCycle += 1
  224. } ELSE if (buffOtherCycle = "5") {
  225. send {/}
  226. sleep 300
  227. send {Alt Down}{0}{Alt Up}
  228. buffOtherCycle = 0
  229. } ELSE {
  230. buffOtherCycle = 0
  231. }
  232. return
  233.  
  234. ;WEAPON EQUIP HOTKEYS
  235. WheelUp:: ; Equip 2h Weapon
  236. Send {'}
  237. return
  238.  
  239. +WheelUp:: ; Pole
  240. Send {SC01A}
  241. return
  242.  
  243. ^WheelUp:: ; Axe
  244. Send {SC135}
  245. return
  246.  
  247. MButton:: ; Equip Sword bound to middle mouse click, Shield bound to .
  248. Sleep, 600
  249. Send {.} ; equip shield
  250. return
  251.  
  252. WheelDown:: ; Equip HEALING staff
  253. Send {;}
  254. return
  255.  
  256. +WheelDown:: ; Slow Staff
  257. Send {SC035}
  258. return
  259.  
  260. ;AUTO SPRINT TOGGLE
  261. *SC153:: ; SC029 is the tilde key
  262. if toggle := !toggle
  263. Send, {SC153 down}
  264. else
  265. Send, {SC153 up}
  266. return
  267.  
  268. }
Add Comment
Please, Sign In to add comment