ModBot

From MacroQuest Wiki

Contents

ModBot - A Universal Bot Macro

  • Caster
  • Melee
  • Shrouds & MM's
  • Mez, Charm, Heal, Melee, etc
  • All classes supported
  • Now supports mixed groups of MQ2 and Non-MQ2 users/players
  • ModBot is under constant improvement effort, open to suggestions / additions / adjustments, etc

ModBot_v3.x Source

How To

To use ModBot you must extract and place all included files from zip (all .mac and .inc files) into your MQ2 macro directory.

From inside EQ, type /macro modbot <optional custom INI file name> (e.g. /macro modbot OR /macro modbot raidmode)

This will build, if it doesn't exist, your MB_<toonname>.ini file, locate this file in your macro directory and open it.

For every component of the macro you want to use, increase the respective "count", if you want two heals, set AHCount=2, if you want 2

debuffs, set ADCount=2, etc and save the INI file

Tab back over into EQ and restart the macro.

This will now populate your INI file again, open the INI file once more and "tweak" the newly created entries to fit your needs. Save

the INI file.

Tab back over into EQ and restart the macro.

Your bot should now be just that, a BOT and will listen to your every command (assuming you are the master).

Please Note One thing to keep in mind through-out the configuration of the ModBot INI file, keep your spells, activities, etc that you use most,

first in its respective INI section. You don't want your mez spell as Debuff number 20, you don't want slow as debuff 10, you don't want

a CBT based buff as buff 23, you don't want CH as heal 1, you want your most desperate heal as heal 1, etc. These types of things you'd

want to configure in a sense of highest priority first and the rest in that same sort of order.

Reference to Understanding the ModBot WiKi

<text> - Replace this with the respective descriptor 
         Example 1 - <servername>_<toonname> is luclin_bobby
         Example 2 - <toonname> is bobby

(text) - These are "comments" and should be removed when saving the respective file
         Example 1 - Send=1 (If set to 1 it will send netbots information over the network) This text:
         (If set to 1 it will send netbots information over the network) should NOT appear in the INI file
 
[text] - This is to show different options or series of options
         Example 1 - /bc cast <spell alias name> [<toonname>, %t, grp, <spell alias name>, etc]

Plugin requirements & Examples

I suggest you have a good understanding of how to configure each of these plugins. Any misconfiguration can have an adverse affect on the performance of ModBot

MQ2EQBC & EQBCS (/cheer OmniCtrl and ascii38 for this plugin)

MQ2Cast (/cheer A_Enchanter_00 for this plugin)

  • ModBot will create a saved spell set using MQ2cast called ModBot2 and this information is stored in the MQ2Cast.INI file

MQ2NetHeal (/cheer S0rcier for this plugin)

  • The settings are located in <servername>_<toonname>.ini in your MQ2 directory)
/netheal on grab=on send=on
/netcure on

MQ2NetBots (/cheer S0rcier for this plugin)

  • The settings are located in <servername>_<toonname>.ini in your MQ2 directory)
/netbots on grab=on send=on

MQ2Melee (/cheer S0rcier for this plugin)

  • The settings are located in <servername>_<toonname>.ini in your MQ2 directory)
/melee plugin=1
MQ2Bandolier (/cheer wassup for this plugin)
  • If you plan to use item swapping and spell foci items, you may need to configure "sets"
MQ2MoveUtils (/cheer outlander for this plugin)
MQ2Exchange (/cheer wassup for this plugin)
MQ2Twist (For Bards. /cheer Cr4zyb4rd and others for this plugin)  (May also want to look at pages later in the thread.)

Example <servername>_<toonname>.INI for MQ2NetBots, MQ2NetHeal, MQ2Melee:

[MQ2NetBots]
Stat=1
Grab=1
Send=1

[MQ2NetHeal]
Stat=1
Grab=1
Send=1
[MQ2NetCure]
Watch=1

[MQ2Melee]
backstab=50
disarm=1
enrage=1
evade=1
facing=1
hide=1
infuriate=1
melee=200
meleepri=<item ID>
meleesec=<item ID>
petlock=1
petmend=20
petrange=75
pickpocket=1
plugin=1
poker=<item ID>
resume=20
sneak=1
standup=1
stickrange=200
hideif=${If[${Select[${MakeCamp},off]} || !${Defined[CampStatus]},0,1]}
sneakif=${If[${Select[${MakeCamp},off]} || !${Defined[CampStatus]},0,1]}
stickcmd=hold ${If[${Target.Height}<5,10,${Math.Calc[${Target.Height}+7].Int}]} ${If[!${Me.GroupSize} || 
        ${Melee.AggroMode},moveback,${If[${Melee.BackStabbing},behind,!front]}]} ${If[${Me.Underwater},uw,]}
version=3.999

Example MQ2MoveUtils.INI for MQ2MoveUtils:

[Defaults]
AutoPause=on
BreakOnWarp=on
BreakDist=250.0
BreakOnGate=on
Verbosity=1
stuckDist=0.8
turnDirection=10.0
stuckCheck=5
StuckLogic=off

Example MQ2Bandolier_<toonname>.ini for MQ2Bandolier:

[ThisSet] 
17=12345 
13=23456 
14=34567

Example MQ2Cast.INI for MQ2Cast:

[SpellSet.<servername>.<toonname>]
ModBot2=123|1 456|2 789|3

ModBot HUD

[<toonname>_<servername>]
Last=ModBotHUD
SkipParse=7
CheckINI=100
UpdateInBackGround=on
ClassHUD=on
ZoneHUD=on

