FightThisWay

An all-in-one class for HonorBuddy.

What is it?

FightThisWay (FTW) is an all-in-one class for HonorBuddy. It handles pulling mobs, battling mobs, and resting for you.

Why should I use this instead of another custom class?

Here's what's great about FTW:
  1. Easily customizable - simply change the data file to change your play style. Like to open with Rain of Fire? No problem! Like to heal as soon at you get below 100, instead of below 70? Piece of cake. Do you want to never EVER use a certain spell? Just remove those lines.
  2. You don't have to be a rocket scientist to modify the gameplay, thanks to FightThisWay's unique action system - you just need to edit a text file.
  3. Change combat style at runtime. After making your changes and saving them, FightThisWay automatically notices the file has changed, and reloads it at runtime. There's no need to stop and restart HonorBuddy, to preview changes.
  4. Access spells that aren't currently available in HonorBuddy's Spell Manager. All the missing druid and warlock spells are here, and ready to rock!
  5. Customizing it makes you play different than everyone else, so it's less obvious that you're playing with a bot.
  6. Innovative use of the scroll key to handle automatic movement and facing. When the scroll lock key is on, no movement, targeting, or facing is performed, so you can control it yourself. When the scroll lock key is off, everything's automatic. This comes in handy when you want to do dungeons with others, and want it to handle the rotation, while you handle the movement and game mechanics. With scroll lock on, you can 'steer' the bot, and make target choices yourself. If nature calls and you need a quick bio break, turn scroll lock off and let it do its thing.
  7. Works in all dungeons! For the lower level dungeons, you can pretty much ignore it and assume good stuff's happening. For the higher level trickier dungeons, there are large stretches where it can play unattended, but you will eventually need to come back to manually steer out of Mannoroth's fel flames.
  8. When in party, it automatically follows the tank when out of combat, and your current target when in combat.
  9. When in a party in combat, it automatically rezzes any dead tank or healers, if it can - Death Knight 'Raise Ally', warlock 'Soulstone', druid 'Rebirth', etc. It happens so fast you often don't notice someone went down before they've popped back up again.
  10. In party out of combat, it does the 'cheap' rez on everyone, regardless of whether they're a tank or healer - 'Revive' for druids, 'Redemption' for paladins, etc.
  11. It uses a weighting system during combat, and will stop what it's doing and go save the healer, if it must. If it's a tank and it's losing aggro, it will drop the current mob and target the mob he lost aggro on. When things get wild during combat, I just hit 'scroll lock' and let the bot handle it. My bear runs around like he's rabid, regaining aggro on the things he lost it on, far faster than I could have.
  12. It uses a weighting system to pick who to heal, as well. Some classes should never off-heal - feral druid comes to mind, because it breaks form. But for some classes, it's appropriate - tanks can occasionally toss a heal to the worst hurt player, to take the load off the healer, for instance. The worst hurt player pops to the top, with an extra 10 points given if they're a tank or healer, so they're prioritized first in healing.
  13. It can optionally pull only groups of monsters, ignoring onesie-twosies. This is great when farming for cloth, such as the trogg packs in Deepholm.
I use this a lot when in dungeons. It takes all the 'reflex' work out of partying with others, and let's me concentrate on game mechanics, steering, and chat. However, it's also useful for leveling - when out of party, it will do it all.

Where can I get it?

FTW is available via SVN here.

How do I install it?

All the files go into your 'Honorbuddy/Routines' folder, into a new folder called 'FTW'. Now, you could download the files one by one, but that would be tedious and time-consuming. An easier way is to install TortoiseSVN, and checkout the latest changes using the link above. Don't worry, it's not as hard as it sounds! Just follow these instructions:
  1. Download and install TortoiseSVN.
  2. Create a folder called 'FTW' inside the 'Honorbuddy/Routines' folder.
  3. Right-click the FTW folder, and choose 'SVN Checkout...' from the popup menu.
  4. Enter this when it asks you for the URL, and click 'OK': http://fightthisway.googlecode.com/svn/trunk/.
You're done! To grab the latest version whenever there's an update, just redo step 3 above.

