Your comments for improvements are most welcome.
Code: Select all
|----------------------------------------------------------------------------|
| GoMage - Mage Combat and Buff
| Zanomo Jun 26, 2004
| Usage: /mac GoMage [MainAssist]
| magic word is "Get Ready and Kill it"
|
#turbo 40
#include spellcast.inc
#chat group
sub main
/declare c int outer | counter variable
/declare MinHP int outer 5 | hp percentage at which to stop nuking
/declare NukeMana int outer 1500 | Actual mana at which to stop nuking
/declare BuffTime int outer 20 | Buff duration under which to recast them
/declare MA string outer | Main Assist
/declare IniFile String outer
/declare Incword String outer
/declare engagedistance int outer 100
/varset IniFile "GoIni.ini"
/varset Incword "Get Ready and Kill it"
| INI setup variables
/if (${Defined[Param0]}) {
/ini "${IniFile}" Settings MA ${Param0}
/varset MA ${Param0}
} else {
/varset MA ${Ini[${IniFile},Settings,MA,NOTFOUND]}
/if (${MA.Equal["NOTFOUND"]}) {
/echo You need to start the macro with /mac GoMage [Main Assist] and generate your .INI file.
/endmacro
} else {
/echo Assisting ${MA}
}
}
/echo GoMage started
:mainloop
/doevents chat
/call Buffemup
/goto :mainloop
/endmacro
Sub Buffemup
/if (!${Me.Casting.ID} && !${Target.Type.Equal[NPC]}) {
/if (!${Me.Buff["Shield of Maelin"].ID} && !${Me.Casting.ID}) /call Cast "Shield of Maelin"
/if (${Me.AltAbilityReady[Elemental Form: Water]}) /call Cast "Elemental Form: Water" activate
/if (${Me.Pet.ID}) {
/if (!${Me.Buff["Elemental Draw Recourse"].ID} && !${Me.Casting.ID}) {
/call Cast "Elemental Draw"
/sit
}
/if (!${Me.PetBuff["Burnout V"]} && !${Me.Casting.ID}) {
/call Cast "Burnout V"
/sit
}
/if (!${Me.PetBuff["Kindle"]} && !${Me.Casting.ID}) {
/call Cast "Kindle"
/sit
}
/if (!${Me.PetBuff["Flameshield of Ro"]} && !${Me.Casting.ID}) {
/target ${Me.Pet.Name}
/delay 6
/call Cast "Flameshield of Ro"
/sit
}
}
}
/return
Sub Event_Chat(ChatType,Sender,ChatText)
/if (${ChatText.Equal[${Incword]} && ${Sender.Equal[${MA}]}) {
/call Assist_call
/call Nuke
}
/return
Sub Assist_call
/echo Incoming.
/assist ${MA}
/delay 1s
/delay 10s (${Target.Distance}<=${engagedistance})
/if (${Target.Type.Equal[NPC]} && ${Target.Distance}<=${engagedistance}) {
/stand
/pet kill
}
/return
Sub Nuke
/echo Nuking ${Target.Name} at ${Target.PctHPs}%
/delay 5s ${Me.SpellReady["Firebolt of Tallon"]}
:nuke
/delay 5s
/if (${Me.SpellReady["Firebolt of Tallon"]} && ${Target.PctHPs}>=${MinHP} && ${Me.CurrentMana}>=${NukeMana} ) /call cast "Firebolt of Tallon"
/delay 7s
/if (${Target.PctHPs} >= ${MinHP}) /goto :nuke
/sit
/return