[ModBotHUD]
Target= 3,060,210,225,225,225,${If[${Target.ID},Dis:${Int[${Target.Distance}]}-Lvl:${Target.Level}-${Target.Class.ShortName}-${Target.PctHPs}%,]}
Name1=  3,060,220,240,240,000,${If[${NetBots.Counts}>=1,${NetBots.Client.Arg[1]} ${NetBots[${NetBots.Client.Arg[1]}].Level} XP:${Int[${NetBots[${NetBots.Client.Arg[1]}].PctExp}]} AXP:${Int[${NetBots[${NetBots.Client.Arg[1]}].PctAAExp}]},NA]} 
HP1=    3,060,230,255,100,100,HP:${If[${NetBots.Counts}>=1,${NetBots[${NetBots.Client.Arg[1]}].PctHPs},]}%
Mana1=  3,105,230,100,100,255,M:${If[${NetBots.Counts}>=1,${NetBots[${NetBots.Client.Arg[1]}].PctMana},]}%
Pet1=   3,145,230,255,255,255,Pet:${If[${NetBots.Counts}>=1 && ${NetBots[${NetBots.Client.Arg[1]}].PetID}>0,${NetBots[${NetBots.Client.Arg[1]}].PetHP},]}%
Name2=  3,060,240,240,240,000,${If[${NetBots.Counts}>=2,${NetBots.Client.Arg[2]} ${NetBots[${NetBots.Client.Arg[2]}].Level} XP:${Int[${NetBots[${NetBots.Client.Arg[2]}].PctExp}]} AXP:${Int[${NetBots[${NetBots.Client.Arg[2]}].PctAAExp}]},NA]} 
HP2=    3,060,250,255,100,100,HP:${If[${NetBots.Counts}>=2,${NetBots[${NetBots.Client.Arg[2]}].PctHPs},]}%
Mana2=  3,105,250,100,100,255,M:${If[${NetBots.Counts}>=2,${NetBots[${NetBots.Client.Arg[2]}].PctMana},]}%
Pet2=   3,145,250,255,255,255,Pet:${If[${NetBots.Counts}>=2 && ${NetBots[${NetBots.Client.Arg[2]}].PetID}>0,${NetBots[${NetBots.Client.Arg[2]}].PetHP},]}%
Name3=  3,060,260,240,240,000,${If[${NetBots.Counts}>=3,${NetBots.Client.Arg[3]} ${NetBots[${NetBots.Client.Arg[3]}].Level} XP:${Int[${NetBots[${NetBots.Client.Arg[3]}].PctExp}]} AXP:${Int[${NetBots[${NetBots.Client.Arg[3]}].PctAAExp}]},NA]} 
HP3=    3,060,270,255,100,100,HP:${If[${NetBots.Counts}>=3,${NetBots[${NetBots.Client.Arg[3]}].PctHPs},]}%
Mana3=  3,105,270,100,100,255,M:${If[${NetBots.Counts}>=3,${NetBots[${NetBots.Client.Arg[3]}].PctMana},]}%
Pet3=   3,145,270,255,255,255,Pet:${If[${NetBots.Counts}>=3 && ${NetBots[${NetBots.Client.Arg[3]}].PetID}>0,${NetBots[${NetBots.Client.Arg[3]}].PetHP},]}%
Name4=  3,060,280,240,240,000,${If[${NetBots.Counts}>=4,${NetBots.Client.Arg[4]} ${NetBots[${NetBots.Client.Arg[4]}].Level} XP:${Int[${NetBots[${NetBots.Client.Arg[4]}].PctExp}]} AXP:${Int[${NetBots[${NetBots.Client.Arg[4]}].PctAAExp}]},NA]} 
HP4=    3,060,290,255,100,100,HP:${If[${NetBots.Counts}>=4,${NetBots[${NetBots.Client.Arg[4]}].PctHPs},]}%
Mana4=  3,105,290,100,100,255,M:${If[${NetBots.Counts}>=4,${NetBots[${NetBots.Client.Arg[4]}].PctMana},]}%
Pet4=   3,145,290,255,255,255,Pet:${If[${NetBots.Counts}>=4 && ${NetBots[${NetBots.Client.Arg[4]}].PetID}>0,${NetBots[${NetBots.Client.Arg[4]}].PetHP},]}%
Name5=  3,060,300,240,240,000,${If[${NetBots.Counts}>=5,${NetBots.Client.Arg[5]} ${NetBots[${NetBots.Client.Arg[5]}].Level} XP:${Int[${NetBots[${NetBots.Client.Arg[5]}].PctExp}]} AXP:${Int[${NetBots[${NetBots.Client.Arg[5]}].PctAAExp}]},NA]} 
HP5=    3,060,310,255,100,100,HP:${If[${NetBots.Counts}>=5,${NetBots[${NetBots.Client.Arg[5]}].PctHPs},]}%
Mana5=  3,105,310,100,100,255,M:${If[${NetBots.Counts}>=5,${NetBots[${NetBots.Client.Arg[5]}].PctMana},]}%
Pet5=   3,145,310,255,255,255,Pet:${If[${NetBots.Counts}>=5 && ${NetBots[${NetBots.Client.Arg[5]}].PetID}>0,${NetBots[${NetBots.Client.Arg[5]}].PetHP},]}%
Name6=  3,060,320,240,240,000,${If[${NetBots.Counts}>=6,${NetBots.Client.Arg[6]} ${NetBots[${NetBots.Client.Arg[6]}].Level} XP:${Int[${NetBots[${NetBots.Client.Arg[6]}].PctExp}]} AXP:${Int[${NetBots[${NetBots.Client.Arg[6]}].PctAAExp}]},NA]} 
HP6=    3,060,330,255,100,100,HP:${If[${NetBots.Counts}>=6,${NetBots[${NetBots.Client.Arg[6]}].PctHPs},]}%
Mana6=  3,105,330,100,100,255,M:${If[${NetBots.Counts}>=6,${NetBots[${NetBots.Client.Arg[6]}].PctMana},]}%
Pet6=   3,145,330,255,255,255,Pet:${If[${NetBots.Counts}>=6 && ${NetBots[${NetBots.Client.Arg[6]}].PetID}>0,${NetBots[${NetBots.Client.Arg[6]}].PetHP},]}%

ModBot Commands & Syntax

ModBot commands are executed in a few different ways:

  • /bc <command>
  • /bc <botname> <command>
  • /bct <botname> <command>
  • /bct <channel name> <command>

Are probably most common but check out the EQBC Forum thread for more methods / features.

You can also configure an alias so you can run modbot on the character you control and execute ModBot commands.

To create the alias you must run this from the EQ prompt:

  • /alias /mb /echo mb-

Or change the LoadAlias variable in MBCommon.inc [Settings] section from 0 to 1 if you've lost the alias in your Macroquest.ini

With this alias you can tell your bot locally what to do:

  • /mb makecamp
  • /mb buffup
  • /mb letsroll
  • /mb <command>

Command Reference


  • dobuffbot [on, true, off, false, <no parameter acts like a toggle>]

Places the bot in "BuffBot Mode". Currently once set to on or true, it will NOT turn off and you MUST restart the macro to "quit" this

mode. It will cast any spell alias on the requesting target. The requester must be a "master".
Example 1 - /t <bot name> buffhp

  • domount [on, true, off, false, <no parameter acts like a toggle>]
To cast a mount or not, used in conjunction with MountCast INI entry
  • domelee [on, true, off, false, <no parameter acts like a toggle>]
  • dodebuffs [on, true, off, false, <no parameter acts like a toggle>]
  • dobuffs [on, true, off, false, <no parameter acts like a toggle>]
  • dosongs [on, true, off, false, <no parameter acts like a toggle>] (used for bards only)
  • doheals [on, true, off, false, <no parameter acts like a toggle>]
  • docures [on, true, off, false, <no parameter acts like a toggle>]
  • dopull [on, true, off, false, <no parameter acts like a toggle>] (not fully production yet)
  • doloot [on, true, off, false, <no parameter acts like a toggle>]
  • doevents [on, true, off, false, <no parameter acts like a toggle>]
  • dosit [on, true, off, false, <no parameter acts like a toggle>]
  • doforage [on, true, off, false, <no parameter acts like a toggle>]
  • dopet [on, true, off, false, <no parameter acts like a toggle>]
To cast a pet or not, used in conjunction with PetCast INI entry
  • dofw [on, true, off, false, <no parameter acts like a toggle>]
  • doafk [on, true, off, false, <no parameter acts like a toggle>]
  • mbpause or mbp [on, true, off, false, <no parameter acts like a toggle>]
Used to pause or unpause the macro
  • mbwayplay <PathName>
Used to playback previously recorded paths / waypoints, through zones, doors, chaining paths, etc.
  • mbwayrec <PathName>