After downloading the files via SVN, stop and restart HonorBuddy, if it's running.

How it works:

FTW is controlled by class files containing instructions on how to play your class. These instructions are simply lists of what actions to perform in what order, combined with conditions. Lines that start on the left hand side, are actions. Lines that are indented under them, are conditions for the action above.

Here's an example of an action with its associated conditions:

  • Target.Cast Wrath
    • Me.Mana > 90
    • Target.Health < 10
<-- This is an action
<-- This is a condition
<-- This is another condition
In the example above, your mana must be more than 90%, AND the target's health must be less than 10%, for your character to cast 'Wrath' on the target.

Prefixes

Every action and condition starts with one of the following prefixes. If it doesn't start with one of these prefixes, 'Target' is assumed. The prefixes choose who is checked. For instance, 'Target.Health' returns the target's health, 'Me.Health' returns the player's health, and 'Healer.Health' returns the healer's health.

MeThe player
TankThe tank when you're in a party, the player when not in a party.
HealerThe healer for the party.
TargetThe mob you're currently targeting.
HealThe party member most in need of healing.
PetYour pet.
ReviveA dead party member.
CleanseA diseased party member.

Actions

All the actions you can perform in a class file, are listed below:

Actions that use targets (target is one of the prefixes up above)
BlacklistBlacklists the current target. Only usable with Target.
Cast XXXCasts the spell XXX, waiting for the current spellcast to finish, if any.
CastNow XXXCasts the spell XXX, interrupting the current spellcast if necessary.
CastOnce XXXCasts spell XXX on the target just once. This check expires after 2 minutes. This is useful when determining whether or not to Pickpocket or Dismantle a mob, for instance - those spells always return true regardless if it actually succeeded, and would be cast continuously (eat your rotation) unless they were stopped somehow.
DumpAurasThis lists all the auras on the specified target. It will appear only when loglevel is set to 'diagnostic', as it can get kinda long.
PetCast XXXCasts spell XXX from your pet spell bar, waiting for the current spellcast to finish, if any.
PetCastNow XXXCasts spell XXX from your pet spell bar, interrupting the current spellcast, if necessary.
Use XXXUse item XXX from your inventory.
Actions that don't use targets (target is ignored, specify anything you want - usually 'Me.')
AutoAttackCauses the player to autoattack.
CastAll XXXApplies aura XXX to all enemies. Useful for dotting Corruption on all targets, for instance.
ClipTime XXXStops casting spells XXX milliseconds before they're done ("clips" them.) For max DPS, set this number higher... but if you start getting 'Interrupted's, turn it back down. Set it to 0 to not clip spells.
DrinkCauses the player to drink. Usable in the Rest phase only.
EatCauses the player to eat. Usable in the Rest phase only.
FollowTargetCauses the player to follow their current target, or the tank if in a party and out of combat.
FindBetterTargetCauses the player to look for a better target. Incapacitated mobs will be ignored by default, so the bot will stop targeting the sapped mob and start attacking something else.
GrabAggroLike FindBetterTarget, but prioritizes mobs the tank doesn't have aggro on, over others.
InterruptAny XXXInterrupts the spellcaster that's farthest away, with spell XXX. Useful for ranged interrupts, like 'Silence.'
ImbueWeapon1 XXXCasts XXX on your mainhand weapon. (Useful for shamans to apply Windfury, for instance.)
ImbueWeapon2 XXXCasts XXX on your offhand weapon. (Useful for shamans to apply Flametongue.)
LeaveEarlyCauses script execution to stop here, and resume at the top.
Macro XXXExecutes the specified text XXX as a macro.
Message XXXDisplays a message XXX in the HonorBuddy window.
ParalyzeAny XXXParalyzes the spellcaster that's farthest away, or a mob that's attacking the healer. Useful for ranged stuns, such as 'Paralysis.'
PetAttackCauses your pet to start attacking the target.
PullMore XXXTaunts a mob you're not in combat with, with spell XXX. Useful for getting more adds during the fight, as in the following:
    Me.PullMore Provoke
        Target.AddsCount < 3
        Me.Health > 80
The above example causes you to always fighting at least 3 adds, if possible. It will pull mobs closer to you first, then farther away. How far away it will pull, is dependent upon the range of your taunt.
Range XXXSets your combat range to the number XXX. Melee should use 4.95, ranged should be 20 or higher.
StopCasting XXXStops casting spell XXX, if it's currently casting.
UseHealthPotionCauses the player to drink a health potion from their inventory.
UseManaPotionCauses the player to drink a mana potion from their inventory.
UseBandageCauses the player to use a bandage from their inventory.
DumpAurasDisplays all the auras on the specified unit.

Conditions

All the conditions available for use in a class file, are listed below:

AddsCountThe number of mobs attacking you or your party members. (Exception: If you're in combat by yourself, and there are 0 adds, it will return a list of all mobs within 40 yards of you. This accommodates that bug in WoW where it says you're in combat when you're not, and you have to kill the mobs in a 40 yard radius to get out of combat.)
AggroA number from 0 to 4 indicating how much aggro you have on the target. Tanks should be at 3 or 4, DPS and healers should be 0 to 2.
AllComboPointsAll the combo points you have, on all targets, dead or alive. Useful to check before casting 'Recuperate' out of combat as a rogue.
AuraExpiring("XXX")Returns how many milliseconds until the unit's XXX aura expires. Returns 0 if aura is not there.
AvgHealthThe average health of all members in your party. Useful to check before casting an AOE heal with a large cooldown, such as 'Tranquility.'
BalanceHow much Balance you have, between -100 and 100. (moonkins).
BearFormReturns 1 if druid is in bear form.
BloodRuneHow many blood runes you have.
BurningEmbersHow many burning embers you have, x 10. (Emberbits).
CanCast("XXX")Returns whether or not SpellManager will let you cast spell XXX right now.
CatFormReturns 1 if a druid is in cat form.
CapsLockReturns 1 if caps lock key is down.
ChiHow much Chi you have, a number between 0 and 5.
ClusterSizeHow many enemy mobs are surrounding the specified unit, blacklisted or not. This is a useful thing to check before casting an AOE attack, such as Spinning Crane Kick.
ComboPointsHow many combo points you have on the current target.
DeadReturns 1 if the unit is dead.
DeathRuneHow many death runes are active.
DemonicFuryHow much Demonic Fury you have, a number between 0 and 1000.
DistanceHow far away you are from the unit, ignoring height (Z direction).
EclipseDirectionReturns 1 if the eclipse is moving up, -1 if the eclipse is moving down (moonkin).
EnergyHow much energy you have.
FeralFormReturns 1 if a druid is in either cat or bear form.
FocusHow much focus you currently have.
FlightFormReturns 1 if a druid is in flight form.
FrostRuneHow many frost runes are active.
HasAura("XXX")Returns 1 if the unit currently has an aura named XXX.
HasItem("XXX")Returns 1 if you have at least 1 of item XXX in your inventory.
HasMyAura("XXX")Returns 1 if the unit currently has an aura named XXX, that was applied by the player.
HasSpell("XXX")Returns 1 if the player knows spell XXX.
HasTotem("XXX")Returns 1 if the unit currently has totem XXX out.
HealthHow much health you have.
HolyPowerHow much holy power you have.
InBattlegroundReturns 1 if you're in a battleground.
InPartyReturns 1 if you're in a party or a raid.
InRaidReturns 1 only if you're in a raid.
InterruptableReturns 1 if the unit's spellcast is interruptible. Useful for checking before blowing a cooldown trying to interrupt.
IsBehindReturns 1 if you're behind the unit.
IsBeastReturns 1 if the unit is a beast.
IsCastingReturns 1 if the unit is currently casting any spell.
IsCasting("XXX")Returns 1 if the unit is currently casting spell XXX.
IsCritterReturns 1 if the unit is a critter.
IsDemonReturns 1 if the unit is a demon.
IsDiseasedReturns 1 if the unit has a disease that can be dispelled.
IsDPSReturns 1 if your party role is damager. It doesn't check others, just yourself, so only use with 'Me.'
IsDragonReturns 1 if the unit is a dragon.
IsElementalReturns 1 if the unit is an elemental.
IsEliteReturns 1 if the unit is an elite mob.
IsFacingTargetReturns 1 if the unit is facing their current target (and has a current target.)
IsFleeingReturns 1 if the unit is fleeing.
IsFlyingReturns 1 if the unit is flying.
IsGasCloudReturns 1 if the unit is a gas cloud.
IsGiantReturns 1 if the unit is a giant.
IsHealerReturns 1 if the player is a healer. It doesn't check others, just yourself, so only use with 'Me.'
IsHostileReturns 1 if the unit is hostile to the player.
IsHumanoidReturns 1 if the unit is humanoid (can be pickpocketed!)
IsIncapacitatedReturns 1 if the unit is dead or incapacitated.
IsLootingReturns 1 if the bot is moving towards or looting a lootable mob.
IsMechanicalReturns 1 if the unit is a mechanical.
IsMovingReturns 1 if the unit is moving.
IsNonCombatPetReturns 1 if the unit is a non-combat pet.
IsRootedReturns 1 if the mob is rooted or shackled.
IsTankReturns 1 if the player is a tank. It doesn't check others, just yourself, so only use with 'Me.'
IsTotemReturns 1 if the unit is a totem.
IsUndeadReturns 1 if the unit is undead.
ItemOnCooldown("XXX")Returns 1 if item XXX is on cooldown.
LevelReturns the unit's level.
LevelDiffReturns the unit's level - the player's level. If they're higher level than you this number will be positive - if lower level, it will be negative. This is handy to check when choosing your 'Pull' spell - if they're much lower level than you, you can choose an instant-cast and get it over with quickly.
LineOfSightReturns 1 if the unit is in your line of sight.
ManaReturns the unit's mana percent.
MeleeRange4.95
MoonkinFormReturns 1 if a druid is in moonkin form.
MountedReturns 1 if the unit is mounted.
MyAuraExpiring("XXX")Returns how many milliseconds until the unit's XXX aura, applied by the player, expires. Returns 0 if aura is not there.
MyStackCount("XXX")Returns how many stacks of aura XXX, applied by the player, are on the unit.
NormalFormReturns 1 if a druid is NOT in moonkin, cat, or bear form.
NumItems("XXX")Returns the number of item XXX you have in your inventory.
OnCooldown("XXX")Returns 1 if the spell XXX is on cooldown.
PartyWithAura("XXX")Returns the number of party members that currently have an aura XXX. This is useful to check before casting Uplift, for instance.
PartyWithHealth("XXX")Returns the number of party members with a health <= XXX.
PetIsMissingReturns 1 if your pet is missing.
RageYour current rage.
RuneCountA count of all your active runes (from 0 to 6).
RunicPowerYour current runic power.
ScrollLockReturns 1 if the scroll lock key is down.
SoulShardsThe number of soul shards the player has.
StackCount("XXX")Returns how many stacks of aura XXX are on the unit.
StunCountThe number of stunned mobs near the unit. This is useful to check before casting an AOE spell that will break crowd control.
TotemCountThe number of totems you have out.
UnholyRuneThe number of unholy runes that are active.

Class Files

The list of instructions for each class/spec combo is stored in a separate class file. These files are named with their class/specs, and stored in the 'data' folder inside of FightThisway. These are the files you edit, to change your gameplay style.

File format:

Spell Files

Spell_Overrides.txtThis file contains a list of spell overrides. Spells in this file override HonorBuddy's SpellManager version of this spell, because either the ID is different, the cooldown is different, or the name is different. Add entries to this file when:
  1. You find a spell that's failing to cast, due to HonorBuddy's SpellManager not knowing it. That happened to a lot of spells, when the Mists of Pandaria patch hit.
  2. A spell is casting continuously, eating your rotation, and you want to put a fake cooldown on it. FightThisWay will honor that fake cooldown, and not cast the spell again until its cooldown has expired. Example: Dismantle. No way of knowing in advance whether that spell will succeed or not, but you don't want to keep trying if it fails. Just put a fake cooldown on it, or perform a 'CastOnce' with it, to fix that.
  3. You want to rename a spell to differentiate it from other spells. Example: Mangle (Cat) or Mangle (Bear).
Spell_Stuns.txtContains aura names that should be considered to be stuns. This is useful when the spell mechanic for an aura is 'Disoriented', ie, 'Paralysis'. 'Disoriented' is used so frequently it's useless as a stun check, and it's necessary to check the aura name.
Spell_Cast_Over.txtSpells in this file should never be stopped, the next spell should just cast over them. Example: 'Soothing Mist'.
Spell_Tank_Only.txtSpells in this file should only ever be cast on the tank. Example: 'Misdirection'.
Spell_Target_Circle.txtSpells in this file require a second click, to place the targeting circle. Example: 'Flare'.

Whenever any of the files in the 'FTW/data' folder change, they will all automatically be reloaded by FightThisWay. This means you can tweak your rotation without having to stop and restart HonorBuddy.

Common Problems and Resolutions

My character just sits there, and most of the spells say 'Unknown spell.' Whenever you change class or specs, restart HonorBuddy! Its internal SpellManager will be messed up until you do.
I'm having low framerates If you're having speed problems, check the following
  1. Turn off unnecessary plugins. In particular, LazyRaider is known to cause speed issues with custom classes. Either turn it off entirely, or turn off the 'framelock' option.
  2. For older machines, speed up WoW by running it with higher priority. To do this, you have to run WoW from a batch file. In Windows 7, open up Notepad, copy/paste this in, save as 'Hog.bat' somewhere nice, and then double-click 'Hog.bat'.
    Start "WoW" /high "C:\Program Files (x86)\World of Warcraft\Wow.exe"
    REM /realtimehighest priority
    REM /highhigh priority
    REM /normalnormal priority
    REM /belownormalbelow normal priority
    REM /lowlowest priority

    This would work for all programs, not just WoW. Replace the /high with whatever priority you want (try /high first though.) Replace the pathname to WoW.exe, with the pathname to whatever program you want to run at a different priority. Finally - remember to double-click the bat file, not the program itself!
  3. The performance of HonorBuddy is directly linked to your frame rate. In WoW, under 'Game Menu', 'System', 'Advanced', you'll see a slider called 'Max Background FPS'. Make sure that is set to 30% or higher - you'll have to eyeball it, there's no numbers on it. If the framerate is set too low, and you swap to HonorBuddy to see what cool stuff is happening, your framerate will drop dramatically. To see this in action, drag the 'Max Background Slider'  all the way to the left, which sets it 8fps, and then bring HonorBuddy to the foreground. See how the WoW window has jerky animation, and HonorBuddy starts failing on a lot of spells? Drag it back up to 30% or higher, and it will start working smoothly again.
I'd like to see exactly what spells it is casting. To get a closer look at what your character is doing, create the following macro, drag it to your action bar somewhere, then click it. This is a one-line macro - place all the text you see below on one line, though word-wrapping might cause it to display as more than one line. It will print a message to your chat window containing what spell you just cast, and what its spell ID is.

/run local f=CreateFrame("Frame") f:RegisterEvent("UNIT_SPELLCAST_SUCCEEDED") f:SetScript("OnEvent", function(f,e,u,s,_,_,i) if u=="player" then print(s,i) end end)
My character isn't eating, drinking, picking up loot, healing pet, etc., after combat. FightThisWay is meant to be used with the 'Grind Bot' or 'Questing' bots. If you're using 'Combat' bot, only the 'Combat' routine will run - you must use a different bot, such as 'Grind Bot', to get the 'Rest' behavior to run.

If you don't have a particular grinding profile you want to use, you can use an empty profile with FTW. Here's an empty profile for your use. Copy the following text, paste it into a file called 'Empty Profile.xml', and load that profile to use with 'Grind Bot.'

<HBProfile/>
I'd like to use disengage on my hunter rotation.DON'T TOUCH THAT DIAL! <slaps your hand off that spell.> Disengage will drop you off cliffs, shoot you into packs of wild dogs, and generally turn your smooth-working hunter class into a wild hootenanny. If you want to use it, don't come crying to me when you end up dead at the bottom of the ocean. ;-D