AFK bot is a mage. If a tell is received by the mage saying "help" the mage will cast "Call of Hero" on whoever he is targetting. Checks for fizzles and recasts.
Thats all! Please don't flame me too bad
Moderator: MacroQuest Developers
Code: Select all
| Cothbot.mac
#include spellcast.inc
#define MySecretPassword <whatever you want it to be>
#event CoH "#1# tells you, '#2#'"
#event Join "#1# has joined the group."
Sub Main
/echo CotH Bot Active
:loop
/doevents
/delay 1
/goto :loop
/endmacro
Sub Event_CoH(string line, string who, string what)
/if (${what.Find[MySecretPassword]}) {
/target ${who}
/delay 1
/if (${Target.Name.Equal[${who}]}) /invite
}
/return
Sub Event_Join(string line, string who)
/target pc ${who}
/delay 1
/if (${Target.Name.Equal[${who}]) {
/call cast Call of the Hero
/delay 1
/if (${Macro.Return.Equal[CAST_SUCCESS]}) /disband
}
/returnCode: Select all
/declare MySecretPassword int outer
/varset MySecretPassword ${Param0}
Code: Select all
| Cothbot.mac
#include spellcast.inc
#define MySecretPassword <whatever you want it to be>
#event CoH "#1# tells you, '#2#'"
#event Join "#1# has joined the group."
Sub Main
/echo CotH Bot Active
:loop
/doevents
/delay 1
/goto :loop
/endmacro
Sub Event_CoH(string line, string who, string what)
/if (${what.Find[MySecretPassword]}) {
/target ${who}
/delay 1
/if (${Target.Name.Equal[${who}]}) /invite
}
/return
Sub Event_Join(string line, string who)
/target pc ${who}
/delay 1
/if (${Target.Name.Equal[${who}]) {
/call cast Call of the Hero
/delay 1
/if (${Macro.Return.Equal[CAST_SUCCESS]}) /disband
}
/returnCode: Select all
${what.Find[MySecretPassword]}