Used to record a path / waypoint. Once started, ducking for each location will add a waypoint to the path. Sitting stops path recording and returns to modbot functions. In order to add doors, chains, pull locations, etc you'll need to edit the MBWayPlay.INI file
  • dolist (Used to /bc out the existing "Do" status)
  • goto <y> <x> (Bot will move to the loc given)
  • mana (Used to /bc out the existing Mana % of the bot)
  • holdup (This will set DoBuffs,DoDebuffs,DoEvents,DoMelee all to FALSE)
  • buffup (This will set DoBuffs & DoEvents TRUE & DoHeals FALSE)
  • attack (Sets DoMelee TRUE and forces bot to attack the TankName's target)
  • attack <name or ID> <engage at HP> <disengage at HP> (Sets DoMelee TRUE and forces bot to attack the target)
Note: OffTank must be TRUE to use this option (I may remove this requirement though TBD)
Example 1 - /bc attack badguy
Example 2 = /bc attack badguy 100 20
  • letsroll (This will set DoBuffs,DoHeals,DoMelee,DoEvents,DoDebuffs TRUE)
  • stop (Will stop following and/or stop in place)
  • makecamp (This will Makecamp at existing location)
  • include <mob name> (Removes <mob name> from alert list, this will not save to the INI file, see exclude save)
  • exclude <mob name,save> (Adds <mob name> to alert list, to save list you must use the "save" option, otherwise it will not be

written to the INI file)

The exclude list is dynamic and will only exclude mobs that are present in the zone AND that are on the list. If you want to force an

exclude you must edit the INI file and place a "#" in front of the mobs name (e.g. ExcludeList=a dusty barrel|a dark coffin|#a bitten

victim|a hollow tree|, this will always force "a bitten victim" to be on the exclude list)

  • follow <name> (Follows the sender or <name>)
  • follow close (Follows the sender within 3 steps, very close)
  • sell <vendor name> (You must be within range of a merchant in order to function, it will sell loot marked as "=SELL" in the

loot.ini file)

  • abort (Interrupts any cast in progress, Sets - DoHeals, DoDebuffs & DoMelee FALSE and follows the sender closely, usefull when

you want to RUN away)

  • campout (Performs a /camp desktop and ends the macro)
  • sing <spellalias> (Will sing this song and add the respective gem number to the Twist.List, it attempts to use detrimental as the

qualifier to add it to combat songs, or rest songs)

  • sung <spellalias> (Will remove this song from the respective Twist.List, it attempts to use detrimental as the qualifier to

remove it from combat songs, or rest songs)

  • script <INI file section name> (This will allow you to run custom commands while the macro is running, or combine series of

commands, see script examples in manual / rev notes)

  • cast <spellalias> <on/off> (This will disable or enable the spell associated with this alias)
  • cast <spellalias> [<spawnname/id> <%t> <grp>] <spellalias> [<spawnname/id> <%t> <grp>] (infinte) (Best explained by example)
  • Example 1 - /bc cast buffhp grp haste bob haste jane dmgshld bob
  • Example 2 - /bc cast dmgshld bob nuke tash
  • Example 3 - /bc cast slow "nasty add"
Cast checks if spell is detrimental it targets the requesters target, if beneficial it targets the sender, if grp is present it casts

buff on group members, if %t is present it targets the requesters target, The cast command will ignore INI settings for things like

minmana, maxmana, recasts, buff debuff counters, etc this is mainly used for manual "one off" type casts)

  • dopull <on/off/path> (Self explanatory. See the instructions on forums.)
  • offtank <on/off> (Toggles offtanking for dealing with adds.)
  • docombines (toggles using the combine button in new tradeskill window when the button is ready.)
  • give <TargetName> <ItemNames> <InStacks> <ItemCount> (Calls the sub GiveCheck to hand an item to a toon or NPC. ItemCount is optional and will default to 1.
  • handin (Target an NPC or PC, get one item on your cursor, and all of that item will be handed to them and trade or give button pressed.)
  • sell <TargetName> (With NPC targeted will attempt to sell all items marked "sell" in your lootIni file to target. Otherwise optional target name can be supplied.)
  • dotells(Toggles a beep when tells are recieved from non-netbots toons. Useful for tells in background sessions)

ModBot in game usage and commands

Example commands:
/bc Bob follow me [This tells bob and only bob to follow me]
/bc cast dd [this tells every bot to cast the spell alias dd]
/bc shamandude cast buffsta grp buffhp focus grp buffhp %T [buffsta on the group, buffhp on the requester, focus on the group, buffhp on requesters target]
/bc necroguy makecamp [this tells "necroguy" to makecamp]
/bc campout [tells all bots to camp to desktop]
/bc exclude ${Target.CleanName} [tells all bots to add your target to the exclude / ignore list, toons will not attack any spawn with that name.]
/bc clericname dobuffs on [tells the cleric to set DoBuffs to true and will then begin buffing group]
/bc pallyguy cast bmb %t buffhp grp [bmb on requesters target, buffhp on the group]
Typical commands sequence for an EXP group:
/bc letsroll
/bc makecamp
You then begin to pull mobs and they will react accordingly.
Mobile Camp Example:
/bc follow
/bc buffup
[once ready zone into the instance]
/bc stop
/bc letsroll
[clear first room lets say]
/bc follow
[move to next room]
/bc makecamp
[etc, repeat]
Example movement options with or without invis
/bc mbp on
/bc follow
Make a EQBC Channel and do things like (using this technique you don't even have to be a master)
/bct mycoolchannelname //mb letsroll
/bct mycoolchannelname //mb campout

ModBot INI Settings

PreFace Notes

  • Spell Alias's must be unique across all alias's
  • You should be familiar or at least capable of making MQ2Bandolier sets as they are used by MQ2Cast for "foci" items
  • Please treat the Buff, Debuff, Event, Heal INI sections as a first in first out (FIFO). Highest priority to lowest priority, you don't

want mez or slow as ADSpell12 but as ADSpell1. You don't want AHHeal1 as Complete Heal, you want AHHeal1 to be DA/DB (those are

examples, use common sense)
References

  • tnt = TankName Target
  • grp = group


Settings Section - [Settings]

  • DoMelee=[TRUE,FALSE]
  • DoHeals=[TRUE,FALSE]
  • DoBuffs=[TRUE,FALSE]
  • DoDebuffs=[TRUE,FALSE]
  • DoEvents=[TRUE,FALSE]
  • DoPet=[TRUE,FALSE] (Must have a completed PetCast entry below, see note for Cleric pets under PetCast below)
  • DoSit=[TRUE,FALSE]
  • DoLoot=[TRUE,FALSE]
  • DoCures=[TRUE,FALSE]
  • DoFW=[TRUE,FALSE] (should I cast spells for food and water, see FoodSpell and DrinkSpell entries)
  • DoForage=[TRUE,FALSE]
  • DoAfk=[TRUE,FALSE]
  • DoPull=[TRUE,FALSE]
  • DoMount=[TRUE,FALSE] (Must have a completed MountCast entry below)
  • DoAura=[TRUE,FALSE] (Must have a completed AuraCast entry below) DEPRICATED!! Set up aura as a buff with 'self aura' as the ABTarType.
  • MasterList=[Bob,John,Billy] (Comma delimited list of names)
  • TankName=[Meat,Brutis] (Comma delimited list of names)
  • ExcludeList=[a hollow tree|a broken barrel|] (Pipe delimited names to exclude, don't forget Pipe at the end)
  • Radius=[100] (Radius that I will monitor for NPCs)
  • SitAggroRadiusCheck=[75] (Radius and aggro check to see if I can sit)
  • FollowDistance=[20] (How far will I stay from followee)
  • FollowStick=[20 hold uw] (If using MQ2MoveUtils, what options do I want used)
  • AfkMessage=[Not now, thanks] (For a custom AFK message, leave blank for none)
  • PetCast=[<pet spell name>|gem<#>|<smii>(for Suspended Minion II)] (Example: PetCast=Animate Dead|gem8|smii)
Mainly MQ2Cast syntax without quotes
           OR 
[charm <AdvDebuff Spell Number> <NPC type 0=any 1=undead,vampyre 2=animal 3=summoned 4=(specify name type)> <list of names>]
(Example: PetCast=charm 4 4 "lowland basilisk,a emerald drake")
(For Cleric Hammer type pets that you only want to cast / have while in combat, 
you MUST have DoPet set to False AND have PetCast=<pet spell name>|<gem<#>,item,alt>) 
  • PetFoci=[-bandolier|petfoci] (Any spell foci you want to swap in for this spell using MQ2Cast syntax,
        you must have previously created the set via the MQ2Bandolier plugin /createset command)
  • PetAggro=[TRUE,FALSE] (Turn pet taunt off or leave on)
  • PetAssist=[1] (Assist and pet attack or not)
  • MountCast=[<Spell,Item,AA name>|<gem<#>,item,alt>] (Example: Collapsable Roboboar|item)
          MQ2Cast syntax without quotes
  • AuraCast=[<Spell,Item,AA name>|<gem<#>,item,alt>] (Example: Uber Aura|gem3) - DEPRICATED! Set up aura as a buff with 'self aura' as ABTarType.
         MQ2Cast syntax without quotes
  • SummonFood=[<spell name,item name,alt name>|<gem<#>,item,alt>] (MQ2Cast syntax)
  • SummonDrink=[<spell name,item name,alt name>|<gem<#>,item,alt>] (MQ2Cast syntax}
  • DeathSlot=[<chest,mainhand,etc>] (Slot you want to look for to determine you are dead, if no entry it looks for chest)
  • TraderName=[<toon name>|bazaar trader] (For use with the Campout command - /bc campout trader will log in whatever toon you have set in the TraderName variable. Second argument (|bazaar trader) will log in the toon and run the bazaar macro with the trader option (or any other mac+options you want there.))


AdvHeal Section - [AdvHeal]

  • AHCount=(Number of heals you plan to have)
  • AHCheckTime=(How often to check for heals in seconds)
  • AHHealOOBC=[TRUE,FALSE] (Do I heal characters outside of Netbots and EQBC, e.g. folks not running MQ2)
  • AHGem1=(Gem number, alt, item, script)
  • AHSpell1=(Spell, Item, Alt Ability, Script name)
  • AHSpellFoci1=(Please see MQ2Bandolier and MQ2Cast to understand how to use swap sets, e.g. -bandolier|<setname>)
  • AHDurMod1=(any spell extension percentage, eg 05 (for 5%), 25 (for 25%))
  • AHSpellMinMana1=(Minimum mana to have in order to attempt this heal)
  • AHSpellAlias1=(Alias name for the heal)
  • AHAnnounce1=[/bc] (Channel to announce in, or leave blank for no announce)
  • AHTarCnt1=(How many targets are required to cast this spell)
  • AHClass1=[pc pet group hp0 war shd pal rng mnk rog brd bst ber shm clr dru wiz mag enc nec tnt self]
         (Any combo there of, see the MQ2NetHeal plugin for full options)
         (Do NOT use 'tnt' if you aren't using a lifetap type spell.)
         (Only use self if the heal spell is SELF ONLY.)
  • AHHealMode=0|0|12 [0 or 1 (off or on)|Heal #|Timer] (This will keep the toon in the heal loop after casting <Heal #> to
           check for additional heals for the duration of <Timer>)
  • AHInterruptLevel=2 (Lowest interruptable spell. AHHealSpell1 will never interrupt if this is set to 2)
  • AHClassPriority=enc,wiz,mag,nec,clr,dru,shm,pal,shd,war,bst,rng,ber,rog,brd,mnk (If you're currently healing a chanter, you won't interrupt for a monk...)
  • AHAllowDismount= (If set to FALSE, your toon will never dismount to interrupt a spell.)


AdvDebuff Section - [AdvDebuff]

  • ADCount=(Number of debuffs you plan to have)
  • ADMobMax=(Max number of NPC's to track, you must also include you group/raid, group/raid pets, etc in the count.
   - If your toons are ignoring NPCs, this number may be set too low.  First thing to check!!)
  • ADCheckTime=(How often to check for debuffs in seconds)
  • ADAggroOnly=[1,0] (If set to 1 it will confirm mobs are aggroed on a group member before adding it to the MobArray
  • ADHold=0|1|1| (This is used much like the AHHealMode setting, but only for type 12 debuffs. Sets a timer to hold the toon in the debuff loop (no buffs or events) until the debuff is complete 1=on 0=off|Debuff spell #|Time to wait for debuff| )
  • ADGem1=(Gem number, alt, item, script, ability, disc, potionbelt) - 'potionbelt' does not require a slot number.
  • ADSpell1=(Spell, Item, Alt Ability, Script name)
  • ADSpellFoci1=(Please see MQ2Bandolier and MQ2Cast to understand how to use swap sets, e.g. -bandolier|<setname>)
   - As of version 2.61 of modbot, "-bandolier|" has been added directly to code.  Use ADSpellFoci1=<setname>
  • ADDurMod1=(any spell extension percentage, eg 05 (for 5%), 25 (for 25%))
  • ADSpellAlias1=(Alias name for the debuff)
  • ADAnnounce1=[/bc] (Channel to announce in, or leave blank for no announce)
  • ADSpellMinMana1=(Minimum mana to have in order to attempt this debuff)
  • ADSpellRecast1=(Number of times to recast this spell for fizzles, interrupts, etc)
  • ADSpellCastonResist1=(Should this spell be resisted, is there another alias to cast before another attempt of this spell, ADSpellRecast must be at least 1)
  • ADSpellDelay1=(How many seconds do I wait between casts of this spell)
  • ADTarCnt1=(How many targets should be present to cast this spell, if set to 0, this spell will not be auto-casted)
  • ADTarType1=(Set this to, 0=All mobs, 1=MA Target only, 2=All except MA Target,
           Priority Debuffs(10, 11, 12) should be placed first most (prior to non-priorities)
           10=All mobs before next spell, 11=MA Target Only, 12=All but MA target before next spell
           settings of 10, 11, and 12 need to be in top spells slots (ADGem1, ADGem2, etc)
  • ADTarBegHP1=(The target must be equal or below this HP%)
  • ADTarEndHP1=(The target must be equal or above this HP%)
  • ADIfSpellImmune1= (This is meant to be a pointer to a quick, one line script that is executed when a mob is immune to the spell you have cast. If you need to do something complicated, other scripts can be called from it. Param1 is now passed as the immune target's ID. example for chanter mez - '/bc {TankName} //multiline ; /varset ACMATarget {Param1};/target id {Param1}')
  • ADUseHoTT1=# (This will cause the macro to /target the mob and check TargetOfTarget before casting and delay # seconds before checking again if mob is skipped. If not a raid or group member, the macro will move on and recheck that mob for that debuff after the time has expired.)


AdvBuff Section - [AdvBuff]

  • ABCount=(Number of buffs you plan to have)
  • ABMobMax=(Max number of targets to track for buffs (do not include pets))
  • ABCheckTime=(How often to check for buffs in seconds)
  • ABProactive=[TRUE,FALSE] (Do I cast buffs before they fade or afterward, if FALSE it will only recast on NetBot clients)
This setting is redundant in current release and will be removed soon.  Leave set as default for best results.
  • ABGem1=(Spell, Item, Alt Ability, Script name)
  • ABSpell1=(Spell, Item, Alt Ability, Script name)
  • ABSpellFoci1=(Please see MQ2Bandolier and MQ2Cast to understand how to use swap sets, e.g. -bandolier|<setname>)
    - As of version 2.61 of modbot, "-bandolier|" has been added directly to code.  Use ABSpellFoci1=<setname>
  • ABDurMod1=(any spell extension percentage, eg 05 (for 5%), 25 (for 25%))
  • ABSpellAlias1=(Alias name for the buff)
  • ABAnnounce1=[/bc] (Channel to announce in, or leave blank for no announce)
  • ABSpellMinMana1=(Minimum mana to have in order to attempt this buff)
  • ABTarCnt1=(How many targets should be present to cast this spell, if set to 0, this spell will not be auto-casted)
  • ABTarType1=[war shd pal rng mnk rog brd bst ber shm clr dru wiz mag enc nec self mypet grp pet cbt idle]
           (ShortClassName used for class specific buffs (ie. haste on "melee")
           (grp for Group spells (e.g. self grp))
           (cbt for spells to be casted during combat (e.g. Yaulp))
           (idle used with cbt for spells to be casted when in or out of combat (e.g. <a fast clicky item>))
  • ABRecast= (Set ABRecast TRUE when you want the macro to use the spell worn off messages from EQ for the macro to know who to cast the buff on. This allows you to rebuff toons that are lower level for your normal buff set, or not in EQBC and not in group. For the most part this shouldn't be needed for rebuffing if all of your toons are NetBots members. The macro actually checks the other toons in netbots and knows what their buffs are, whether the one they're trying to cast will stack, and the duration of the buff if the toon still has it on.


AdvEvent Section - [AdvEvent]

  • AECount=(Number of events you plan to have)
  • AECheckTime=(How often to check for events in seconds)
  • AEGem1=(Spell, Item, Alt Ability, Script name)
  • AESpell1=(Spell, Item, Alt Ability, Script name)
  • AESpellFoci1=(Please see MQ2Bandolier and MQ2Cast to understand how to use swap sets, e.g. -bandolier|<setname>)
  • AEDurMod1=(any spell extension percentage, eg 05 (for 5%), 25 (for 25%))
  • AEDelay1=(How many seconds do I wait between casts of this spell)
  • AEEventMinMana1=(My mana must be at least this to complete this event)
  • AEEventMinHP1=(My HP must be at least this to complete this event)
  • AEMinMana1=(Mana must be above this to complete this event)
  • AEMaxMana1=(Mana must be below this to complete this event)
  • AEMinHP1=(HP must be above this to complete this event)
  • AEMaxHP1=(HP must be below this to complete this event)
  • AETarType1=[war shd pal rng mnk rog brd bst ber shm clr dru wiz mag enc nec self tnt] (Less is better!)
  • AESpellAlias1=(Alias name for the event)
  • AEAnnounce1=[/bc] (Channel to announce in, or leave blank for no announce)


AdvCure Section - [AdvCure]

  • AQCount=(Number of cures you plan to have)
  • AQCheckTime=(How often to check for cures in seconds)
  • AQGem1=(Spell, Item, Alt Ability, Script name)
  • AQSpell1=(Spell, Item, Alt Ability, Script name)
  • AQSpellFoci1=(Please see MQ2Bandolier and MQ2Cast to understand how to use swap sets, e.g. -bandolier|<setname>)
  • AQSpellCureType1=[Poisoned,Diseased,Cursed,All] (Type of cure needed)
  • AQSpellMinMana1=(Minimum mana to have in order to attempt this cure)
  • AQSpellRecast1=(Number of times to recast this spell for fizzles, interrupts, etc)
  • AQTarCnt1==(How many targets should be present to cast this spell, if set to 0, this spell will not be auto-casted)
  • AQTarType1=[war shd pal rng mnk rog brd bst ber shm clr dru wiz mag enc nec cbt] (Any combo of these)
  • AQSpellAlias1=(Alias name for this cure)
  • AQAnnounce1=[/bc] (Channel to announce in, or leave blank for no announce)
  • AQSpellCntr= (currently not used for anything, so don't worry about it :)


AdvMelee - [Melee]

  • OffTank=[TRUE,FALSE] (Do I only attack the MA target or do I assist MA and then not change targets)
  • ACLeash=[Minimum distance to mob to engage, however if "TankName" stays within 20 steps, the bot will exceed this leash]
  • ACAssistPct=(Assist when target HP is this or less)
  • ACManaPct=[Stop assisting when Mana drops below this, set to 0 for melee only, set to 101 for non-melee casters)
  • ACAnnounce=[/bc] (Channel to announce in, or leave blank for no announce)
  • ACMeleeCmd=[/melee plugin=1] (Use to set MQ2Melee commands)
  • ACBefore=(Special script code to execute before you engage, see Note below)
  • ACAfter=(Special script code to execute after you leave combat, see Note below)
Note: ACBefore, ACAfter use ModBot script code (same as MQ2 just no "$".  Here is complex example:

ACBefore=/if ({ACMATarget} && {Spawn[{ACMATarget}].Type.Equal[NPC]} && {Spawn[{ACMATarget}].Distance3D}<={ACLeash} && {Me.CombatAbilityReady[Sneak Attack]} && {Me.Invis} && {Me.Sneaking} && {Me.PctEndurance}>40 && !{Me.Moving}) /call mbscript SneakAttack

These can be more simple, here is a cleric pet hammer example

ACBefore=/if (!{Me.Pet.ID}) /casting ''{PetCast}''

AdvPull Section - [AdvPull]

(this is under development, no ETA)


MBCommon.inc Settings
The location and name of MBCommon.inc can now be set by changing line 38 in Modbot.mac.

/declare MBCommon string outer MBCommon.ini

It defaults to the ./macros folder, but the line can be changed to any path.


Settings Section

  • LoadAlias [1,0] This is an on / off setting to load the "/alias /mb /echo MB-" alias for commands. It is set to 0 after first run when alias should be loaded, but you can set to 1 to add it back to your Macroquest.ini file if it gets deleted.
  • IniLocation Path to your MB_<Toon>.ini files. Must end in / or \ if changed from default.
  • LootIni [Loot.ini] This setting can be used to change the location of your Loot.ini file as well as the name.
  • MBWayPntLocation [MBWayPnt.ini] This setting can be used to change the location of your MBWayPnt.ini file as well as the name of the file.
  • CheckTargetDebuffs [TRUE|FALSE] This setting toggles on/off the ${Target.Buff} checking for debuffs.

ExcludeList

  • Zone.ShortName - List of mobs excluded for that zone in a pipe -"|" delimited string. This setting is not present for any zones which you have nothing excluded.


Immune lists for each spell are now saved in their own section along with a MaxLevel=[100] setting. Change to the max level of the spell. As the macro finds mobs that are immune to the spell, the zone shortname is added to the entry as a variable along with the mob names in pipe delimited format.

ModBot Class INI Examples

ModBot Class INI Examples linked to another page

Scripts and ModBot Variable Usage

ModBot allows VERY customizable sripts to such an extent you can actually program your own sub-procedures within your INI file. You can

harness ANY global variable within ModBot to use with the scripts.
Scripts match MQ2 code to every extent, below are several examples of scripts and common variables one would use to create complex

scripts

Understanding scripts, syntax, example, how to

  • Scripts General Info
  • Scripts can be difficult and there are some MQ2 commands that give scripts trouble. Keep this in mind and prepare to post you script

code should you have problems.

  • No script can take more then 15 seconds to complete however this can be modified in the code directly in the Sub MBScript or even

changed in the script you create ({Timer} is the var)

  • Scripts are executed from top to bottom and you are allowed to use a label :Top (e.g. /goto :Top), in your script. The /goto :Top

option allows for complex loops to take place directly from code in the INI file

  • If you use ANY INI generated ModBot global string variables that have spaces in your custom scripts they MUST be encapsulated by 2

apostrophies when used in the script, see PetCast example below.

  • Reserved Characters
  • These characters can not be used in scripts
  • $ "
  • '' Two apostrophies are for passing variables with spaces in script code. Use them to replace quotes.
  • Syntax
  [Script-<name of script>]
  Commands=<number of statements>
  C1=<Commands>
  .
  Cn=<Commands>

What does a script look like in your INI file:

  [Script-HelloWorld]
  Commands=2
  C1=/echo Hello World
  C2=/if ({Timer}>50) /varset Timer 5s
  C3=/goto :Top

In the example above it will echo to the MQ2ChatWindow "Hello World" for 5s. Notice how I do NOT use a $ to reference the "Timer"

variable.

  • How To use or launch a script
  • /bc bob script HelloWorld
  • You can set XXGem1=script and XXSpell=HelloWorld as a spell name for any of the spells you've configured in ModBot, and it will be

triggered when that event, heal, etc would take place.

Please see the below examples for complex script code.

Common Variables (You can use ANY mq2 variable without the $, you can even CREATE new global vars and use them, all from the INI file via Scripts)

{ACState} = If greater than 0, ModBot thinks you are in combat
{ACMATarget} = The target of the main assist
{CampStatus} = If greater than 0, means I've been given a /bc makecamp command
{FollowFlag} = If greater than 0, means I should be following something
{TankName} = The acting main assist
{Me}, {Spawn}, etc = See MQ2 Manual

Examples
This example is triggered from an event OR a heal and it will remove the necro "Lich" spell:

[AdvHeal]
AHGem3=Script
AHSpell3=DropLich
AHSpellFoci3=
AHDurMod3=0
AHSpellAlias3=droplich
AHSpellMinMana3=0
AHAnnounce3=/bc
AHTarCnt3=1
AHClass3=pc hp40 nec

[AdvEvent]
AEGem3=Script
AESpell3=DropLich
AESpellFoci3=
AEDurMod3=0
AEDelay3=0
AEEventMinMana3=100
AEEventMinHP3=40
AEMinMana3=20
AEMaxMana3=100
AEMinHP3=0
AEMaxHP3=90
AETarType3=tnt
AESpellAlias3=
AEAnnounce3=/bc

[Script-DropLich]
Commands=1
C1=/if ({Me.Buff[Lich].ID}) /notify BuffWindow Buff{Math.Calc[{Me.Buff[Lich].ID}-1].Int} leftmouseup 

This example is launched via the ACBefore command from the [Melee] section, I've got Sneak Attack bound to hotkey 6. What the bot will do

is to trigger Sneak Attack, attempt proper position, backstab the mob, then revert to "normal"

[Script-SneakAttack]
Commands=10
C1=/if ({Melee.Enable}) /melee plugin=0
C2=/if ({Me.CombatAbilityReady[Sneak Attack]}) /keypress 6
C3=/if (!{Me.Moving} && !{Stick.MoveBehind} && {Stick.Distance}!={Math.Calc[{Spawn[{ACMATarget}].MaxRangeTo}+5]}) /stick {Math.Calc[{Spawn[{ACMATarget}].MaxRangeTo}+5]} behind id {ACMATarget}
C4=/if ({Target.ID}!={ACMATarget}) /multiline ; /target id {ACMATarget};/delay 5
C5=/if ({Melee.BackAngle}>60 || {Melee.BackAngle}<-60) /goto :Top
C6=/if ({Target.Distance3D}>={Spawn[{ACMATarget}].MaxRangeTo}) /stick {Math.Calc[{Spawn[{ACMATarget}].MaxRangeTo}-5]} hold behind id {ACMATarget}
C7=/if ({Target.Distance3D}>={Spawn[{ACMATarget}].MaxRangeTo}-3) /goto :Top
C8=/delay 5
C9=/if ({Me.AbilityReady[Backstab]}) /doability backstab
C10=/melee plugin=1

This example will confirm you are hidden and sneaking when I'm at "camp" and not sneaking when I'm in follow mode. It will also

re-engage if MQ2Melee lost "stick" because of too much mob movement

[Script-HideSneak]
Commands=4
C1=/if ({FollowFlag} && {Me.Sneaking}) /multiline ; /doability sneak;/return
C2=/if (!{FollowFlag} && !{ACState} && {Select[{MakeCamp},on]} && {Me.AbilityReady[Hide]} && !{Me.Moving} && !{Melee.Combat}) /multiline ; /doability Hide;/delay 5
C3=/if (!{FollowFlag} && !{ACState} && {Select[{MakeCamp},on]} && {Me.AbilityReady[Sneak]} && !{Me.AbilityReady[Hide]} && !{Me.Moving} && !{Melee.Combat}) /multiline ; /doability Sneak;/delay 5
C4=/if ({ACState} && {ACMATarget} && {Target.ID} && {Me.AbilityReady[Backstab]}) /keypress q

Example of createing a new global var and an example of using it

[Script-EventsOff] 
Commands=2 
C1=/if (!{Defined[CheckSlow]}) /declare CheckSlow int outer 1 
C2=/if ({DoEvents}) /multiline ; /varset DoEvents FALSE;/varset CheckSlow 1  

[Script-EventsOn] 
Commands=2 
C1=/if (!{Defined[CheckSlow]}) /declare CheckSlow int outer 3 
C1=/if (!{DoEvents}) /multiline ; /varset DoEvents TRUE;/varcalc CheckSlow {CheckSlow}+1 

[Script-IsSlowed] 
Commands=3 
C1=/if (!{Defined[CheckSlow]}) /multiline ; /varset DoEvents FALSE;/return 
C2=/if ({CheckSlow}<=4) /varset DoEvents FALSE 
C3=/if ({CheckSlow}>4) /varset DoEvents TRUE;/varset CheckSlow 1

Example of using a ModBot global string. This will create a new pet, say when your existing pet is about to die

  • Please note in the INI snippets below that the INI generated global string PetCast has a space so to pass this properly in the script,

you must encapsulated in quotes, script code uses apostrophies in place of quotes.

[Settings]
PetCast=Invoke Death|gem1

[Script-NewPet] 
Commands=4 
C1=/multiline ; /casting ''{PetCast}'' -maxtries|5;/delay 2s
C2=/if ({Cast.Timing}>600) /goto :Top
C3=/multiline ; /if ({Me.Pet.ID}) /pet go away;/delay 2s !{Me.Casting.ID} 
C4=/if (!{Me.Pet.ID}) /goto :Top

Example of using PetCast for a cleric hammer, to be called from a ACBefore command

[Settings]
DoPet=FALSE
PetCast=Unswerving hammer of awesomeness|gem1
[Melee]
ACBefore=/if (!{Me.Pet.ID} && {ACMATarget} && {Spawn[{ACMATarget}].Type.Equal[NPC]} && {Spawn[{ACMATarget}].Distance3D}<={ACLeash}) /call MBScript SumHam 
[Script-SumHam]
Commands=2 
C1=/if ({Target.ID}!={ACMATarget}) /multiline ; /target id {ACMATarget};/delay 5 
C2=/if (!{Me.Pet.ID}) /multiline ; /casting ''{PetCast}'' -maxtries|2;/delay 3s