*************************************************************************************
*DISCLAIMER* = DO NOT USE THIS if you are on a flagged account, afraid of becoming a flagged account, afraid of getting banned. AFK macros are extremely risky to use so do not blame me if you get caught
*************************************************************************************
Forming new thread for this version, original macro thread is located here:
http://www.mmobugs.com/forums/showthread.php?t=882&page=28
And credit to Kalle for the locs inside the mission on his thread here:
[ame="http://www.mmobugs.com/forums/showthread.php?t=1596"]http://www.mmobugs.com/forums/showthread.php?t=1596[/ame]
Description:Will auto-retrieve mission, or count down if there is a tasktimer. Once zoning in will wait for at least 1 group member, then begin pulling goblins using *WARP* back to the entrance. Will kill all mobs before proceeding to next and will pause if health is low or if rooted. Will continue pulling goblins until the 40 counter is reached, then will begin retrieving hostages. On success will open chest and loot shard, then wait until mission is over and do it all over again.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*NOTE* = PickSkill.inc is something I whipped up solely for using the Abilities "Taunt" and "Kick". Feel free to copy it into a General include if you want, and change the #include line at top of macro. If you wish to use these abilities in the macro, make sure to download the .inc file into your macros folder, and in the macro make sure the variable UseAbility shows a value of 1. By using these, it will overwrite your existing hotkeys in slot 3 and 4 FYI. If you dont' wish to use it, make the value 0 and comment out or remove the line #include Pickskill (already done by default).
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Version: 2.3
Plugins Required:
- MQ2Exchange
- MQ2MoveUtils
- MQ2MMOBUGSTOOLS
Known Issues:
---------------------
- Restarting macro inside(for testing) will reset Goblin count back to 0, in work
LSMAIN.MAC
*DISCLAIMER* = DO NOT USE THIS if you are on a flagged account, afraid of becoming a flagged account, afraid of getting banned. AFK macros are extremely risky to use so do not blame me if you get caught
*************************************************************************************
Forming new thread for this version, original macro thread is located here:
http://www.mmobugs.com/forums/showthread.php?t=882&page=28
And credit to Kalle for the locs inside the mission on his thread here:
[ame="http://www.mmobugs.com/forums/showthread.php?t=1596"]http://www.mmobugs.com/forums/showthread.php?t=1596[/ame]
Description:Will auto-retrieve mission, or count down if there is a tasktimer. Once zoning in will wait for at least 1 group member, then begin pulling goblins using *WARP* back to the entrance. Will kill all mobs before proceeding to next and will pause if health is low or if rooted. Will continue pulling goblins until the 40 counter is reached, then will begin retrieving hostages. On success will open chest and loot shard, then wait until mission is over and do it all over again.
UPDATED: 2 OCT 2006
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*NOTE* = PickSkill.inc is something I whipped up solely for using the Abilities "Taunt" and "Kick". Feel free to copy it into a General include if you want, and change the #include line at top of macro. If you wish to use these abilities in the macro, make sure to download the .inc file into your macros folder, and in the macro make sure the variable UseAbility shows a value of 1. By using these, it will overwrite your existing hotkeys in slot 3 and 4 FYI. If you dont' wish to use it, make the value 0 and comment out or remove the line #include Pickskill (already done by default).
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Version: 2.3
Plugins Required:
- MQ2Exchange
- MQ2MoveUtils
- MQ2MMOBUGSTOOLS
Known Issues:
---------------------
- Restarting macro inside(for testing) will reset Goblin count back to 0, in work
Code:
Changes:
----------------
7 April 2006 - Complete rewrite from orig. to account for 40 goblins
8 April 2006 - Back to the old way of warp target, hail, removed hailtarget
- Added Current zone checks for known Zoning event issue
9 April 2006 - Changed zone checks because they weren't working :)
- Added pause at start to wait for group
- 2nd loc was a tad off, adjusted it
- Will now wait if low on health or rooted
- Added 9 more Locations to goblin loop
15 April 2006 - Added event to help in counting, prev. was only counting ones the main toon killed
- Fight sub will now target wizzies first, then rogues, then rest
- Locs 19-25 changed to better targets
- Added a better zonechange event
17 April 2006 - Added a goblincount reset so they don't go straight to hailing hostages on 2nd mission
- Changed the way Sub Loot is called
- Fixed errors created during pasting macro into post
- Changed target order on mobs to Shm then Wiz then Rogue
- Added loop so he will keep trying to zone in, instead of just getting another mission.
20 April 2006 - Modified Goblincount variable to better recognize group members dying.
- Changed hostage check to better recognize a hostage from a goblin
- Added /face heading so main toon isn't facing wall on each succor (doesn't really add to functionality)
- Added 45min. Missiontimer from the time you get the mission. Should now either zone you out when 45min. is up, or when you are booted from the zone, whichever is first.
30 April 2006 - Improved targeting functionality during fight routine
- Added Aggrotimer to fix 0-mob pull problems (60sec timer)
- Main toon will no longer warp after doing hostages, Looters rejoice
- The Goblin counter now works much better
- New include file, adding Taunt and Kick ability if you wish it, Read above and make sure to copy/download Pickskill.inc
- End of mission, zoning to Lavastorm, it will wait 2min. or until a group member is in zone (+ another 15sec) then get new mission
10 May 2006 - Moved :Laghangup in the DoGoblins sub up a little to reclear target to avoid a possible Loop error
31 May 2006 - Added a timer on Taunt so it won't mash the keys
- Removed 723.00, 543.00 LOC from array, it was a roamer
- Fixed Looting bug, was looting faster than window was up
1 June 2006 - Added command "/LSPassword text" to change PW in-game
- *NOTE* Using /LSPassword only changes pw for duration of the macro running. Continue to use the Password variable inside macro to permanently change the password, I don't want to incorporate an INI for 1 variable
- Added delay before Fade check in Loot for slower computers
24 Aug 06 - Added hail counter to avoid a loop if trying to zone in
- Changed the way hostages are done
- Added LoS checks on goblins (credit to Fy, I didn't know you could use this as a parameter)
- Removed a line that was causing conflict
3 Sep 06 - Added check for group health to help avoid wipes
2 Oct 06 - Added the additional Fade after hails back in
LSMAIN.MAC
Code:
|LSMain.mac
|Written by Booges 2 OCT 06
|Version: 2.3
|-*-This macro is to be only posted on MMOBugs.com-*-
|-Required Plugins: MQ2MoveUtils, MQ2MMOBUGSTOOLS, MQ2Exchange
| Pickskill.inc - if using abilities
|- Put in PASSWORD variable for those auto-joining your group
|- Begin Macro at Sol A entrance in vicinity of Commander
|- MAIN CHARACTER MUST BE GROUP LEADER FOR MISSION TO WORK CORRECTLY
|- If you use USEABILITY, slot 3 and 4 of HotButtons will be overwritten
|
|
|-----------------------------------------------
|On the Fly Commands:
|===============================================
|- /LSPassword passwordhere = Change PW - NOTE* only changes for duration of macro, use Var below to perma change
|-----------------------------------------------
#turbo 10
#include Pickskill.inc
#Chat Group
#Chat Tell
#Event Camping "It will take you about 30 seconds to prepare#*#"
#event Goblindeath "You have slain#*#"
#event Goblindeath "#*# goblin #*# has been slain by #*#"
#event Healinc "#1# begins to cast a spell."
#event Lava "#*#You have entered The Lavastorm Mountains#*#"
#event Nogroup "#*#this shared task because your party does not contain the minimum#*#"
#event NewPassword "[MQ2] LSPassword #1#"
#event Request "You may not request a shared task because#*#"
#event Shard "#*#Meet back at the rendezvous point and we'll celebrate in due process#*#"
#event Slain "#*#You have been slain by#*#"
#event Trade "#1# has offered you a #*#"
#event WaitTimer "#*#task because you must wait 0d:0h:#1#m before you can#*#"
#event Zoning "LOADING, PLEASE WAIT#*#"
Sub Main
|--------------------------------------------------------------------
|##Between quotes type what people should say to you to get an invite
|##Set UseAbility to 1 if you want to use Taunt and Kick (PickSkill.inc)
|-----------------------------------------------------------------------
/declare Password string outer "INVITE PASSWORD"
/declare UseAbility int outer 1
|--------------------------------------------------------------------
|## NO EDIT
|--------------------------------------------------------------------
/declare Waittimer int outer 0
/declare Missiontimer timer outer 0
/declare WinCount int outer 0
/declare Goblincount int outer 0
/declare Goblinloc[25] string outer
/varset Goblinloc[1] -485 -483 73
/varset Goblinloc[2] -504 -535 58
/varset Goblinloc[3] -471 -570 44
/varset Goblinloc[4] -565 -558 55
/varset Goblinloc[5] -546 -657 55
/varset Goblinloc[6] -621 -675 49
/varset Goblinloc[7] -530 -705 51
/varset Goblinloc[8] -543 -789 50
/varset Goblinloc[9] -568 -841 43
/varset Goblinloc[10] -574 -901 42
/varset Goblinloc[11] -539 -915 42
/varset Goblinloc[12] -495 -633 55
/varset Goblinloc[13] -447 -611 55
/varset Goblinloc[14] -441 -746 33
/varset Goblinloc[15] -419 -777 43
/varset Goblinloc[16] -368 -566 38
/varset Goblinloc[17] -655 -541 44
/varset Goblinloc[18] -435 -869 42
/varset Goblinloc[19] -387 -890 44
/varset Goblinloc[20] -439 -922 43
/varset Goblinloc[21] -356 -614 56
/varset Goblinloc[22] -338 -663 56
/varset Goblinloc[23] -365 -778 44
/varset Goblinloc[24] -330 -744 44
/squelch /alias /LSPassword /echo LSPassword
/Echo ==============+==============
/Echo ## Lavastorm AFK V2.3 ##
/Echo ==============+==============
:main
/doevents
/call GM
/call start
/goto :main
/return
|--
|##If in lavastorm it will get mission, if in Sol A
|##mission zone it will begin the mission
|--------------------------------------------------
Sub start
/declare t int local 0
:StartOver
/if (${Zone.ID}==31) /goto :Bigloop
/call Reset
:Bigloop
/call GM
/target myself
/If ((!${Target.ID}) && (!${Spawn[${Group.Member[1]}].Type.Equal[pc]})) /goto :BigLoop
/doevents
:Checkgobs
/if (${Goblincount}<40) {
/call DoGoblins
/goto :Checkgobs
}
/if (${Spawn[npc "goblin" radius 20].ID}) /call Fight
/if (${Zone.ID}==27) /return
/delay 2s
/target clear
|--
|If you wish to post this or use it elsewhere please contact the author Booges
|for permission. If you see this macro posts elsewhere please contact admin@mmobugs.com
|##Hailing Hostages now
|------------------------------------------------
/call GM
/echo ! Saving the Hostages !
/for t 1 to 9
/target hostage0${t}
/if (${Target.CleanName.NotEqual[a gnomish hostage]}) /goto :Nohostage
/delay 5
/warp t
/delay 5
/keypress h
/delay 25
/keypress h
/delay 7
:Nohostage
/next t
/target hostage10
/if (${Target.CleanName.NotEqual[a gnomish hostage]}) /goto :AllDone
/delay 5
/warp t
/delay 5
/keypress h
/delay 25
/keypress h
/delay 7
:AllDone
/warp s
/delay 2s
/call Fade
/delay 2s
/call Fade
/delay 2s
:Checkcursor
/autoinventory
/if (${Cursor.ID}) /goto :Checkcursor
/doevents
/goto :StartOver
/return
|--
|##40 Goblin Script
|------------------
Sub DoGoblins
/declare intcount int local
/declare Aggrotimer timer local
/if (${UseAbility}) /call Pickskill Taunt 3
/delay 1s
/if (${UseAbility}) /call Pickskill Kick 4
/exchange "Reinforced Armor Plating" Chest
/delay 1s
/exchange "Diamond Tipped Drill Bit" mainhand
/delay 1s
/cleanup
/for intcount 1 to 24
/if (${Zone.ID}==27) /call Event_Lava
/squelch /target clear
/if (${Goblincount}>40) /return
:Laghangup
/varset Aggrotimer 60s
/warp loc ${Goblinloc[${intcount}]}
/delay 4s
/keypress back hold
/delay 3
/keypress back
/delay 4s (${Target.ID})
/if (${Spawn[npc radius 5].ID}) /target goblin npc los
/if (${UseAbility} && ${Target.ID}) /notify HotButtonWnd HB_Button4 leftmouseup
/warp s
/face heading 90
/delay 2s
:wait1
/if (!${Aggrotimer} && ${Target.Type.Equal[npc]}) /goto :Laghangup
/if (${Target.Distance}>25) /goto :wait1
/call Fight
/doevents
/if (${Target.ID} || ${SpawnCount[npc goblin radius 30]} || ${Me.Buff["Root"].ID} || ${Me.Buff["Instill"].ID} || ${Me.PctHPs}<63) /goto :wait1
/call CheckGroup
/if (${Macro.Return}) /goto :wait1
/next intcount
/return
|--
|##Make sure group is ready for more
|----------------------------------
Sub CheckGroup
/declare i int local
/declare t int local 0
/declare Healthlow int local 0
/for i 0 to ${Group.Members}
/if (${Group.Member[${i}].PctHPs}<55) /varcalc t ${t}+1
/next i
/if (${t}>2) {
/varset Healthlow 1
} else {
/varset Healthlow 0
}
/return ${Healthlow}
|--
|##Retrieve the Mission and zone in
|----------------------------------
Sub Reset
/declare Gnomeslackcounter int local 0
/doevents flush
/if (${Me.Sitting}) /stand
/target Clockwork_Commander_widgetsworth
/If (${Target.Distance}>40) /call Movement 1449, 913
/face
/delay 2s
/stick 10
/delay 2s
/squelch /stick off
/say group
/delay 2s
/doevents
/delay 1s
/if (!${Window[TaskSelectWnd].Open}) /say group
:GetTask1
/if (${Window[TaskSelectWnd].Open}) {
/notify TaskSelectWnd AcceptButton leftmouseup
/delay 3s
/goto :GetTask2
}
/goto :GetTask1
:GetTask2
/delay 1s
/doevents
/delay 1s
:GetMonster1
/if (${Window[TaskTemplateSelectWnd].Open}) {
/notify TaskTemplateSelectWnd TaskTemplateSelectListOptional listselect ${Window[TaskTemplateSelectWnd].Child[TaskTemplateSelectListOPtional].List[Juggernaut]}
/delay 1s
/notify TaskTemplateSelectWnd TaskTemplateSelectAcceptButton leftmouseup
/delay 3s
/goto :GetMonster2
}
/goto :GetMonster1
:GetMonster2
/cleanup
/tar Clockwork_Commander_Cogswain
/face
/delay 2s
/stick 10
/varset Goblincount 0
/varset Missiontimer 43m
/delay 10s
/squelch /stick off
:hailwait
/if (${Gnomeslackcounter}==5) /call Event_Camping
/keypress h
/delay 15s
/doevents
/if (${Zone.ID}==27) {
/varcalc Gnomeslackcounter ${Gnomeslackcounter}+1
/goto :hailwait
}
/delay 10s
/call Start
/return
|--
|##Loot Sub, checks for nearby mob
|---------------------------------
Sub Loot
:again
/if (${Zone.ID}==31) {
/call Fade
/If (${Cursor.ID}) /autoinventory
/target id ${Spawn[npc race "Chest"].ID}
/delay 1s
/If (${Target.Distance}>8) /warp target
/delay 1s
/open
/delay 1s
/target corpse
/delay 5
/if (${Target.Type.NotEqual[corpse]}) /call Fade
/target corpse
/If (${Target.Distance}>8) /warp target
/delay 3s
/loot
/delay 1s
/call Fight
/delay 2s
/if (${Window[LootWnd].Open}) {
/if (${Corpse.Items}==1) {
/itemnotify loot1 rightmouseup
/itemnotify loot1 rightmouseup
/delay 2s
} else {
/itemnotify loot2 rightmouseup
/itemnotify loot2 rightmouseup
/delay 2s
}
/if (${Window[ConfirmationDialogBox].Open}) /nomodkey /notify ConfirmationDialogBox Yes_Button leftmouseup
/delay 2s
/notify LootWnd DoneButton Leftmouseup
/delay 3s (!${Window[LootWnd].Open})
/notify LootWnd DoneButton Leftmouseup
}
/if (!${FindItem[Shard of Wisdom].InvSlot.ID}) /goto :again
/varcalc WinCount ${WinCount}+1
/echo Successful Mission = (${WinCount})
/popup Success! Like Woah
/warp loc ${Math.Calc[${Math.Rand[7]}+-401]}, ${Math.Calc[${Math.Rand[7]}+-352]}, 17
/varset Goblincount 0
/delay 30s
/call Fight
:Forever
/if ((!${Missiontimer}) && (${Zone.ID}==31)) {
/target Comm
/delay 1s
/warp t
/delay 1s
/say evac
/delay 5s
}
/doevents
/goto :Forever
} else {
/call Reset
}
/return
|--
|##Attack mobs if they prevent you from looting
|----------------------------------------------
Sub Fight
/declare Taunttimer timer local 7s
:Checkfight
/If (${Zone.ID}!=31) /return
/If (${Spawn[npc "goblin" radius 25].LineOfSight}) {
/if (${Spawn[npc Shaman radius 30].ID}) {
/target Shaman npc
/goto :Targeted
} else /if (${Spawn[npc Wizard radius 30].ID}) {
/target Wizard npc
/goto :Targeted
} else /if (${Spawn[npc Rogue radius 25].ID}) {
/target Rogue npc
/goto :Targeted
} else {
/target goblin npc los
}
:Targeted
/delay 5
/stick 10
:Mob
/if (${Target.Distance}<16) /attack on
/doevents
/If (${Target.Type.Equal[NPC]} && ${Spawn[npc "goblin" radius 24].LineOfSight}) {
/if (${UseAbility} && !${Taunttimer}) {
/notify HotButtonWnd HB_Button3 leftmouseup
/varset Taunttimer 7s
}
/goto :Mob
} else {
/attack off
/squelch /stick off
}
/goto :Checkfight
}
/doevents
/return
|--
|##Simple Fade sub to hold macro while fading
|--------------------------------------------
Sub fade
/If (${Me.PctHPs}>30) {
/fade
} else {
/delay 40s
}
:Fading
/target myself
/If (!${Target.ID}) /goto :Fading
/target clear
/delay 1s
/return
|--
|##GM Sub for checking
|---------------------
Sub GM
/if (${Spawn[gm].ID}) {
/gsay Time to go, cya later
/camp
/endmac
}
/return
|--
|##Enables you to Move to a loc specified
|----------------------------------------
Sub Movement(int MoveX,int MoveY)
/declare StartZone int local ${Zone.ID}
/declare StuckXLoc int local ${Me.X}
/declare StuckYLoc int local ${Me.Y}
/squelch /stick off
/keypress forward hold
/keypress Space
:AnchorMoveLoop
/delay 1
/face fast nolook loc ${MoveX},${MoveY}
/if (${Math.Distance[${MoveX},${MoveY}]}>10) {
/keypress forward hold
/varset StuckXLoc ${Me.X}
/varset StuckYLoc ${Me.Y}
/doevents
/delay 5
/if (${StuckXLoc}==${Me.X} && ${StuckYLoc}==${Me.Y}) {
/keypress forward
/keypress back hold
/delay 3
/keypress back
/if (${Math.Rand[2]}) {
/keypress strafe_right hold
} else {
/keypress strafe_left hold
}
/delay 2s
/keypress strafe_right
/keypress strafe_left
}
/if (${Zone.ID}!=${StartZone}) /return
} else {
/keypress forward
/return
}
/goto :AnchorMoveLoop
/return
|------------------------------------------------------
| -+= EVENTS =+-
|------------------------------------------------------
|--
|##Chat Events
|-------------
Sub Event_Chat(string ChatType,string ChatSender,string ChatText)
/If (${ChatType.Equal[TELL]} && ${ChatText.Equal[${Password}]}) {
/invite ${ChatSender}
/taskaddplayer ${ChatSender}
/return
}
/If (${ChatText.Equal[make me leader]}) {
/if (!${Goblincount}) /makeleader ${ChatSender}
/return
}
/If (${ChatText.Equal[how long]} || ${ChatText.Equal[timer?]}) {
/t ${ChatSender} Have ${Waittimer} minutes left yet.
/return
}
/return
|--
|##End Macro if you camp on your own
|-----------------------------------
Sub Event_Camping
/echo Camping - Ending macro!
/endmacro
/return
|--
|##Counting dead goblins
|-----------------------
Sub Event_Goblindeath
/varcalc Goblincount ${Goblincount}+1
/echo Goblin Dead! ${Math.Calc[40-${Goblincount}]} To Go!
/return
|--
|## Pause if a heal is inc
|-------------------------
Sub Event_Healinc(Line, string Command)
/if (${Verbose}) /echo Heal Delay Entered
/if (${Select[${Command},${Group.Member[1]},${Group.Member[2]},${Group.Member[3]},${Group.Member[4]},${Group.Member[5]}]}) /delay 2s
/return
|--
|##Remove task upon zoning to Lavastorm
|--------------------------------------
Sub Event_Lava
/declare g int local 0
/declare g2 int local 0
/doevents flush
/delay 2s
/If (${Me.Sitting}) /stand
/for g 0 to ${Group.Members}
/varcalc g2 ${Group.Members}-${g}
/taskremove ${Group.Member[${g2}]}
/next g
/delay 2m (${Spawn[${Group.Member[1]}].Type.Equal[pc]})
/delay 15s
/call Reset
/return
|--
|## Set a new Password on the fly
|--------------------------------
Sub Event_NewPassword(Line, string Freshone)
/varset Password ${Freshone}
/echo Password successfully changed to - ${Password} -
/return
|--
|##Auto-camp in the event your group leaves/crashes
|--------------------------------------------------
Sub Event_Nogroup
/gsay Group folded I'm done
/end
/return
|--
|##This Event is so you can stop/start a macro during a tasktimer
|----------------------------------------------------------------
Sub Event_Request
/declare g int local 0
/declare g2 int local 0
/If (${Me.Sitting}) /stand
/echo ! Pausing for 2 Minutes for Looters !
/delay 2m
/for g 0 to ${Group.Members}
/varcalc g2 ${Group.Members}-${g}
/taskremove ${Group.Member[${g2}]}
/next g
/call Reset
/return
|--
|##Hostages done. Calling Loot sub
|---------------------------------
Sub Event_Shard
/call Loot
/return
|--
|##Holds macro when you die
|--------------------------
Sub Event_Slain
/delay 5s
:Loading
/target myself
/If (!${Target.ID}) /goto :Loading
/target clear
/delay 2s
/return
|--
|##Auto accept items traded
|--------------------------
Sub Event_Trade
/delay 8s
/doevents flush
/if (${Window[TradeWnd].Open}) {
/notify TradeWnd TRDW_Trade_Button leftmouseup
}
/return
|--
|##Countdown if you have a tasktimer
|-----------------------------------
Sub Event_WaitTimer(crap,int tasktime)
/declare y int local 0
/varcalc tasktime ${tasktime}+1
/echo Delaying ${tasktime} minutes
/squelch /stick off
/keypress strafe_left hold
/delay 1s
/keypress strafe_left
/call Movement ${Math.Calc[${Math.Rand[7]}+1427]}, ${Math.Calc[${Math.Rand[7]}+971]}
/face heading ${Math.Rand[359]}
/If (!${Me.Sitting}) /sit
/for y 0 to ${tasktime}
/Echo ${Math.Calc[${tasktime}-${y}]} minutes left till get new expedition
/varset Waittimer ${Math.Calc[${tasktime}-${y}]}
/doevents
/delay 15s
/doevents
/delay 15s
/doevents
/delay 15s
/doevents
/delay 15s
/next y
/call reset
/return
|--
|##Zoning Function since zone events don't work
|----------------------------------------------
Sub Event_Zoning
/delay 2s
/if (${Zone.ID}==27) /call Event_Lava
/return
Attachments
Last edited by a moderator: