Code: Select all
;Mage.iss
#include spell_routines.inc
variable int CampMode=0
variable int Camp_X
variable int Camp_Y
variable int hud_CampX=20
variable int hud_CampY=150
variable int hud_CampInc=15
variable int PetAttack=0
variable string MA
variable string PetSpell=Monster Summoning I
variable string Burnout=Burnout II
variable string NukeSpell=Blaze
function main()
{
echo Mage GO!
call myInit
call PetSetup
MA:Set[${Group.Member[1]}.ID]
while 1
{
call CombatStuff
if (!${Me.Sitting} && ${CampMode}==1)
EQExecute /sit
}
}
function myInit()
{
squelch hud -add CampLoc ${hud_CampX}, ${hud_CampY} "Camp Loc: ${Camp_X}, ${Camp_Y}"
squelch hud -add MA ${hud_CampX}, ${hud_CampY:Inc[${hud_CampInc}]} "Main Assist: ${MA}"
squelch hud -add Target ${hud_CampX}, ${hud_CampY:Inc[${hud_CampInc}]} "Target: ${Target.CleanName}
${Target.Level} ${Target.Class}"
AddTrigger Event_Died "You have been @*@"
AddTrigger Event_Exp "You gain @*@"
AddTrigger Event_Incoming "${MA} tells the group,@*@"
}
function PetSetup()
{
if !${Me.Pet.ID}
cast "${PetSpell}"
cast "${Burnout}"
}
function CombatStuff()
{
while (${Target.ID}!=${MA})
{
if ${PetAttack}==0
{
EQExecute /pet attack
PetAttack:Set[1]
}
if ${Target.Distance}<200
{
cast "${NukeSpell}"
}
}
}
function Event_Exp()
{
PetAttack:Set[0]
EQExecute /target ${MA}
if (${Me.X}!=${Camp_X})&&(${Me.Y}!=${Camp_Y})
{
face loc ${Camp_Y}, ${Camp_X}
while ${Math.Distance[${Me.X},${Me.Y},${Camp_X},${Camp_Y}]}>5
keypress forward
}
if !${Me.Pet.ID}
call PetSetup
}
function Event_Incoming()
{
EQExecute /assist
}
function Event_Died()
{
endscript mage
}
function atexit()
{
squelch hud -remove CampLoc
squelch hud -remove MA
squelch hud -remove Target
echo Shutting Down
}
atom(global) MakeCamp()
{
CampMode:Set[1]
Camp_X:Set[${Me.X}]
Camp_Y:Set[${Me.Y}]
echo "Camp set to ${Camp_X}, ${Camp_Y}"
}
atom(global) MoveCamp()
{
CampMode:Set[0]
echo "Time to move camp"
} EDIT: Fixed some spelling and misc. errors.

