Greetins!
I was wondering what the code would be to check someone's guild name? I am trying to make a bot I can leave sitting around that will buff my guild, and people that I have in an ini file only, everyone else, it ignores.
Thanks.
Moderator: MacroQuest Developers


Code: Select all
#turbo
#include spell_routines.inc
#define <myname> "Your Bot's Name Goes Here In Quotes"
#define <guildname> "Your Guild Name Goes Here In Quotes"
#event Hailed "#1# says, 'Hail, <myname>'"
Sub Event_Hailed(string line,string RequestorName)
/target pc ${RequestorName}
/if (!${Target.Guild.Equal["<guildname>"]}) {
/if (!${Target.Class.Equal["Warrior"]}) {
/call Cast "Swift Like The Wind"
}
/if (!${Target.Class.Equal["Wizard"]}) {
/tgb
/call Cast "Koadic's Endless Intellect"
}
}
/return
Sub Main
:MainLoop
/doevents
/goto :MainLoop
/return