cleric.mac
necro.mac
rez.mac
movement.ini
edit:toolismacro.ini
edit:pl.mac
edit2:list of commands for /gui toggle and /gui force goto
hey guys rl got me down for a couple days, caulk should fix this soon
important for casters
/if (${Window[SpellBookWND].Open}) /keypress esc
this goes before :spellsetloop at top of casters macros
prevents them from locking up if you restart macros while casting
ill put example in clr macro
gonna finish invis travel grp movement soon, very sorry
reg zerg travel works /gui force goto zonename
09/20/2015?
|think fixed part where memming spells and screen is black <> 09/07/2015? 3:00am est
bard.mac
-----------
|NOT SAFE FOR LIVE EVER
|edit:NONE OF THESE MACROS ARE SAFE FOR LIVE
|edit:your characters may try to return to camp after death! endless fun
|these are my macros, I have a lot of characters
|bard clr necro is so fun so ill share these ones, im rlly a cleric
|these macros will get you banned on live plz dont
|these macros are slightly broken kind of like search so
|these macros require spellset called level 62 and certain spells on spellbar
|these macros have to have like a /delay 1s before /memspellset level 62
|one of my goals is to play with variables that work when the screen isn't black
Cleric has problems clicking off wrong buffs sometimes trying to click off Spiritual Vigor
this is fun and entertaining, they inform you when spiritual vigor doesn't come off
you could block the spell if you really cared enough
these macros will prolly work with titanium ill check eventually
titanium macroquest and plugins instructions are in eqemu servertransfer macros post
viewforum.php?f=43
underfoot macroquest and plugins instructions are here for now
mq2-20100609 is mq build for underfoot client, its in the wiki - hidden -
http://www.macroquest2.com/downloads/zips.php
spellroutines might work not sure that's hidden in macro snippets\
included my spellroutines in other posts - its way better for running alot
this uses mq2moveutils and mq2twist from vip, donating to mq is good
moveutils for UF I think is june2011 vip plugins development post page 32
moveutils seems to have changed recently mine is 339,968 bytes
moveutils currently has no spaces and is 249,896 bytes
spell_routines for uf I think is 7/05/09 macro snippets- but ill put my own
mq2twist for UF I think is 09/22/09+ vip plugins development
mq2twist is pg26 of post, it is thepost by htw not first posting 09/22/09+....
|
|spell routines is like the only macro I ever read so I learned not easy
|
|my macros are slightly broken they will not switch to the rez macro
|correctly sometimes, its because of them memming spells and I don't
|want an extra second delay for the screen to load when they are rezzed
|I think -right before memspell on all macros or something
|
|the bard will not group invis properly this is easy to fix, I wanted it without
|more variables
|
|the auto movement requires movement.ini I got a lot mapped so far
|you must use /gui force goto zonename or junctionname
|until you fix group invis or I post a fix...
|regular goto zonename is broken after zoning a lot of the time,
|
|bard will sometimes not speed song or invis song, easy fixes starter stuff
|this can prolly be fixed with /delay 12 or 15 or 16 instead of /delay 1s
|because of lag
|you could prolly put some twist offs or w/e to ensure she has stopped
|singing songs - this stuff is in the movement section of the macro
|I tried to do like manual sort of twisting bard songs with least variables
|you can easily fix this stuff
|
| there is toggle commands and movement commands
|
|these macros all load spellset called level 62, they fail without that usually
|they like certain spells on the spellbar|
|toggle is a good read u can easily add toggles if u want, its diff in each
|macro because we don't necessarily have to have /gui toggle stick front
|affecting the clerics and the wizards
|( u may want to add this if u got leet time or tov lewts)
|
|
|my destroy function is (I think very safe) watch out for items when u click
|destroy by accident when waiting for a rez, it reads that as the same
|window, that can prolly be changed if u can get /windows (list windows) to
| work right. the destroy function is good and there is no crazy horrible
|autoinv to drop ur items like that other spell routines...
|
|handle destroy is in the main macros not the uh spell routines... and is
|used for lava orbs, soul orbs, and mod rods... not sure if anything else
| that's all to the best of my memory or whatever thx guys
|
this version of bard does not use spell_routines.inc only reason would be for charm/mez rlly
there is prolly definately ways to make her mez without spell_routines.inc
this bard does not charm/mez yet... unnecessary/dangerous for tanking bard
this is bard.mac
Code: Select all
#turbo 40
#chat tell
#chat group
#chat guild
#Event Follow "#1#tells the#*#, '#2#follow'"
#Event MakeCamp "#*#tells the#*#, '#2#make camp'"
#Event GuildAssist "#1#tells the guild, 'assist me with#*#'"
#Event Enraged "#1# enraged#*#"
#Event Toggle "#1#guild, '#2#toggle#3#'"
#Event Movement "#1#guild, '#2#goto#3#'"
Sub Main
/declare slowsong string outer "Melody of Mischief"
/declare overhastesong string outer "Echo of the Trusik"
/declare resistsong string outer "Psalm of Veeshan"
/declare speedsong string outer "Selo's Accelerating Chorus"
/declare pacisong string outer "Silent Song of Quellious"
/declare travelsong string outer "Selo's Song of Travel"
/declare chorussong string outer "Chorus of Marr"
/declare invulnsong string outer "Kazumi's Note of Preservation"
/declare invissong string outer "Shauri's Sonorous Clouding"
/declare mezsong string outer "Dreams of Terris"
/declare assistat int outer 98
/declare slowsonggem int outer
/declare overhastesonggem int outer
/declare resistsonggem int outer
/declare speedsonggem int outer
/declare pacisonggem int outer
/declare travelsonggem int outer
/declare chorussonggem int outer
/declare invulnsonggem int outer
/declare invissonggem int outer
/declare mezsonggem int outer
/if (!${Me.Book[Echo of the Trusik]}) {
/varset overhastesong "Rizlona's Call of Flame"
}
/if (!${Me.Gem[Chorus of Marr]}) {
/varset chorussong "Warsong of Zek"
}
/varset slowsonggem ${Me.Gem[${slowsong}]}
/varset overhastesonggem ${Me.Gem[${overhastesong}]}
/varset resistsonggem ${Me.Gem[${resistsong}]}
/varset speedsonggem ${Me.Gem[${speedsong}]}
/varset pacisonggem ${Me.Gem[${pacisong}]}
/if (${Me.Gem[${travelsong}]}) /varset travelsonggem ${Me.Gem[${travelsong}]}
/if (${Me.Gem[${invissong}]} && !${Me.Gem[${travelsong}]}) /varset travelsonggem ${Me.Gem[${invissong}]}
/if (${Me.Gem[${invissong}]} && ${Me.Gem[${travelsong}]}) {
/varset travelsonggem ${Me.Gem[${invissong}]}
/echo invis song and travel song both memmed, only 1 song memmed is necessary plz
}
/varset chorussonggem ${Me.Gem[${chorussong}]}
/varset invulnsonggem ${Me.Gem[${invulnsong}]}
/declare assistsongs string outer ${overhastesonggem} ${resistsonggem} ${chorussonggem} ${speedsonggem}
/declare cursorwarningtimer timer outer 0
/declare twistingthis string outer empty
/declare sticktype string outer behindonce loose 8
/declare makecamploc string outer ${Me.Y},${Me.X}
/declare dotwist int outer 1
/declare twistcombat int outer 0
/declare didstick int outer 0
/declare gettarget int outer 1
/declare targetdead int outer 1
/declare targetid int outer 0
/declare didinvis int outer 0
/declare canlev int outer 1
/declare ammoving int outer 0
/squelch /stick off
/squelch /assist off
/declare mainassist string outer
/varset mainassist ${Param0}
/if (${Defined[Param0]}) {
/echo My main assist is set to ${mainassist}
} else {
/echo This Macro needs a Main assist to run ... try /mac monk Tanksname .... case counts
/end
}
/echo bard macro started
:spellsetloop
/if (${NearestSpawn[PC ${Me.Name}].Name.Find[${Me.Name}]}) {
/memspellset level 62
/delay 46s !${Window[SpellBookWND].Open}
}
/delay 2
/if (!${NearestSpawn[PC ${Me.Name}].Name.Find[${Me.Name}]}) /goto :spellsetloop
:bardloop
/if (${ammoving}) /call travelstuff
/if (!${ammoving} && ${dotwist}) /call dotwist
/if (!${ammoving}) /call cleartarget
/if (${gettarget} && !${ammoving}) /call gettarget
/if (${targetid} == ${Target.ID}) /call killtarg
/if (!${ammoving} && !${Me.CombatState.Equal[COMBAT]}) /call autoprotectstuff
/if (!${ammoving} && ${Bool[${leashloc}]}) /call gotoloc
/call checkstuff
/doevents
/delay 2
/goto :bardloop
Sub travelstuff
/if (${Cursor.ID} && !${cursorwarningtimer}) {
/echo i cant travel through lev / no lev zones properly with shit on my cursor
/guildsay i cant travel through lev / no lev zones properly with shit on my cursor
/varset cursorwarningtimer 100
}
/if (!${didinvis} && ${canlev}) {
/if (!${Me.Gem[${travelsong}]} && !${Cursor.ID}) {
/guildsay sec memming invis travel song
/memspell ${travelsonggem} ${travelsong}
/delay 2s
}
/twist ${travelsonggem}
/varset didinvis 1
/varset twistcombat 0
}
/if (!${didinvis} && !${canlev}) {
/if (!${Me.Gem[${invissong}]} && !${Cursor.ID}) {
/guildsay sec memming invis song
/memspell ${travelsonggem} ${invissong}
/delay 2s
}
/call groupcheck
/if (${Macro.Return.Equal[1]}) {
/twist ${speedsonggem}
/delay 3s
/twist ${travelsonggem}
/varset didinvis 1
/varset twistcombat 0
}
}
/return
Sub dotwist
/if (${twistingthis.NotEqual[empty]}) {
/twist ${twistingthis}
/varset dotwist 0
/varset twistcombat 1
/varset twistingthis empty
/return
}
/twist ${assistsongs}
/varset dotwist 0
/varset twistcombat 1
/return
Sub gettarget
/call getids "${mainassist}"
/if (${Spawn[${Macro.Return}].ID} && ${Spawn[id ${Macro.Return}].Distance} < 200) {
/target ID ${Macro.Return}
/delay 2
/assist
/delay 2
/if (${Target.Type.Equal[NPC]} && ${Target.Type.NotEqual[CORPSE]} && ${Target.PctHPs} < ${assistat} && ${Target.Distance} < 200) {
/varset targetid ${Target.ID}
/varset targetdead 0
/varset gettarget 0
/varset didstick 0
/g assisting on %t
/echo My Target is now ${Target.CleanName}
/if (${Me.Pet.ID}) /pet attack
}
}
/return
Sub killtarg
/if (!${didstick} && ${Target.Type.Equal[NPC]} && ${Target.ID} == ${targetid}) {
/face fast nolook id ${targetid}
/attack on
/stick ${sticktype}
/if (${Me.Pet.ID}) /pet attack
/varset didstick 1
/delay 2
}
/if (${Me.PctHPs}<30 && ${Me.CombatAbilityReady["Deftdance Discipline"]}) {
/varset twistingthis ${Twist.List}
/twist off
/doability "Deftdance Discipline"
/varset dotwist 1
}
/if (${Me.PctHPs}<15 && ${Me.CurrentMana} > 900) {
/echo i am at ${Me.PctHPs} percent and fading
/guildsay i am at ${Me.PctHPs} percent and fading
/varset twistingthis ${Twist.List}
/twist off
/attack off
/aa act Fading Memories
:waitloop
/delay 2s
/if (${Me.PctHPs} > 90) {
/guildsay i am fighting as normal
/attack on
/varset dotwist 1
} else {
/goto :waitloop
}
}
/return
Sub cleartarget
/if (${Spawn[${targetid}].Type.Equal[CORPSE]} && !${targetdead} || !${Spawn[${targetid}].Type.Equal[NPC]} && !${targetdead}) {
/varset targetdead 1
/varset gettarget 1
/varset didstick 0
/attack off
/if (${Me.CombatState.NotEqual[COMBAT]} && !${NearestSpawn[1,npc radius 50].ID}) /call returntocamp "face"
/if (${Target.ID} != ${targetid} && ${Spawn[${targetid}].Type.NotEqual[CORPSE]} && ${Spawn[${targetid}].ID}) /target ID ${targetid}
}
/return
Sub autoprotectstuff
/if (${twistingthis.Equal[empty]} && ${Twist.List} != ${assistsongs}) {
/varset twistingthis ${Twist.List}
}
/return
Sub checkstuff
/if (${Cursor.Name.Equal[Rod of Mystical Transvergence]}) {
/if (${Me.FreeInventory} < 1) {
/guildsay mod rod on cursor but no inventory room
/return
}
/if (${Me.FreeInventory} > 1) /autoinv
}
/if (!${Me.Invis}) {
/if (${FindItem[=Rod of Mystical Transvergence].ID}) {
/if (!${FindItem[=Rod of Mystical Transvergence].TimerReady}) {
/if (!${Cursor.ID} && ${Me.PctMana} < 85 && ${Me.CurrentHPs} > 4000) {
/call clickitem "Rod of Mystical Transvergence" "inv"
}
}
}
}
/if (!${InvSlot[13].Item.ID}) {
/if (!${InvSlot[17].Item.ID}) {
/if (${Zone.ShortName.Equal[poknowledge]} || ${Zone.ShortName.Equal[guildlobby]} || !${InvSlot[18].Item.ID}) {
/if (${MacroQuest.GameState.NotEqual[INGAME]}) /return
/if (!${Me.Gem[8].ID}) {
:spellsetloop
/if (${NearestSpawn[PC ${Me.Name}].Name.Find[${Me.Name}]}) {
/memspellset level 62
/delay 46s !${Window[SpellBookWND].Open}
}
/delay 2
/if (!${NearestSpawn[PC ${Me.Name}].Name.Find[${Me.Name}]}) /goto :spellsetloop
}
/if (!${Defined[amnaked]}) /declare amnaked int local 100
/if (!${Window[SpellBookWnd].Open}) /guildsay <==== i died ====>
/if (!${Window[SpellBookWnd].Open} && ${Defined[amnaked]}) /docommand /mac rez ${mainassist} ${amnaked}
/if (!${Window[SpellBookWnd].Open}) /docommand /mac rez ${mainassist}
}
}
}
/return
Sub getids(string name)
/declare SpawnID int local
/declare SpawnName string local
/declare i int local
/for i 1 to 4
/varset SpawnID ${NearestSpawn[${i}, pc ${name}].ID}
/varset SpawnName ${NearestSpawn[${i}, pc ${name}]}
/if (${NearestSpawn[${i}, pc ${name}].Name.Equal[${name}]}) /return ${SpawnID}
/next i
/return 0
Sub Event_Follow(Line, FollowTarget, ChatText)
/if (!${Bool[${ChatText}]}) {
/varset FollowTarget ${FollowTarget.Right[-2].Left[-2]}
/call getids "${FollowTarget}"
/if (${Spawn[id ${Macro.Return}].ID} && ${Spawn[id ${Macro.Return}].Distance} < 200) {
/target ID ${Macro.Return}
/delay 2
/if (${Target.Type.Equal[PC]}) {
/varset ammoving 1
/keypress w
/face fast
/stick loose 5
}
}
/return
}
/if (${ChatText.Find[group]}) {
/varset ChatText ${ChatText.Right[-6]}
/call findgroup
/declare i int local
/for i 1 to ${Ini[toolismacro,Values,totalgroups]}
/if (${Macro.Return} == ${ChatText.Arg[${i},,]}) {
/varset FollowTarget ${FollowTarget.Right[-2].Left[-2]}
/call getids "${FollowTarget}"
/if (${Spawn[id ${Macro.Return}].ID} && ${Spawn[id ${Macro.Return}].Distance} < 200) {
/target ID ${Macro.Return}
/delay 2
/if (${Target.Type.Equal[PC]}) {
/varset ammoving 1
/keypress w
/face fast
/stick loose 5
}
}
}
/next i
/return
}
/if (${ChatText.Find[healers]}) {
/if (${Me.Class.HealerType}) {
/varset FollowTarget ${FollowTarget.Right[-2].Left[-2]}
/call getids "${FollowTarget}"
/if (${Spawn[id ${Macro.Return}].ID} && ${Spawn[id ${Macro.Return}].Distance} < 200) {
/target ID ${Macro.Return}
/delay 2
/if (${Target.Type.Equal[PC]}) {
/varset ammoving 1
/keypress w
/face fast
/stick loose 5
}
}
}
/return
}
/if (${ChatText.Find[${Me.Name}]}) {
/declare i int local
/for i 1 to 12
/if (${ChatText.Arg[${i},].Equal[${Me.Name}]}) {
/varset FollowTarget ${FollowTarget.Right[-2].Left[-2]}
/call getids "${FollowTarget}"
/if (${Spawn[id ${Macro.Return}].ID} && ${Spawn[id ${Macro.Return}].Distance} < 200) {
/target ID ${Macro.Return}
/delay 2
/if (${Target.Type.Equal[PC]}) {
/varset ammoving 1
/keypress w
/face fast
/stick loose 5
}
}
}
/next i
/return
}
/return
Sub Event_MakeCamp(Line, ChatText)
/if (${ChatText.Find[group]}) {
/varset ChatText ${ChatText.Right[-6]}
/call findgroup
/if (${Macro.Return.Equal[${ChatText}]}) {
/stick off
/varset ammoving 0
/varset dotwist 1
/varset makecamploc ${Me.Y},${Me.X}
}
/return
}
/stick off
/varset ammoving 0
/varset dotwist 1
/varset makecamploc ${Me.Y},${Me.X}
/return
Sub Event_GuildAssist(Line, AssistTarget)
/varset AssistTarget ${AssistTarget.Right[-2].Left[-2]}
/call getids "${AssistTarget}"
/if (${Macro.Return} && ${Spawn[id ${Macro.Return}].Distance} < 200) {
/target ID ${Macro.Return}
/delay 2
/assist
/delay 4
/if (${Target.Type.Equal[NPC]} && ${Target.Type.NotEqual[CORPSE]} && ${Target.Distance} < 200) {
/varset targetid ${Target.ID}
/varset gettarget 0
/varset targetdead 0
/varset didstick 0
/if (!${twistcombat}) /varset didtwist 0
/echo My Target is now ${Target.CleanName}
/if (${Me.Pet.ID}) /pet back off
/if (${Me.Pet.ID}) /delay 5
/if (${Me.Pet.ID}) /pet attack
}
}
/return
Sub Event_Enraged(Line, ChatText)
/echo Event enraged fired
/if (${ChatText.Find[has become]}) {
/varset ChatText ${ChatText.Left[-11]}
/if (${NearestSpawn[npc radius 200 "${ChatText}"].ID} == ${targetid}) {
/declare mobheading float local ${Spawn[id ${targetid}].Heading.Degrees}
/if (${mobheading} < 90 && ${Me.Heading.Degrees} < ${Math.Calc[360 -(90 - ${mobheading})]} && ${Me.Heading.Degrees} > ${Math.Calc[${mobheading} - 90]} || ${mobheading} > 270 && ${Me.Heading.Degrees} < ${Math.Calc[${mobheading} - 90]} && ${Me.Heading.Degrees} > ${Math.Calc[90 -(360 - ${mobheading}]}) || ${Me.Heading.Degrees} > ${Math.Calc[${mobheading} + 90]} || ${Me.Heading.Degrees} < ${Math.Calc[${mobheading} - 90]}) /return
/echo >>> ${Spawn[${targetid}].CleanName} is Enraged <<<
/attack off
}
/doevents flush Enraged
/return
}
/if (${ChatText.Find[is no longer]}) {
/varset ChatText ${ChatText.Left[-13]}
/if (${NearestSpawn[npc radius 200 "${ChatText}"].ID} == ${targetid}) {
/echo >>> ${Spawn[${targetid}].CleanName} is no longer Enraged! <<<
/attack on
}
}
/doevents flush Enraged
/return
Sub clickitem(ClickItem, ReplaceSlot)
/if (${ReplaceSlot.Find[inv]}) /declare targetslot string local 100
/if (!${ReplaceSlot.Find[inv]}) /declare targetslot int local ${ReplaceSlot}
/if (!${Defined[ClickItem]}) {
/echo target item not defined - returning
/return
}
/if (!${Defined[ReplaceSlot]}) {
/echo replace slot not defined - inv or slot # plz -returning
/return
}
/if (${Cursor.ID}) {
/guildsay trying to click item but stuff is on my cursor
/return
}
/if (${FindItem[=${ClickItem}].ID} && !${Cursor.ID}) {
/declare castingtime float local ${FindItem[=${ClickItem}].CastTime}
/declare slotnumber int local
/declare packnumber int local
/declare i int local
/declare j int local
/for i 1 to 8
/for j 1 to 10
/if (${InvSlot[Pack${i}].Item.Item[${j}].Name.Equal[${ClickItem}]}) {
/echo found item in bag
/varset packnumber ${i}
/varset slotnumber ${j}
/goto :click
}
/next j
/varset j 0
/next i
/varset i 0
/for i 1 to 8
/if (${InvSlot[${Math.Calc[22 + ${i}]}].Item.Name.Equal[${ClickItem}]}) {
/echo found item in main slot
/varset packnumber ${i}
/varset targetslot pack${packnumber}
/declare invitem int local 1
/goto :click
}
/next i
/varset i 0
:click
/if (!${Window[InventoryWindow].Open}) /keypress i
/if (!${Window[pack${packnumber}].Open} && !${Defined[invitem]}) /nomodkey /itemnotify pack${packnumber} rightmouseup
/delay 2
/if (!${Defined[invitem]}) /nomodkey /itemnotify in pack${packnumber} ${slotnumber} leftmouseup
/if (${Defined[invitem]}) {
/echo using ${ClickItem}
/nomodkey /itemnotify ${InvSlot[${Math.Calc[22 + ${packnumber}]}]} rightmouseup
/delay 2
/if (${castingtime} > 0.50) /delay ${Math.Calc[${castingtime} * 10]}
/keypress i
/deletevar invitem
/return
}
/delay 2
/if (${Cursor.Name.Equal[${ClickItem}]}) {
/echo Using ${ClickItem}
/if (${Defined[targetslot]}) /varset targetslot ${InvSlot[${targetslot}]}
/if (${targetslot} == 100) /varset targetslot pack${packnumber}
/nomodkey /itemnotify ${targetslot} leftmouseup
/delay 2
/nomodkey /itemnotify ${targetslot} rightmouseup
/if (${castingtime} > 0.50) /delay ${Math.Calc[${castingtime} * 10]}
/delay 4
/if (!${ReplaceSlot.Find[inv]}) /nomodkey /itemnotify ${InvSlot[${targetslot}]} leftmouseup
/if (${ReplaceSlot.Find[inv]}) /nomodkey /itemnotify ${InvSlot[${Math.Calc[22 + ${packnumber}]}]} leftmouseup
/delay 4
/if (${Cursor.Name.Equal[${ClickItem}]}) {
/nomodkey /itemnotify pack${packnumber} rightmouseup
/delay 2
/nomodkey /itemnotify in pack${packnumber} ${slotnumber} leftmouseup
/delay 2
/nomodkey /itemnotify pack${packnumber} rightmouseup
/delay 2
}
}
/keypress i
}
/return
Sub handledestroy(TargetItem)
/if (!${Defined[TargetItem]}) {
/echo target item not defined, returning
/return
}
/if (${FindItem[=${TargetItem}].ID} && !${Cursor.ID}) {
/declare slotnumber int local
/declare packnumber int local
/declare i int local
/declare j int local
/for i 1 to 8
/for j 1 to 10
/if (${InvSlot[Pack${i}].Item.Item[${j}].Name.Equal[${TargetItem}]}) {
/echo item is in pack
/varset packnumber ${i}
/varset slotnumber ${j}
/goto :destroy
}
/next j
/varset j 0
/next i
/varset i 0
/for i 1 to 8
/if (${InvSlot[${Math.Calc[22 + ${i}]}].Item.Name.Equal[${TargetItem}]}) {
/echo found item in main slot
/varset packnumber ${i}
/declare invitem int local 1
/goto :destroy
}
/next i
/varset i 0
:destroy
/if (!${Window[InventoryWindow].Open}) /keypress i
/if (!${Window[pack${packnumber}].Open} && !${Defined[invitem]}) /nomodkey /itemnotify pack${packnumber} rightmouseup
/delay 2
/if (!${Defined[invitem]}) /nomodkey /itemnotify in pack${packnumber} ${slotnumber} leftmouseup
/if (${Defined[invitem]}) /nomodkey /itemnotify pack${packnumber} leftmouseup
/delay 2
/if (${Cursor.Name.Equal[${TargetItem}]}) {
/echo destroying ${TargetItem}
/if (${Cursor.Name.Equal[${TargetItem}]}) {
/echo destroying ${Cursor.Name}
/destroy
/if (${Defined[invitem]}) /deletevar invitem
}
}
/if (${Window[pack${packnumber}].Open}) /nomodkey /itemnotify pack${packnumber} rightmouseup
/delay 2
/keypress i
}
/return
Sub Event_Toggle(Line, ChatSender, Targets, action)
/if (!${Bool[${action}]}) /return
/if (${Bool[${Targets}]}) {
/if (${Targets.Arg[1,].Equal[group]}) {
/if (${Targets.Arg[1,].Equal[group]}) {
/declare groupnumber int local
/call findgroup
/varset Targets ${Targets.Right[-6]}
/for groupnumber 1 to ${Ini[toolismacro,Values,totalgroups]}
/if (${Targets.Arg[${groupnumber},,]} == ${Macro.Return}) {
/goto :togglestuff
} else {
/next groupnumber
/return
}
}
}
/if (${Targets.Arg[1,].Equal[healers]}) {
/if (${Me.Class.HealerType}) /goto :togglestuff
/return
}
/if (${Targets.Arg[1,].Equal[casters]}) {
/if (${Me.Class.PureCaster}) /goto :togglestuff
/return
}
/declare name int local
/for name 1 to 12
/if (${Targets.Arg[${name},].Equal[${Me.Name}]}) /goto :togglestuff
/next name
/return
}
:togglestuff
/if (${action.Find[abort]}) {
/keypress forward
/varset didinvis 0
/guildsay !ABORTING!
/return abort
}
/if (${action.Arg[1,].Equal[leash]}) {
/varset action ${action.Right[-6]}
/if (${Bool[${Ini[movement,leash,${action}]}]}) {
/if (!${Defined[leashloc]}) /declare leashloc string outer
/declare i int local
/for i 1 to 10
/if (${Ini[movement,leash,zoneshortnames].Arg[${i},,].Equal[${Zone.ShortName}]}) {
/varset leashloc ${Ini[movement,leash,${action}]}
}
/next i
}
/return
}
/if (${action.Arg[1,].Equal[zoneout]}) {
/varset action ${action.Right[-8]}
/if (${Bool[${Ini[movement,zoneout,${action}]}]}) {
/if (!${Defined[zoneoutloc]}) /declare zoneoutloc string outer
/declare i int local
/for i 1 to 10
/if (${Ini[movement,zoneout,zoneshortnames].Arg[${i},,].Equal[${Zone.ShortName}]}) {
/if (!${Defined[zoneoutcommand]}) /declare zoneoutcommand string outer empty
/if (${Bool[${Ini[movement,zoneout,${action}command]}]}) /varset zoneoutcommand ${Ini[movement,zoneout,${action}command]}
/varset zoneoutloc ${Ini[movement,zoneout,${action}]}
/call gotoloc "${zoneoutloc}" "${zoneoutcommand}"
/return
}
/next i
}
/return
}
/if (${action.Arg[1,].Equal[leashoff]}) {
/if (${Defined[leashloc]}) /deletevar leashloc
/return
}
/if (${action.Arg[1,].Equal[tank]}) {
/if (${action.Arg[1,].Equal[tank]}) /varset action ${action.Right[-5]}
/varset mainassist ${action}
/return
}
/if (${action.Find[/mac]}) {
/varset action ${action.Right[-5]}
/if (${action.Arg[1,].Equal[start]}) {
/varset action ${action.Right[-6]}
/if (${Me.Class.Name.Equal[Beastlord]}) /docommand /mac beast ${action}
/if (${Me.Class.Name.Equal[Shadowknight]}) /docommand /mac sk ${action}
/if (${Me.Class.Name.Equal[Magician]}) /docommand /mac mage ${action}
/if (${Me.Class.Name.Equal[Necromancer]}) /docommand /mac necro ${action}
/if (${Me.Class.Name.Equal[Wizard]}) /docommand /mac wiz ${action}
/if (${Me.Class.Name.Equal[Enchanter]}) /docommand /mac ench ${action}
/if (${Me.Class.Name.Equal[Bard]}) /docommand /mac bard ${action}
/if (${Me.Class.Name.Equal[Cleric]}) /docommand /mac cleric ${action}
/if (${Me.Class.Name.Equal[Shaman]}) /docommand /mac shaman ${action}
/if (${Me.Class.Name.Equal[Monk]}) /docommand /mac monk ${action}
/if (${Me.Class.Name.Equal[Rogue]}) /docommand /mac rogue ${action}
/if (${Me.Class.Name.Equal[Paladin]}) /docommand /mac paladin ${action}
/if (${Me.Class.Name.Equal[Ranger]}) /docommand /mac ranger ${action}
/if (${Me.Class.Name.Equal[Berserker]}) /docommand /mac berserker ${action}
/if (${Me.Class.Name.Equal[Druid]}) /docommand /mac druid ${action}
}
/declare i int local
/for i 1 to 15
/if (${Ini[toolismacro,Values,macros].Arg[${i},,].Equal[${action.Arg[1,]}]}) {
/docommand /mac ${action}
}
/next i
/varset i 0
/for i 1 to 10
/if (${Ini[toolismacro,Values,othermacros].Arg[${i},,].Equal[${action.Arg[1,]}]}) {
/docommand /mac ${action}
}
/next i
/echo Macro not found
/return
}
/if (${action.Find[mod rod]}) {
/if (${Cursor.ID}) {
/guildsay ITEM ON CURSOR - MOD RODS COMING
/return
}
/if (${Me.FreeInventory} < 1 && !${FindItem[=Rod of Mystical Transvergence].ID}) {
/guildsay NO ROOM IN BAGS - MOD RODS COMING
/return
}
/if (${FindItem[=Rod of Mystical Transvergence].ID} && ${FindItem[=Rod of Mystical Transvergence].Charges} < 3) /call handledestroy "Rod of Mystical Transvergence"
/return
}
/if (${action.Find[accept rez]}) {
/if (${Window[ConfirmationDialogBox].Open} || !${InvSlot[13].Item.ID}) {
/docommand /mac rez ${mainassist}
}
/return
}
/if (${action.Find[consent]}) {
/varset action ${action.Right[-8]}
/consent ${action}
/return
}
/if (${action.Find[stick]}) {
/if (${action.Find[front]}) {
/echo sticking in front
/varset sticktype front loose 8
}
/if (${action.Find[behind]}) {
/echo sticking behind
/varset sticktype behindonce loose 8
}
/return
}
/if (${action.Find[/ex]}) {
/if (${Me.Trader}) /return
/docommand /exit
}
/if (${action.Find[pagedown]}) {
/keypress Page_Down hold
/delay 1s
/keypress Page_Down
/return
}
/if (${action.Find[anon]}) {
/docommand /a
/return
}
/if (${action.Find[assistat]}) {
/echo setting assistat to ${action.Arg[2,]}
/varset assistat ${action.Arg[2,]}
/if (${Defined[nukeat]}) /varset nukeat ${action.Arg[2,]}
/return
}
/if (${action.Find[camp]}) {
/if (${Me.Trader}) /return
/if (${action.Find[desktop]}) {
/camp desktop
:action
/doevents toggle
/if (${Macro.Return.Equal[cancel]}) /return
/delay 2
/goto :action
/return
}
/camp
:action
/doevents toggle
/if (${Macro.Return.Equal[cancel]}) /return
/delay 2
/goto :action
/return
}
/if (${action.Find[cancel]}) {
/return cancel
}
/if (${action.Find[speed]}) {
/twist off
/guildsay inc speed song
/twist ${speedsonggem}
/delay 3s
/varset dotwist 1
/varset didinvis 0
/return
}
/if (${action.Find[throne]}) {
/twist off
/delay 2
/varset dotwist 1
/aa act Throne of Heroes
/return
}
/if (${action.Find[infusion]}) {
/twist off
/delay 2
/varset dotwist 1
/aa act Infusion of the Faithful
/return
}
/if (${action.Find[lesson]}) {
/twist off
/delay 2
/varset dotwist 1
/aa act Lesson of the Devoted
/return
}
/if (${action.Find[intensity]}) {
/twist off
/delay 2
/varset dotwist 1
/aa act Intensity of the Resolute
/return
}
/if (${action.Find[expedient]} || ${action.Find[expediant]}) {
/twist off
/delay 2
/varset dotwist 1
/aa act Expedient Recovery
/return
}
/return
Sub page(direction, duration)
/if (${direction.Find[down]}) {
/keypress Page_Down hold
/delay ${duration}
/keypress Page_Down
}
/if (${direction.Find[up]}) {
/keypress Page_Up hold
/delay ${duration}
/keypress Page_Up
}
/return
Sub returntocamp(face)
/if (${Bool[${makecamploc}]}) {
/declare nextlocationyhigh int local ${Math.Calc[${makecamploc.Arg[1,,]} + 145]}
/declare nextlocationylow int local ${Math.Calc[${makecamploc.Arg[1,,]} - 145]}
/declare nextlocationxhigh int local ${Math.Calc[${makecamploc.Arg[2,,]} + 145]}
/declare mnextlocationxlow int local ${Math.Calc[${makecamploc.Arg[2,,]} - 145]}
/if (${Me.Y} < ${nextlocationyhigh} && ${Me.Y} > ${nextlocationylow} && ${Me.X} < ${nextlocationxhigh} && ${Me.X} > ${nextlocationxlow}) {
/call gotoloc "${makecamploc}"
/if (${Macro.Return} == 1 && ${face.Equal[face]}) {
/if (${Me.Heading.Degrees} > 179) /face fast heading ${Math.Calc[${Me.Heading.Degrees} - 180]}
/if (${Me.Heading.Degrees} < 180) /face fast heading ${Math.Calc[${Me.Heading.Degrees} + 180]}
}
}
}
/return
Sub gotoloc(loc, command)
/declare locfrom string local
/declare zoneshortname string local ${Zone.ShortName}
/if (!${Bool[${loc}]}) /varset locfrom leashloc
/if (${Bool[${loc}]}) /varset locfrom loc
/declare nextlocationy string local ${${locfrom}.Arg[1,,]}
/declare nextlocationx string local ${${locfrom}.Arg[2,,]}
/declare nextlocationyhigh string local ${Math.Calc[${${locfrom}.Arg[1,,]} + 5]}
/declare nextlocationylow string local ${Math.Calc[${${locfrom}.Arg[1,,]} - 5]}
/declare nextlocationxhigh string local ${Math.Calc[${${locfrom}.Arg[2,,]} + 5]}
/declare nextlocationxlow string local ${Math.Calc[${${locfrom}.Arg[2,,]} - 5]}
/if (${nextlocationy.NotEqual[NULL]} && ${Me.Y} <= ${nextlocationyhigh} && ${Me.Y} >= ${nextlocationylow} && ${Me.X} <= ${nextlocationxhigh} && ${Me.X} >= ${nextlocationxlow}) {
/if (${command.NotEqual[empty]}) /call ${command}
/return
}
:travel
/keypress forward hold
/if (${nextlocationy.NotEqual[NULL]} && ${Me.Y} <= ${nextlocationyhigh} && ${Me.Y} >= ${nextlocationylow} && ${Me.X} <= ${nextlocationxhigh} && ${Me.X} >= ${nextlocationxlow}) {
/keypress forward
/if (!${Me.Class.PureCaster}) /varset didstick 0
/if (${command.NotEqual[empty]}) /call ${command}
/return 1
}
/if (${nextlocationy.NotEqual[NULL]}) {
/if (${Me.Y} <= ${nextlocationylow} || ${Me.X} <= ${nextlocationxlow} || ${Me.Y} >= ${nextlocationyhigh} || ${Me.X} >= ${nextlocationxhigh}) {
/face nolook fast loc ${nextlocationy},${nextlocationx}
|/if (!${Me.Moving}) /timed 10 /call stuck
}
}
/if (${zoneshortname.NotEqual[${Zone.ShortName}]}) {
/if (!${InvSlot[17].Item.ID}) {
/if (!${InvSlot[13].Item.ID} && !${Defined[amnaked]}) {
/guildsay - i died during movement -
/declare amnaked int outer 100
/keypress forward
/if (${Defined[stuckdirection]}) /deletevar stuckdirection
/varset makecamploc ${Me.Y},${Me.X}
/return
}
}
}
/if (${zoneshortname.NotEqual[${Zone.ShortName}]}) {
/if (${InvSlot[17].Item.ID} || ${amnaked} == 100) {
/if (${InvSlot[13].Item.ID} && !${Defined[amnaked]} || !${InvSlot[13].Item.ID} && ${amnaked} == 100) {
/echo ~~ ${Zone.Name} ~~
/keypress forward
/deletevar zoneoutloc
/if (${Defined[stuckdirection]}) /deletevar stuckdirection
/varset makecamploc ${Me.Y},${Me.X}
/return
}
}
/return
}
/delay 1
/goto :travel
/return
Sub zonedoor
/keypress forward
:doorloop
/keypress u
/delay 2
/keypress u
/delay 1s
/keypress u
/delay 2
/call viewing
/if (${zoneshortname.Equal[${Zone.ShortName}]}) /goto :doorloop
/return
Sub door
/keypress u
/if (!${Me.Moving}) {
/if (${Bool[${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc[${j}]door]}]}) {
/doortarget ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc[${j}]door]}]}
/face door
/keypress u
}
}
/return
Sub stuck(direction)
/if (${Me.Moving} /return
/if (${Defined[stuckdirection]}) /varset stuckdirection right
/if (!${Defined[stuckdirection]}) /declare stuckdirection string outer left
/keypress back hold
/delay 5
/keypress back
/if (${Me.Heading.Degrees} < 40 && ${direction.Equal[left]} || ${Me.Heading.Degrees} > 320 && ${direction.Equal[right]}) {
/if (${direction.Equal[right]}) {
/face fast heading ${Math.Calc[360 - ${Me.Heading.Degrees}]}
/goto :move
}
/if (${direction.Equal[left]}) {
/face fast heading ${Math.Calc[40 - ${Me.Heading.Degrees}]}
/goto :move
}
}
/if (${direction.Equal[right]}) {
/face fast heading ${Math.Calc[${Me.Heading.Degrees} + 40]}
}
/if (${direction.Equal[left]}) {
/face fast heading ${Math.Calc[${Me.Heading.Degrees} - 40]}
}
:move
/keypress forward hold
/delay 8
/keypress forward
/if (${Defined[stuckdirection]}) {
/if (${stuckdirection.Equal[right]}) /deletevar stuckdetection
}
/guildsay got stuck and attempted to move
/return
Sub viewing
/declare variable string local page_down
:viewing
/if (${zoneshortname.Equal[${Zone.ShortName}]}) {
/keypress ${variable} hold
/delay 2
/keypress ${variable}
/keypress u
/if (${zoneshortname.Equal[${Zone.ShortName}]}) {
/keypress ${variable} hold
/delay 4
/keypress ${variable}
/keypress u
/if (${zoneshortname.Equal[${Zone.ShortName}]}) {
/keypress ${variable} hold
/delay 4
/keypress ${variable}
/keypress u
/if (${variable.Equal[page_down]}) {
/varset variable page_up
/goto :viewing
}
/if (${variable.Equal[page_up]}) {
/varset variable page_down
/goto :viewing
}
}
}
}
/return
Sub findgroup
/declare totalgroups int local
/declare i int local
/declare j int local
/varset totalgroups ${Ini[toolismacro,Values,totalgroups]}
/for i 1 to ${totalgroups}
/for j 1 to 6
/if (${Ini[toolismacro,Group${i},member${j}].Equal[${Me.Name}]}) {
/return ${i}
}
/next j
/next i
/echo GROUP NOT FOUND ---- returning +1
/return ${Math.Calc[${totalgroups} + 1]}
Sub groupcheck
/declare i int local
/declare grpcheck int local 0
:checkgroup
/for i 0 to ${Group}
/if (${Group.Member[${i}].Distance} < 120 && ${Group.Member[${i}].ID}) /varset grpcheck ${Math.Calc[${grpcheck} + 1]}
/next i
/if (${grpcheck} == ${Group.GroupSize}) {
/delay 1s
/return 1
} else {
/varset grpcheck 0
/delay 2
/goto :checkgroup
}
/return
Sub Event_Movement(Line, SenderPerson, targetperson, TargetZone)
/if (${Bool[${targetperson}]}) {
/declare name int local
/declare force int local
/for force 1 to 10
/if (${targetperson.Arg[${force},].Equal[force]}) {
/declare forcemove bool local TRUE
}
/if (${targetperson.Arg[1,].Equal[force]} && !${Bool[${targetperson.Arg[2,]}]}) /goto :beginning
/next force
/if (${targetperson.Arg[1,].Equal[group]}) {
/if (${targetperson.Arg[1,].Equal[group]}) {
/declare groupnumber int local
/call findgroup
/varset targetperson ${targetperson.Right[-6]}
/if (${targetperson.Find[force]}) /varset targetperson ${targetperson.Left[-6]}
/for groupnumber 1 to ${Ini[toolismacro,Values,totalgroups]}
/if (${targetperson.Arg[${groupnumber},,]} == ${Macro.Return}) {
/goto :beginning
} else {
/next groupnumber
/return
}
}
}
/for name 1 to 10
/if (${targetperson.Arg[${name},].Equal[${Me.Name}]}) /goto :beginning
/next name
/return
}
:beginning
/if (!${Bool[${Ini[movement,${TargetZone},zoneshortnames].Arg[1,,]}]}) {
/echo Incorrect Destination
/return
}
/declare zoneshortname string local ${Zone.ShortName}
/declare savedtargetzone string local ${TargetZone}
/declare startlocation string local 0
/declare tempheading float local 0
/declare nextlocationx string local NULL
/declare nextlocationy string local NULL
/declare nextlocationxhigh string local
/declare nextlocationxlow string local
/declare nextlocationyhigh string local
/declare nextlocationylow string local
/declare i int local
/declare j int local
/declare junctions int local
/declare savedvariable int local 0
/if (${Me.Class.Name.NotEqual[Bard]}) /declare didinvis int local 0
/declare grpnumber int local 0
/echo - Starting -
/for junctions 1 to 12
/echo ${junctions} junctions
/for i 1 to 10
/echo ${i} i variable at i loop
:start
/if (${Bool[${Ini[movement,${TargetZone},junctions].Arg[${junctions},,]}]}) {
/echo ${Ini[movement,${TargetZone},junctions].Arg[${junctions},,]}
/varset TargetZone ${Ini[movement,${TargetZone},junctions].Arg[${junctions},,]}
/echo changed targetzone to ${TargetZone}
/echo ${Ini[movement,${TargetZone},junctions].Arg[${junctions},,]} targetzones junctions
/echo ${i} i variable in bool junctions
/varset i 1
}
/if (!${Bool[${Ini[movement,${savedtargetzone},junctions].Arg[${junctions},,]}]} && ${TargetZone.NotEqual[${savedtargetzone}]}) {
/varset TargetZone ${savedtargetzone}
/echo changed targetzone to savedtargetzone
/echo ${junctions} junctions
/echo ${i} i variable in not bool junctions
/echo ${j} j
/varset i 1
}
/if (${Bool[${Ini[movement,${savedtargetzone},junctions].Arg[${junctions},,]}]} && ${TargetZone.NotEqual[${Ini[movement,${savedtargetzone},junctions].Arg[${junctions},,]}]}) {
/varset TargetZone ${Ini[movement,${savedtargetzone},junctions].Arg[${junctions},,]}
/echo changed targetzone to savedtargetzone junction arg junctions
/echo ${junctions}
/echo ${i} i variable in bool junctions arg junctions
/echo ${j} j
/varset i 1
}
/if (${savedvariable} != 1) {
/if (${Bool[${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,].Equal[${Zone.ShortName}]}]} && ${startlocation.Equal[0]}) {
/echo found starting zone
/varset startlocation ${TargetZone},${i},
/echo ${startlocation}
/echo ${i} i variable
/echo ${j} j variable
}
/if (${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,].NotEqual[${Zone.ShortName}]} && ${startlocation.NotEqual[0]}) {
/echo found end of zones
/varset junctions 1
/varset savedvariable 1
/varset TargetZone ${startlocation.Arg[1,,]}
/varset i ${startlocation.Arg[2,,]}
}
}
/if (${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}].Arg[${j},,].Equal[finish]} && ${zoneshortname.Equal[${Zone.ShortName}]}) {
/keypress w
/varset didinvis 0
/echo i have reached my destination
/guildsay im at target destination
/varset makecamploc ${Me.Y},${Me.X}
/return
}
/if (${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,].Equal[${Zone.ShortName}]}) {
/if (!${forcemove}) {
/if (${Me.Class.Name.Equal[Bard]} && !${didinvis}) {
/call groupcheck
}
/if (${Me.Class.Name.NotEqual[Bard]} && !${didinvis}) {
/call findgroup
/varset grpnumber ${Macro.Return}
:waitforinvis
/doevents Toggle
/if (${Macro.Return.Equal[abort]}) {
/varset makecamploc ${Me.Y},${Me.X}
/return
}
/if (${Ini[toolismacro,Movement,group${grpnumber}ready].Equal[ready]}) {
/varset didinvis 1
}
/if (${Ini[toolismacro,Movement,group${grpnumber}ready].Equal[empty]}) {
/delay 2
/echo waiting for invis
/goto :waitforinvis
}
}
}
/if (${Me.Class.Name.Equal[Bard]} && !${didinvis}) {
/squelch /twist off
/varset didinvis 1
/varset dotwist 1
/if (!${Me.Gem[${travelsong}]} && !${Cursor.ID}) {
/guildsay sec memming travel song
/memspell ${travelsonggem} ${travelsong}
/delay 2s
}
/squelch /twist ${travelsonggem}
/delay 2s
/if (!${Me.Casting.ID}) {
/squelch /twist ${speedsonggem}
/delay 2s
/if (${Me.Casting.ID}) /delay 1s
/if (!${Me.Gem[${invissong}]} && !${Cursor.ID}) {
/guildsay sec memming invis song
/memspell ${travelsonggem} ${invissong}
/delay 2s
}
/squelch /twist ${travelsonggem}
/delay 3s
}
/if (${Me.Casting.ID}) /delay 2s
/call findgroup
/varset grpnumber ${Macro.Return}
/ini "toolismacro" "Movement" "group${grpnumber}ready" "ready"
/delay 6
/ini "toolismacro" "Movement" "group${grpnumber}ready" "empty"
}
/echo ${j} j (before for loop)
/for j 1 to 30
/echo ${j} j
/if (${Bool[${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${j}]}]} && ${savedvariable} != 1) {
/varset savedvariable ${j}
/varset nextlocationy ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${j}].Arg[1,,]}
/varset nextlocationx ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${j}].Arg[2,,]}
/varset nextlocationyhigh ${Math.Calc[${nextlocationy} + 75]}
/varset nextlocationylow ${Math.Calc[${nextlocationy} - 75]}
/varset nextlocationxhigh ${Math.Calc[${nextlocationx} + 75]}
/varset nextlocationxlow ${Math.Calc[${nextlocationx} - 75]}
/if (${Me.Y} <= ${nextlocationyhigh} && ${Me.Y} >= ${nextlocationylow} && ${Me.X} <= ${nextlocationxhigh} && ${Me.X} >= ${nextlocationxlow}) {
/echo found correct loc
/varset savedvariable 1
/goto :end
}
/varset nextlocationyhigh ${Math.Calc[${nextlocationy} + 175]}
/varset nextlocationylow ${Math.Calc[${nextlocationy} - 175]}
/varset nextlocationxhigh ${Math.Calc[${nextlocationx} + 175]}
/varset nextlocationxlow ${Math.Calc[${nextlocationx} - 175]}
/if (${Me.Y} <= ${nextlocationyhigh} && ${Me.Y} >= ${nextlocationylow} && ${Me.X} <= ${nextlocationxhigh} && ${Me.X} >= ${nextlocationxlow}) {
/echo found nearest loc
/varset savedvariable 1
/goto :nearestlocloop
}
/echo this didnt work
/varset nextlocationy NULL
/if (${Bool[${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${savedvariable}].Arg[1,,]}]}) {
/varset savedvariable ${Math.Calc[${j} + 1]}
/varset nextlocationy NULL
/if (${Bool[${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${savedvariable}].Arg[1,,]}]}) {
/echo next j
/next j
}
/if (${Bool[${Ini[movement,${TargetZone},zoneshortnames].Arg[${Math.Calc[${i} + 1]},,]}]}) {
/varset j 0
/next i
}
/if (${Bool[${Ini[movement,${savedtargetzone},junctions].Arg[${junctions},,]}]}) {
/varset j 0
/echo next junctions instead of j
/varset TargetZone ${savedtargetzone}
/next junctions
}
}
/echo this fired
/varset savedvariable ${Math.Calc[${j} + 1]}
/delay 2
/next i
}
/if (!${Bool[${Ini[movement,${savedtargetzone},junctions].Arg[${junctions},,]}]} && ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}].Arg[${j},,].Equal[junction]} || ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}].Arg[${j},,].Equal[finish]}) {
/keypress w
/varset didinvis 0
/echo i have reached my destination
/guildsay im at target destination
/varset makecamploc ${Me.Y},${Me.X}
/return
}
:end
/if (${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}].Arg[${j},,].Equal[junction]}) {
/keypress forward
/varset j 1
/varset TargetZone ${savedtargetzone}
/if (!${Bool[${Ini[movement,${savedtargetzone},junctions].Arg[${junctions},,]}]}) {
/varset TargetZone ${startlocation.Arg[1,,]}
/varset i ${startlocation.Arg[2,,]}
}
/if (${Bool[${Ini[movement,${TargetZone},junctions].Arg[${junctions},,]}]}) {
/echo changing junctions +1 from hitting a junction
/next junctions
}
}
/if (${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}].Arg[${j},,].Equal[zonedoor]} && ${nextlocationy.NotEqual[NULL]}) {
/keypress forward
/varset j 1
:doorloop
/keypress u
/delay 2
/keypress u
/delay 1s
/if (${Bool[${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}zonedoor]}]}) {
/face nolook loc ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}zonedoor]}
/keypress u
}
/call viewing
/if (${zoneshortname.Equal[${Zone.ShortName}]}) /goto :doorloop
/varset nextlocationy NULL
}
/if (${zoneshortname.Equal[${Zone.ShortName}]}) {
/varset tempheading ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}].Arg[${j},,]})
/if (${Math.Calc[(360 - ${tempheading}) + 45]} > 360 && ${Me.Heading.Degrees} <= ${Math.Calc[(360 - ${tempheading}) - 45]} || ${Math.Calc[(360 - ${tempheading}) + 45]} > 360 && ${Me.Heading.Degrees} <= ${Math.Calc[45 - (360 - ${tempheading})]}) {
/goto :headingdone
}
/if (${Math.Calc[(360 - ${tempheading}) - 45]} < 0 && ${Me.Heading.Degrees} <= ${Math.Calc[(360 - ${tempheading}) + 45]} || ${Math.Calc[(360 - ${tempheading}) - 45]} < 0 && ${Me.Heading.Degrees} <= ${Math.Calc[45 - (360 - ${tempheading})]}) {
/goto :headingdone
}
/if (${Math.Calc[${Me.Heading.Degrees}]} >= ${Math.Calc[360 - ${tempheading}]} && ${Math.Calc[${Me.Heading.Degrees}]} <= ${Math.Calc[(360 - ${tempheading}) + 45]} || ${Math.Calc[${Me.Heading.Degrees}]} >= ${Math.Calc[(360 - ${tempheading}) - 45]} && ${Math.Calc[${Me.Heading.Degrees}]} <= ${Math.Calc[360 - ${tempheading}]}) {
/goto :headingdone
}
/if (${tempheading} <= 180) {
/echo Tempheading < 180
/if (${Me.Heading.Degrees} >= ${Math.Calc[(360 - ${tempheading}) - 180]} && ${Me.Heading.Degrees} <= ${Math.Calc[360 - ${tempheading}]}) {
/varset tempheading ${Math.Calc[${tempheading} + 45]}
/goto :heading
} else {
/if (${tempheading} <= 45) {
/varset tempheading ${Math.Calc[315 + ${tempheading}]}
/goto :heading
}
/varset tempheading ${Math.Calc[${tempheading} - 45]}
/goto :heading
}
}
/if (${tempheading} > 180) {
/echo Tempheading > 180
/if (${Me.Heading.Degrees} <= ${Math.Calc[(360 - ${tempheading}) + 180]} && ${Me.Heading.Degrees} >= ${Math.Calc[360 - ${tempheading}]}) {
/varset tempheading ${Math.Calc[${tempheading} - 45]}
/goto :heading
} else {
/if (${tempheading} <= 315) {
/varset tempheading ${Math.Calc[${tempheading} + 45]}
/goto :heading
}
/varset tempheading ${Math.Calc[(360 - ${tempheading}) - 45]}
/goto :heading
}
}
:heading
/face heading ${tempheading}
:headingdone
/face fast heading ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}].Arg[${j},,]}
}
/varset nextlocationy NULL
/varset nextlocationx NULL
/if (${Bool[${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${j}]}]}) {
/varset nextlocationy ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${j}].Arg[1,,]}
/varset nextlocationx ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${j}].Arg[2,,]}
}
:nearestlocloop
/doevents Toggle
/if (${Macro.Return.Equal[abort]}) {
/varset makecamploc ${Me.Y},${Me.X}
/return
}
/varset nextlocationyhigh ${Math.Calc[${nextlocationy} + 5]}
/varset nextlocationylow ${Math.Calc[${nextlocationy} - 5]}
/varset nextlocationxhigh ${Math.Calc[${nextlocationx} + 5]}
/varset nextlocationxlow ${Math.Calc[${nextlocationx} - 5]}
:movementloop
/keypress forward hold
/if (${nextlocationy.NotEqual[NULL]} && ${Me.Y} <= ${nextlocationyhigh} && ${Me.Y} >= ${nextlocationylow} && ${Me.X} <= ${nextlocationxhigh} && ${Me.X} >= ${nextlocationxlow}) {
/keypress forward
/delay 2
/if (${Bool[${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${j}command]}]}) /call ${Ini[movement,${TargetZone},${Ini[movement,${TargetZone},zoneshortnames].Arg[${i},,]}loc${j}command]}
/next j
}
/if (${nextlocationy.NotEqual[NULL]}) {
/if (${Me.Y} <= ${nextlocationylow} || ${Me.X} <= ${nextlocationxlow} || ${Me.Y} >= ${nextlocationyhigh} || ${Me.X} >= ${nextlocationxhigh}) {
/face nolook fast loc ${nextlocationy},${nextlocationx}
}
}
/if (${zoneshortname.NotEqual[${Zone.ShortName}]}) {
/if (!${InvSlot[17].Item.ID}) {
/if (!${InvSlot[13].Item.ID} && !${Defined[amnaked]}) {
/guildsay - i died during movement -
/declare amnaked int outer 100
/doevents flush Movement
/return
}
}
/echo -- ${Zone.Name} --
/varset nextlocationy NULL
/keypress forward
/varset zoneshortname ${Zone.ShortName}
/varset didinvis 0
/varset j 1
/varset i 0
/delay 2
/next i
}
/delay 1
/goto :movementloop
}
/delay 2
/if (${Bool[${Ini[movement,${TargetZone},zoneshortnames].Arg[${Math.Calc[${i} + 1]},,]}]}) /next i
/varset i 0
/next junctions
/varset junctions 1
/varset savedvariable 1
/varset TargetZone ${startlocation.Arg[1,,]}
/varset i ${startlocation.Arg[2,,]}
/echo setting targetzone and zone im in
/next junctions
/echo returning
/return

