Advertisement
Guest User

Untitled

a guest
Sep 19th, 2014
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 28.16 KB | None | 0 0
  1. | Enchanter Dead Hills Routine.
  2. | Version 1.04
  3. | Attempting to clean up some of the problems that people seem to be having. Also looking to
  4. | automate more of it instead of using /load etc. Make it a bit faster maybe.
  5. |
  6. |
  7.  
  8. #include spell_routines.inc
  9.  
  10. #event ToonReady "<#1> Ready"
  11. #event WarriorEnage "<#1#> Engaging #2#"
  12. #event LootingEvent "#*# has looted a #1#.-#*#"
  13. #event UpdateEvent "#*#Your task '#1#' has been updated."
  14.  
  15. Sub Main
  16.  
  17.  
  18. | Variables to determine when to do certain things.
  19. | All settings for this macro can be found in the file set in IniSelfBuff
  20. | If you do not have this file, run the program for the first time and
  21. | it will create one for you. Then you must go through and edit all of the variables
  22. | to match your character.
  23.  
  24. /declare IniSelfBuff string outer mystuff.ini
  25. /declare NukeAt int outer
  26. /declare NoNukeAt int outer
  27. /declare NoDebuffAt int outer
  28. /declare DoNuke1 int outer
  29. /declare DoNuke2 int outer
  30. /declare DoNuke3 int outer
  31. /declare TankName string outer
  32. /declare TankMacro string outer
  33. /declare LooterName string outer
  34. /declare LooterMacro string outer
  35. /declare Toon1 string outer
  36. /declare Macro1 string outer
  37. /declare Toon2 string outer
  38. /declare Macro2 string outer
  39. /declare Toon3 string outer
  40. /declare Macro3 string outer
  41. /declare SpellNuke1 outer
  42. /declare SpellNuke2 outer
  43. /declare SpellNuke3 outer
  44. /declare SpellMez outer
  45. /declare SpellAEMez outer
  46. /declare SpellRune outer
  47. /declare SpellRuneBuff outer
  48. /declare SpellDot outer
  49. /declare SpellStun outer
  50. /declare SpellTash outer
  51. /declare SpellCripple outer
  52. /declare SpellAura1 outer
  53. /declare SpellAura2 outer
  54. /declare SpellAura1Message outer
  55. /declare SpellAura2Message outer
  56. /declare CampX int outer
  57. /declare CampY int outer
  58. /declare Buff1 outer
  59. /declare Buff2 outer
  60. /declare Buff3 outer
  61. /declare IniPathFile string outer
  62. /declare Path[5,20,2] int outer
  63. /declare MaxPaths int outer
  64. /declare NumReady int outer 0
  65. /declare CampNum int outer 1
  66. /declare ReadysRequired int outer 0
  67. /declare BardSong int outer 0
  68. /declare MezMob int outer 0
  69. /declare MezCount int outer 0
  70. /declare MezTimer timer outer 0
  71. /declare ClickName string outer 0
  72. /declare OuterItem string outer
  73. /declare ReturnGribble int outer 0
  74. /declare zrange int outer 100
  75. /declare BugTimer timer outer 20000
  76. /declare BugF int outer 0
  77. /declare NumTargets int outer 0
  78. /declare CurrentTarget int outer 0
  79. /declare NumMez int outer 0
  80. /declare MelodyTimer timer outer 0
  81. /declare EventStep int outer 0
  82. /declare MezTimerTwo timer outer 0
  83. /declare Restart int outer
  84.  
  85. /declare kk int local 0
  86.  
  87.  
  88. /declare MezTargets int outer 0
  89. /declare CheckMez timer outer 0
  90. :StartAgain
  91.  
  92. /varset NumReady 0
  93. /varset CampNum 1
  94. /varset ReadysRequired 0
  95. /varset BardSong 0
  96. /varset MezMob 0
  97. /varset MezCount 0
  98. /varset MezTimer 0
  99. /varset ClickName 0
  100. /varset ReturnGribble 0
  101. /varset zrange 100
  102. /varset BugTimer 20000
  103. /varset BugF 0
  104. /varset NumTargets 0
  105. /varset CurrentTarget 0
  106. /varset NumMez 0
  107. /varset MelodyTimer 0
  108. /varset EventStep 0
  109. /varset MezTimerTwo 0
  110. /varset Restart 0
  111.  
  112. /doevents flush
  113.  
  114. /if (${Me.Pet.ID}) /pet hold on
  115.  
  116. | Here begins the actual bulk of the routines.
  117.  
  118. /for kk 1 to ${Group}
  119. /if (${Group.Member[${kk}].Type.Equal[PC]}) {
  120. /varcalc ReadysRequired ${ReadysRequired}+1
  121. }
  122. /next kk
  123.  
  124. /if (!${Zone.ShortName.Equal[deadhills_errand]}) /echo Readys Required: ${ReadysRequired}
  125.  
  126. /if (${Zone.ShortName.Equal[deadhills_errand]}) {
  127. /call LoadIni
  128. /call SetUp
  129. /call MemSpells
  130. /goto :killmob
  131. }
  132. /call GetInstance
  133. :SkipZoneIn
  134. /call ZoneIn
  135.  
  136. | Move Puller and Tank to the Camp
  137.  
  138. /g follow
  139. /moveto loc ${CampX} ${CampY}
  140. /delay 5s
  141. /g halt
  142. /delay 3s
  143.  
  144. :killmob
  145. /if (${Me.Buff[Slackening Wave Rk. II].ID}) {
  146. /bc Mezzed myself. Waiting.
  147. /delay 1s
  148. /goto :killmob
  149. }
  150. /if (${Me.CombatState.NotEqual[COMBAT]} && ${ReturnGribble}==1) {
  151. /call ReturnToGribble
  152. /goto :StartAgain
  153. }
  154. /if (${Me.CombatState.NotEqual[COMBAT]}) {
  155. /call PullMobA 1 6 160 0 4
  156. /if (${Restart}) /goto :StartAgain
  157. }
  158.  
  159. /doevents
  160.  
  161. | Ressurection routine should go here.
  162. /if (${Me.State.Equal[HOVER]}) {
  163. /varset CampNum 6
  164. /call Wait4Rez
  165. }
  166.  
  167. /delay 2
  168. /doevents
  169.  
  170. | No mobs? Go back to the top.
  171. /if (${Me.XTarget}==0) /goto :killmob
  172.  
  173. | Ther eare mobs in the Xtarget Window, time to kill them/mez them etc.
  174. /if (!${Target.ID} || (${Target.ID} && !${Target.AggroHolder.ID})) {
  175. /if (${Me.XTarget}>0) {
  176. /if (${Me.XTarget}==1) {
  177. /xtar 1
  178. /delay 10
  179. } else {
  180. /xtar 2
  181. /delay 10
  182. }
  183. }
  184. }
  185.  
  186.  
  187. |/grouproles unset ${Me.Name} 3
  188. /if (${Target.ID}) /face fast
  189.  
  190. /delay 1s
  191. | Make sure runes are up.
  192.  
  193. /if (!${Me.Buff[${SpellRuneBuff}].ID}) {
  194. /bc Casting - ${SpellRune}
  195. /cast "${SpellRune}"
  196. }
  197. /if (${Me.Buff[${Spell[27616].Name}].ID}) {
  198. /alt act 791
  199. /bc Casting - Veil of Mindshadow
  200. }
  201. /if (!${Me.Buff[Eldritch Rune].ID}) {
  202. /alt act 173
  203. /bc Casting - Eldritch Rune
  204. }
  205. /if (${Target.Distance}<70) {
  206. /if (${Me.PctMana}<60 && !${FindItem[Latent Robe of Compulsion].Timer}) {
  207. /useitem 17
  208. /bc Robe Click for Mana
  209. }
  210. /if (${Me.PctMana}<70 && ${Me.AltAbilityReady[Fundament: Second Spire of Enchantment]}) {
  211. /alt act 1381
  212. /bc Second Spire AA for Mana.
  213. }
  214.  
  215. /doevents
  216. /if (${Me.XTarget}==1 || (${MezTimerTwo.Value} && ${Me.XTarget}>1)&&!${Target.Dead}) {
  217. /xtar 1
  218. /if (!${Me.Buff[${SpellRuneBuff}].ID}) {
  219. /bc Casting ${SpellRune}...
  220. /call cast "${SpellRune}"
  221. }
  222. /delay 10
  223. /if (!(${Target.ID}==${Me.Pet.Target.ID}) && ${Me.Pet.ID}) /pet attack
  224. /if (!${Target.Buff[${SpellTash}].ID} && ${Int[${Target.PctHPs}]}>${NoDebuffAt}) {
  225. /bc Casting ${SpellTash}...
  226. /call cast "${SpellTash}"
  227. /goto :NextPass
  228. }
  229. /if (!${Target.Buff[${SpellCripple}].ID} && ${Int[${Target.PctHPs}]}>${NoDebuffAt}) {
  230. /bc Casting ${SpellCripple}
  231. /call cast "${SpellCripple}"
  232. /goto :NextPass
  233. }
  234. /if (!${Target.Buff[${Target.Slowed}].ID} && ${Int[${Target.PctHPs}]}>${NoDebuffAt}) {
  235. /bc Casting Dready Deeds AA
  236. /alt act 753
  237. /delay 4s
  238. /goto :NextPass
  239. }
  240. /if (!(${Me.Aura[1].Equal[${SpellAura1Message}]}) && !(${Me.Aura[2].Equal[${SpellAura1Message}]})) {
  241. /bc Casting ${SpellAura1}....
  242. /delay 1s
  243. /call cast "${SpellAura1}"
  244. /delay 3s
  245. }
  246. /if (!(${Me.Aura[1].Equal[${SpellAura2Message}]}) && !(${Me.Aura[2].Equal[${SpellAura2Message}]})) {
  247. /bc Casting ${SpellAura2}
  248. /delay 1s
  249. /call cast "${SpellAura2}"
  250. /delay 3s
  251. }
  252. /xtar 1
  253. /delay 10
  254. /if (${Int[${Target.PctHPs}]}<${NukeAt} && ${Int[${Target.PctHPs}]}>${NoNukeAt}) {
  255. | Nuke Routines.
  256.  
  257. /if ((${Me.Gem[${SpellNuke1}]})&&(${Me.SpellReady[${SpellNuke1}]})&&(!${Me.Casting.ID})&& ${DoNuke1}) {
  258. /bc Casting ${SpellNuke1}....
  259. /call cast "${SpellNuke1}"
  260. }
  261. /if ((${Me.Gem[${SpellNuke2}]})&&(${Me.SpellReady[${SpellNuke2}]})&&(!${Me.Casting.ID})&& ${DoNuke2}) {
  262. /bc Casting ${SpellNuke2}...
  263. /call cast "${SpellNuke2}"
  264. }
  265. /if ((${Me.Gem[${SpellNuke3}]})&&(${Me.SpellReady[${SpellNuke3}]})&&(!${Me.Casting.ID})&& ${DoNuke3}) {
  266. /bc Casting ${SpellNuke3}...
  267. /call cast "${SpellNuke3}"
  268. }
  269. }
  270. /delay 10
  271. :NextPass
  272. /doevents
  273. }
  274.  
  275. /if (${Me.XTarget}>1 && !${MezTimerTwo.Value}) {
  276. /xtar 2
  277. /delay 1s
  278. /if (${Me.XTarget}==2) {
  279. :ReMez
  280. /bc Casting ${SpellMez} on ${Target.Name}....
  281. /call cast "${SpellMez}"
  282. /if (!${Target.ID}) /goto :SkipMez
  283. /if (${Me.XTarget}<2) /goto :SkipMez
  284. /if (!${Macro.Return.Equal["CAST_SUCCESS"]}) /goto :ReMez
  285. } else {
  286. :ReAEMez
  287. /if (${Target.ID}) /face fast
  288. /if (!${Target.ID}) /goto :SkipMez
  289. /bc Casting Bite of Tashani AA
  290. /alt act 1125
  291. /delay 10
  292. /bc Casting ${SpellAEMez}....
  293. /call cast "${SpellAEMez}"
  294. /for MezCount 2 to ${Me.XTarget}
  295. /xtar ${MezCount}
  296. /delay 10
  297. /if (!${Target.Buff[${Target.Mezzed}].ID}) /goto :ReAEMez
  298. /if (${Me.XTarget}<3) /goto :SkipMez
  299. /next MezCount
  300.  
  301. }
  302. /varset MezTimerTwo 360
  303. :SkipMez
  304. }
  305.  
  306.  
  307. }
  308.  
  309.  
  310. /delay 2
  311. /goto :killmob
  312. /return
  313.  
  314.  
  315.  
  316.  
  317. Sub SetUp
  318. /declare kk int inner
  319. /declare i int inner
  320. /declare k int inner
  321. /alert clear 1
  322. /alert add 1 Gribble
  323. /alert add 1 adventurer
  324. /alert add 1 Cogwitz
  325. /hidecorpse looted
  326. /bct ${TankName} //alert add 1 Gribble
  327. /bct ${TankName} //alert add 1 adventurer
  328.  
  329.  
  330. /varset i 1
  331.  
  332. | Loads the Path file
  333.  
  334. :iloop1
  335.  
  336. /varset k 1
  337. /if (!${Bool[${Ini[${IniPathFile},"Path${i}","PointX${k}"]}]}) {
  338. /varcalc MaxPaths ${i}-1
  339. /echo Number of paths ${MaxPaths}
  340. /return
  341. }
  342.  
  343. :kloop1
  344.  
  345. /if (!${Bool[${Ini[${IniPathFile},"Path${i}","PointX${k}"]}]}) {
  346. /varset Path[${i},${k},1] 0
  347. /varset Path[${i},${k},2] 0
  348. /varcalc i ${i}+1
  349. /goto :iloop1
  350. } else {
  351. | /echo ${i} ${k} ${Ini[${IniPathFile},"Path${i}","PointX${k}"]}
  352. /varset Path[${i},${k},1] ${Ini[${IniPathFile},"Path${i}","PointX${k}"]}
  353. /varset Path[${i},${k},2] ${Ini[${IniPathFile},"Path${i}","PointY${k}"]}
  354. |/echo ${Path[${i},${k},1]}
  355. /varcalc k ${k}+1
  356. }
  357.  
  358. /goto :kloop1
  359.  
  360. /return
  361.  
  362. Sub ReturnToGribble
  363. /delay 90s ${Me.CombatState.NotEqual[COMBAT]}
  364. /delay 180s !${Me.XTarget}||${Me.XTarget[1].PctHPs}>99
  365. /delay 15s
  366. /beep
  367. /bca //end
  368. | My Tank automatically aggro's things with in range - just turning him off to make sure he doesn't do anything silly :)
  369. /bct ${TankName} //end
  370. /delay 2s
  371. /bca //moveto loc 436.9 -282.3
  372. /bca //tar Gribble
  373. /tar Gribble
  374. /delay 5s
  375. /delay 20s ${SpawnCount[PC]}==${SpawnCount[PC radius 40]}
  376. /keypress H
  377. /delay 5s
  378. /bca //say back
  379. /kickplayers task
  380. /delay 5s ${Window[ConfirmationDialogBox].Open}
  381. /nomodkey /notify ConfirmationDialogBox Yes_Button leftmouseup
  382. /delay 10s
  383. /say back
  384. /delay 120s ${Zone.ShortName.Equal[deadhills]}
  385. /delay 30s
  386. /varset CampNum 1
  387. /varset ReturnGribble 0
  388. /varset Restart 1
  389. /return
  390.  
  391. Sub GetInstance
  392. /bc Getting instance, and zoning in.
  393. /tar Gribble
  394. /delay 10
  395. /if (${Target.Distance}<50) {
  396. /say willing
  397. /delay 2s
  398. /notify TaskSelectWnd TSEL_TaskList listselect 3
  399. /delay 2s
  400. /notify TaskSelectWnd TSEL_AcceptButton leftmouse 3
  401. } else {
  402. /bc Gribble is OOR
  403. /endm
  404. }
  405. /return
  406.  
  407. Sub Wait4Ready(int MaxReady)
  408. | This is a routine I call which waits for every toon to say they are ready to proceed. I normally use this
  409. | for zoning and moving between camps (I've used the slacker /afol method tho in this macro)
  410.  
  411.  
  412. /doevents flush
  413. :loop
  414. /doevents
  415. /delay 1
  416. /if (${NumReady}<${MaxReady}) /goto :loop
  417. /bc All toons are [+g+]Ready
  418. /varset NumReady 0
  419. /return
  420.  
  421. Sub ZoneIn
  422.  
  423. /declare kk int inner
  424. /declare bufflist string local ${Ini[${IniSelfBuff}, MyBuffs]}
  425. /declare buffloop int local 0
  426. /declare lastbuff int local 0
  427. :shortloop
  428. /bca //tar Gribble
  429. |----------
  430. |
  431. |
  432. | Insert your /bct commands to role buffs for the characters. You can do it here (in deadhills) b4 you zone in.
  433. |
  434. |----------
  435. | /bct ${Toon1} //cast "Talisman of the Courageous Rk. II"
  436. | /bct ${Toon2} //cast "Unified Hand of Certitude"
  437. | /delay 10s
  438. | Group perfected Leviatation
  439. | /bct ${Toon1} //alt activate 1666
  440. | /delay 5
  441. | /bct ${Toon1} //cast "Talisman of Celerity"
  442.  
  443. /delay 32s
  444. /bca //say leave
  445. /say leave
  446. /delay 120s ${Zone.ShortName.Equal[deadhills_errand]}
  447. /if (!${Zone.ShortName.Equal[deadhills_errand]}) /goto :shortloop
  448. /call LoadIni
  449. /call SetUp
  450. /keypress ESC
  451. /delay 10s
  452. /call SetupCamp
  453. /delay 8s
  454. |-------------------
  455. |
  456. | Or you can do it here, inside the zone
  457. |
  458. |-------------------
  459. /if (!${Me.Gem[${Buff1}]} ) {
  460. /memspell 12 "${Buff1}"
  461. /delay 5s
  462. }
  463.  
  464.  
  465. /call cast "${Buff1}"
  466. /delay 8s
  467. /if (!${Me.Gem[${Buff2}]} ) {
  468. /memspell 12 "${Buff2}"
  469. /delay 5s
  470. }
  471. /call cast "${Buff2}"
  472. /delay 8s
  473. /if (!${Me.Gem[${Buff3}]} ) {
  474. /memspell 12 "${Buff3}"
  475. /delay 5s
  476. }
  477. /call cast "${Buff3}"
  478. /delay 8s
  479.  
  480. /call MemSpells
  481. /delay 8s
  482.  
  483. | Load up some clickie buffs on toons.
  484. /bca //useitem 3
  485. /delay 6
  486. /bca //useitem 6
  487. /delay 6
  488. /bca //useitem 20
  489. /delay 6
  490. /bca //useitem 11
  491. /delay 6
  492. /bca //useitem 15
  493. /delay 2s
  494.  
  495. | Custom self buffs from the ini file defined in IniSelfBuff at top.
  496. | File should look similar to the following
  497. |
  498. | [MyBuffs]
  499. | Item1name=casttime
  500. | Item2name=casttime
  501. | Item3name=casttime
  502. | etc
  503. |
  504. | I.E.
  505. | [MyBuffs]
  506. | Staff of Eternal Eloquence=30
  507.  
  508. /varcalc lastbuff ${bufflist.Count[|]}-1
  509.  
  510.  
  511. /if (!${Ini[${IniSelfBuff}].Length}) {
  512. /echo You do not have a ${IniSelfBuff} file created. Skipping.
  513. /goto :SkipSelfBuff
  514. }
  515. /for buffloop 1 to ${lastbuff}
  516. /echo Attempting to use item: ${bufflist.Arg[${buffloop},|]}
  517. /useitem "${bufflist.Arg[${buffloop},|]}"
  518. /delay ${Ini[${IniSelfBuff},MyBuffs,${bufflist.Arg[${buffloop},|]}]}
  519. /next buffloop
  520.  
  521. :SkipSelfBuff
  522.  
  523. /return
  524.  
  525.  
  526. Sub FollowPath(PathNumber)
  527. /declare i int inner
  528. /varset i 1
  529.  
  530. :movecamploop1
  531.  
  532. /doevents
  533. /bc [+Y+]Path : [+y+]${PathNumber}[+Y+] Point : [+y+]${i} [+x+]
  534. /squelch /moveto loc ${Path[${PathNumber},${i},1]} ${Path[${PathNumber},${i},2]}
  535. /delay 60s ${MoveTo.Stopped}
  536. /varcalc i ${i}+1
  537. /if (${Bool[${Path[${PathNumber},${i},1]}]}) /goto :movecamploop1
  538. /return
  539.  
  540.  
  541. Sub SetupCamp
  542.  
  543. |----------------
  544. |
  545. | This area is where you send out /bct's to your other toons to set up. i.e The tank sets up ready to receive mobs, you healers set up.
  546. |
  547. |-----------------
  548. |/bct ${Toon2} //tar ${TankName}
  549. /bca //tar ${TankName}
  550. /delay 5s
  551. /bct ${TankName} //mac ${TankMacro}
  552. /bct ${Toon1} //mac ${Macro1}
  553. /bct ${Toon3} //mac ${Macro3}
  554. /bct ${Toon2} //mac ${Macro2}
  555. /bct ${LooterName} //hidecorpse looted
  556. /delay 5
  557. /bct ${LooterName} //mac ${LooterMacro}
  558. /delay 5s
  559. /return
  560.  
  561. Sub PullMobA(PullType, MaxMobs, PullRange, MezRange, NumberMobsToCheck)
  562. | This macro no longer uses the PullType but I haven't removed it yet. (To avoid
  563. | issues with calls up top. Eventually I'll remove it and change all those calls.
  564. | For now I've removed all the bard fade checks and such, the chanter will not fade
  565. | with the current setup. My chanter has never needed to with 4 mobs.
  566.  
  567. || PullType = 1 = Boastful Bellow, 2 = Sonic Displacement, 4 = Slumber, 8 = Double Pull... (bitwise operation)
  568. /declare i int inner
  569. /declare EndOfPath int inner 0
  570. /declare CheckMob int inner 1
  571. /declare PullList string inner
  572. /declare tt int inner 0
  573.  
  574.  
  575. /if (${Zone.ShortName.NotEqual[deadhills_errand]}) {
  576. /bc Not in the correct zone
  577. /bca //end
  578. /end
  579. }
  580.  
  581. /if (!(${Me.Aura[1].Equal[${SpellAura1Message}]}) && !(${Me.Aura[2].Equal[${SpellAura1Message}]})) {
  582. /echo Twincast Down, casting.
  583. /delay 1s
  584. /call cast "${SpellAura1}"
  585. /delay 3s
  586. }
  587.  
  588. /if (!(${Me.Aura[1].Equal[${SpellAura2Message}]}) && !(${Me.Aura[2].Equal[${SpellAura2Message}]})) {
  589. /echo Mana Reverb down, casting
  590. /delay 1s
  591. /call cast "${SpellAura2}"
  592. /delay 3s
  593. }
  594. /if (!${Me.Pet.Buff[${SpellStun}]} && ${Me.Pet.ID}) {
  595. /bc Buffing Pet with ${SpellStun}
  596. /call cast "${SpellStun}"
  597. /delay 3s
  598. }
  599. /varset EndOfPath 0
  600. /varset i 1
  601. /if (${Me.PctMana}<15) {
  602. /if (${Me.AltAbilityReady[Mana draw]}) {
  603. /bc Casting Mana Draw for some mana.
  604. /call Cast "Mana draw" alt 10s
  605. /goto :SkipMed
  606. }
  607. /sit
  608. /echo Medding for some Mana....
  609.  
  610. :MedIt
  611.  
  612. /if (${Me.PctMana}<99) /goto :MedIt
  613.  
  614. :SkipMed
  615.  
  616. }
  617.  
  618. :moveloop
  619. /bc [+Y+]Path : [+y+]${CampNum}[+Y+] Point : [+y+]${i} [+x+]
  620. /squelch /moveto loc ${Path[${CampNum},${i},1]} ${Path[${CampNum},${i},2]}
  621. :MoveLoop1
  622. /doevents
  623.  
  624. | This is the grunt of the pulling routine
  625. | This bit is checking for targets while moving....
  626. /varset CheckMob ${SpawnCount[NPC radius ${PullRange} zradius ${zrange} los noalert 1]}
  627. /if (${CheckMob}>${NumberMobsToCheck}) /varset CheckMob ${NumberMobsToCheck}
  628. /if (${CheckMob}) {
  629. /for tt 1 to ${CheckMob}
  630. /doevents
  631. /if (${ReturnGribble}==1 || ${Me.CombatState.Equal[COMBAT]}) {
  632. /varcalc i ${i}-1
  633. /goto :ReturnPath
  634. }
  635. /tar id ${NearestSpawn[${tt}, NPC los radius ${PullRange} zradius ${zrange} noalert 1].ID}
  636. /delay 2s ${Target.ID}==${NearestSpawn[${tt}, NPC los radius ${PullRange} zradius ${zrange} noalert 1].ID}||${Me.CombatState.Equal[COMBAT]}
  637. /if (${Target.Type.Equal[NPC]} && ${Target.LineOfSight}) {
  638. /if (${Zone.ShortName.NotEqual[deadhills_errand]}) {
  639. /bc Not in the correct zone
  640. /bca //end
  641. /end
  642. }
  643. /bc Ethereal Mainpulation [+t+]${Target.Name}
  644. /alt activate 2207
  645. /delay 1
  646. }
  647. /next tt
  648. }
  649.  
  650. /delay 1
  651.  
  652. /if (!${MoveTo.Stopped}) /goto :MoveLoop1
  653.  
  654. | This bit is checking for mobs to pull at the way point.
  655.  
  656. /varset CheckMob ${SpawnCount[NPC radius ${PullRange} zradius ${zrange} los noalert 1]}
  657. /if (${CheckMob}>${NumberMobsToCheck}) /varset CheckMob ${NumberMobsToCheck}
  658. /if (${CheckMob}) {
  659. /for tt 1 to ${CheckMob}
  660. /doevents
  661. /if (${ReturnGribble}==1 || ${Me.CombatState.Equal[COMBAT]}) {
  662. /varcalc i ${i}-1
  663. /goto :ReturnPath
  664. }
  665. /tar id ${NearestSpawn[${tt}, NPC los radius ${PullRange} zradius ${zrange} noalert 1].ID}
  666. /delay 2s ${Target.ID}==${NearestSpawn[${tt}, NPC los radius ${PullRange} zradius ${zrange} noalert 1].ID}||${Me.CombatState.Equal[COMBAT]}
  667. /if (${Target.Type.Equal[NPC]} && ${Target.LineOfSight}) {
  668. /bc Ethereal Manipulation [+t+]${Target.Name}
  669. /if (${Zone.ShortName.NotEqual[deadhills_errand]}) {
  670. /bc Not in the correct zone
  671. /bca //end
  672. /end
  673. }
  674. /alt activate 2207
  675. /delay 4
  676. }
  677. /next tt
  678. }
  679. /varcalc i ${i}+1
  680.  
  681. /if (${Bool[${Path[${CampNum},${i},1]}]}) /goto :moveloop
  682. /delay 1s
  683. /bc End of Path Encounted - No Aggro ${i}
  684. /varset EndOfPath 1
  685. /if (${CampNum}==3) {
  686. /tar Cogwitz
  687. /delay 2s ${Target.Name.Find[Cogwitz]}
  688. /keypress H
  689. /delay 5
  690. /keypress H
  691. }
  692. /varcalc i ${i}-2
  693. :ReturnPath
  694. /stopsong
  695.  
  696. /if (${Me.XTarget} && ${i}<10 && ${CampNum}==3 && ${NearestSpawn[1,NPC noalert 1].Distance}>180) {
  697. /delay 3s ${NearestSpawn[1,NPC noalert 1].Distance}<160 || ${Me.PctHPs}<60
  698. }
  699.  
  700. /if (${i}<1) {
  701. /stopsong
  702. /if (${EndOfPath}==1 && ${CampNum}<3) {
  703. /varcalc CampNum ${CampNum}+1
  704. /varset EndOfPath 0
  705. }
  706. /if (${EndOfPath}==1 && ${CampNum}==3) {
  707. /call ReturnToGribble
  708.  
  709. }
  710. /return
  711. }
  712.  
  713.  
  714. /squelch /moveto loc ${Path[${CampNum},${i},1]} ${Path[${CampNum},${i},2]}
  715.  
  716. :MoveLoop2
  717.  
  718. /delay 1
  719. /doevents
  720.  
  721. /if (!${MoveTo.Stopped}) /goto :MoveLoop2
  722. /varcalc i ${i}-1
  723. /goto :ReturnPath
  724. /return
  725.  
  726.  
  727.  
  728. Sub Event_ToonReady(Line1,ToonName)
  729.  
  730. /varcalc NumReady ${NumReady}+1
  731.  
  732. /return
  733.  
  734. Sub Event_LootingEvent(Line1, ItemName)
  735. /varset ItemName ${ItemName.Right[-57]}
  736. /varset ItemName ${ItemName.Left[-1]}
  737. /bc Item = ${ItemName}
  738. /if (${ItemName.Find[Excavation Tools]} || ${ItemName.Find[Dynamite]} || ${ItemName.Find[Xulous Spellbook]}) {
  739. /bc Click item found = ${ItemName}
  740. /delay 2s
  741. /delay 6s ${Me.CombatState.Equal[COMBAT]}
  742. /bct ${LooterName} //useitem "${ItemName}"
  743. /delay 6s ${Me.CombatState.Equal[COMBAT]}
  744. /bct ${LooterName} //useitem "${ItemName}"
  745. /varset OuterItem ${ItemName}
  746. /varset ReturnGribble 1
  747. }
  748. /return
  749.  
  750. Sub Event_UpdateEvent(Line1, TaskName)
  751.  
  752. /varcalc EventStep ${EventStep}+1
  753. /bc [+m+]${TaskName}[+w+] : finished STEP [+m+]${EventStep}
  754.  
  755. /return
  756.  
  757.  
  758. Sub MemSpells
  759.  
  760. /declare changed int inner 0
  761.  
  762. :SpellChanged
  763. /varset changed 0
  764.  
  765. /echo Memming spells. Hang on.
  766.  
  767. /if (!${Me.Gem[${SpellNuke1}]} ) {
  768. /memspell 1 "${SpellNuke1}"
  769. /bc Memmeing ${SpellNuke1} - Slot 1
  770. /delay 20
  771. /varset changed 1
  772. }
  773.  
  774. /if (!${Me.Gem[${SpellNuke2}]} ) {
  775. /memspell 2 "${SpellNuke2}"
  776. /bc Memming ${SpellNuke2} - Slot 2
  777. /delay 20
  778. /varset changed 1
  779. }
  780.  
  781. /if (!${Me.Gem[${SpellNuke3}]} ) {
  782. /memspell 3 "${SpellNuke3}"
  783. /bc Memming ${SpellNuke3} - Slot 3
  784. /delay 20
  785. /varset changed 1
  786. }
  787.  
  788.  
  789. /if (!${Me.Gem[${SpellMez}]} ) {
  790. /memspell 4 "${SpellMez}"
  791. /bc Memming ${SpellMez} - Slot 4
  792. /delay 20
  793. /varset changed 1
  794. }
  795.  
  796. /if (!${Me.Gem[${SpellAEMez}]} ) {
  797. /memspell 5 "${SpellAEMez}"
  798. /bc Memming ${SpellAEMez} - Slot 5
  799. /delay 20
  800. /varset changed 1
  801. }
  802.  
  803. /if (!${Me.Gem[${SpellRune}]} ) {
  804. /memspell 6 "${SpellRune}"
  805. /bc Memming ${SpellRune} - Slot 6
  806. /delay 20
  807. /varset changed 1
  808. }
  809.  
  810. /if (!${Me.Gem[${SpellCripple}]} ) {
  811. /memspell 7 "${SpellCripple}"
  812. /bc Memming ${SpellCripple} - Slot 7
  813. /delay 20
  814. /varset changed 1
  815. }
  816.  
  817. /if (!${Me.Gem[${SpellDot}]} ) {
  818. /memspell 8 "${SpellDot}"
  819. /bc Memming ${SpellDot} - Slot 8
  820. /delay 20
  821. /varset changed 1
  822. }
  823.  
  824. /if (!${Me.Gem[${SpellStun}]} ) {
  825. /memspell 9 "${SpellStun}"
  826. /bc Memming ${SpellStun} - Slot 9
  827. /delay 20
  828. /varset changed 1
  829. }
  830.  
  831. /if (!${Me.Gem[${SpellTash}]} ) {
  832. /memspell 10 "${SpellTash}"
  833. /bc Memming ${SpellTash} - Slot 10
  834. /delay 20
  835. /varset changed 1
  836. }
  837.  
  838. /if (!${Me.Gem[${SpellAura1}]} ) {
  839. /memspell 11 "${SpellAura1}"
  840. /bc Memming ${SpellAura1} - Slot 11
  841. /delay 20
  842. /varset changed 1
  843. }
  844.  
  845. /if (!${Me.Gem[${SpellAura2}]} ) {
  846. /memspell 12 "${SpellAura2}"
  847. /bc Memming ${SpellAura2} - Slot 12
  848. /delay 20
  849. /varset changed 1
  850. }
  851.  
  852.  
  853. /if (${changed}) {
  854. /varset changed 0
  855. /bc test: spell changed so memming again.
  856. /goto :SpellChanged
  857. }
  858.  
  859. /echo Spells are memmed.
  860.  
  861. /return
  862.  
  863. Sub LoadIni
  864. /if (!${Restart}) {
  865.  
  866. /if (!${Ini[${IniSelfBuff}].Length}) {
  867. /echo Nosuch file ${IniSelfBuff}, creating file.
  868. /echo Please Edit ${IniSelfBuff} and set up your macro.
  869. /ini ${IniSelfBuff} "MySettings" "TankName" "TANKNAMEGOESHERE"
  870. /ini ${IniSelfBuff} "MySettings" "TankMacro" "TANKMACROGOESHERE"
  871. /ini ${IniSelfBuff} "MySettings" "LooterName" "LOOTERNAMEGOESHERE"
  872. /ini ${IniSelfBuff} "MySettings" "LooterMacro" "LOOTERMACROGOESHERE"
  873. /ini ${IniSelfBuff} "MySettings" "Toon1" "TOON1NAMEGOESHERE"
  874. /ini ${IniSelfBuff} "MySettings" "Macro1" "TOON1MACROGOESHERE"
  875. /ini ${IniSelfBuff} "MySettings" "Toon2" "TOON2NAMEGOESHERE"
  876. /ini ${IniSelfBuff} "MySettings" "Macro2" "TOON2MACROGOESHERE"
  877. /ini ${IniSelfBuff} "MySettings" "Toon3" "TOON3NAMEGOESHERE"
  878. /ini ${IniSelfBuff} "MySettings" "Macro3" "TOON3MACROGOESHERE"
  879. /ini ${IniSelfBuff} "MySettings" "NukeAt" "90"
  880. /ini ${IniSelfBuff} "MySettings" "NoNukeAt" "20"
  881. /ini ${IniSelfBuff} "MySettings" "NoDebuffAt" "65"
  882. /ini ${IniSelfBuff} "MySettings" "DoNuke1" "1"
  883. /ini ${IniSelfBuff} "MySettings" "DoNuke2" "1"
  884. /ini ${IniSelfBuff} "MySettings" "DoNuke3" "1"
  885. /ini ${IniSelfBuff} "MySettings" "SpellNuke1" "Mindcleave Rk. II"
  886. /ini ${IniSelfBuff} "MySettings" "SpellNuke2" "Phantasmal Assault Rk. II"
  887. /ini ${IniSelfBuff} "MySettings" "SpellNuke3" "Chromaclash Rk. II"
  888. /ini ${IniSelfBuff} "MySettings" "SpellMez" "Confound Rk. II"
  889. /ini ${IniSelfBuff} "MySettings" "SpellAEMez" "Slackening Wave Rk. II"
  890. /ini ${IniSelfBuff} "MySettings" "SpellRune=Phantasmal Unity Rk. II"
  891. /ini ${IniSelfBuff} "MySettings" "SpellRuneBuff" "Polyiridescent Rune Rk. II"
  892. /ini ${IniSelfBuff} "MySettings" "SpellDot" "Mind Squall Rk. II"
  893. /ini ${IniSelfBuff} "MySettings" "SpellStun" "Dizzying Squall Rk. II"
  894. /ini ${IniSelfBuff} "MySettings" "SpellTash" "Eunciation of Tashan Rk. II"
  895. /ini ${IniSelfBuff} "MySettings" "SpellCripple" "Demolished Consciousness Rk. II"
  896. /ini ${IniSelfBuff} "MySettings" "SpellAura1" "Twincast Aura"
  897. /ini ${IniSelfBuff} "MySettings" "SpellAura1Message" "Twincast Aura"
  898. /ini ${IniSelfBuff} "MySettings" "SpellAura2" "Mana Reverberation Aura Rk. II"
  899. /ini ${IniSelfBuff} "MySettings" "SpellAura2Message" "Mana Rev. Aura Rk. II"
  900. /ini ${IniSelfBuff} "MySettings" "Buff1" "Hastening of Sviir Rk. II"
  901. /ini ${IniSelfBuff} "MySettings" "Buff2" "Voice of Foresight Rk. II"
  902. /ini ${IniSelfBuff} "MySettings" "Buff3" "Shield of the Dauntless Rk. II"
  903. /ini ${IniSelfBuff} "MySettings" "deadhills_errandCampX" "480.4"
  904. /ini ${IniSelfBuff} "MySettings" "deadhills_errandCampY" "-251"
  905. /ini ${IniSelfBuff} "MySettings" "deadhills_errand" "hillsinto.ini"
  906. /ini ${IniSelfBuff} "MyBuffs" "clickitem1" "casttime"
  907. /ini ${IniSelfBuff} "MyBuffs" "clickitem2" "casttime"
  908. /ini ${IniSelfBuff} "MyBuffs" "clickitem3" "casttime"
  909. /ini ${IniSelfBuff} "MyBuffs" "Staff of Eternal Eloquence" "30"
  910. /endmac
  911. } else {
  912. /echo Loading INI settings from ${IniSelfBuff}
  913. /varset NukeAt ${Ini[${IniSelfBuff},MySettings,NukeAt]}
  914. /varset NoNukeAt ${Ini[${IniSelfBuff},MySettings,NoNukeAt]}
  915. /varset NoDebuffAt ${Ini[${IniSelfBuff},MySettings,NoDebuffAt]}
  916. /varset DoNuke1 ${Ini[${IniSelfBuff},MySettings,DoNuke1]}
  917. /varset DoNuke2 ${Ini[${IniSelfBuff},MySettings,DoNuke2]}
  918. /varset DoNuke3 ${Ini[${IniSelfBuff},MySettings,DoNuke3]}
  919. /varset TankName ${Ini[${IniSelfBuff},MySettings,TankName]}
  920. /varset TankMacro ${Ini[${IniSelfBuff},MySettings,TankMacro]}
  921. /varset LooterName ${Ini[${IniSelfBuff},MySettings,LooterName]}
  922. /varset LooterMacro ${Ini[${IniSelfBuff},MySettings,LooterMacro]}
  923. /varset Toon1 ${Ini[${IniSelfBuff},MySettings,Toon1]}
  924. /varset Macro1 ${Ini[${IniSelfBuff},MySettings,Macro1]}
  925. /varset Toon2 ${Ini[${IniSelfBuff},MySettings,Toon2]}
  926. /varset Macro2 ${Ini[${IniSelfBuff},MySettings,Macro2]}
  927. /varset Toon3 ${Ini[${IniSelfBuff},MySettings,Toon3]}
  928. /varset Macro3 ${Ini[${IniSelfBuff},MySettings,Macro3]}
  929. /varset SpellNuke1 ${Ini[${IniSelfBuff},MySettings,SpellNuke1]}
  930. /varset SpellNuke2 ${Ini[${IniSelfBuff},MySettings,SpellNuke2]}
  931. /varset SpellNuke3 ${Ini[${IniSelfBuff},MySettings,SpellNuke3]}
  932. /varset SpellMez ${Ini[${IniSelfBuff},MySettings,SpellMez]}
  933. /varset SpellAEMez ${Ini[${IniSelfBuff},MySettings,SpellAEMez]}
  934. /varset SpellRune ${Ini[${IniSelfBuff},MySettings,SpellRune]}
  935. /varset SpellRuneBuff ${Ini[${IniSelfBuff},MySettings,SpellRuneBuff]}
  936. /varset SpellDot ${Ini[${IniSelfBuff},MySettings,SpellDot]}
  937. /varset SpellStun ${Ini[${IniSelfBuff},MySettings,SpellStun]}
  938. /varset SpellTash ${Ini[${IniSelfBuff},MySettings,SpellTash]}
  939. /varset SpellCripple ${Ini[${IniSelfBuff},MySettings,SpellCripple]}
  940. /varset SpellAura1 ${Ini[${IniSelfBuff},MySettings,SpellAura1]}
  941. /varset SpellAura1Message ${Ini[${IniSelfBuff},MySettings,SpellAura1Message]}
  942. /varset SpellAura2 ${Ini[${IniSelfBuff},MySettings,SpellAura2]}
  943. /varset SpellAura2Message ${Ini[${IniSelfBuff},MySettings,SpellAura2Message]}
  944. /varset Buff1 ${Ini[${IniSelfBuff},MySettings,Buff1]}
  945. /varset Buff2 ${Ini[${IniSelfBuff},MySettings,Buff2]}
  946. /varset Buff3 ${Ini[${IniSelfBuff},MySettings,Buff3]}
  947. /varset CampX ${Ini[${IniSelfBuff},MySettings,${Zone.ShortName}CampX]}
  948. /varset CampY ${Ini[${IniSelfBuff},MySettings,${Zone.ShortName}CampY]}
  949. /varset IniPathFile ${Ini[${IniSelfBuff},MySettings,${Zone.ShortName}]}
  950. /echo IniPathFile set to ${IniPathFile}
  951. /echo INI settings complete.
  952. }
  953. }
  954. /return
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement