Coder Social home page Coder Social logo

libbodyguard-1.0's Introduction

LibBodyguard-1.0

A WoW AddOn library to query information about the player's current bodyguard (if any).

This is still in early progress, the plan is to be able to query any feasible information about bodyguards.

For now, only name, health and last known GUID are available.

Usage

The public API methods have LuaDoc comments, the rest of the code has some stray comments here and there.

To load library if you're using it embedded, specify the load.xml file in your TOC.

Use LibStub to consume the library in your WoW AddOns, just like any other library.

License

Copyright (c) 2014-2015 by Adam Hellberg.

LibBodyguard-1.0 is licensed under the MIT License, see the LICENSE file for more information.

Contributing

Contributions are greatly appreciated! Just submit a pull request and I'll have a look :)

Thanks to

The people at freenode/#wowuidev for being helpful as usual.

libbodyguard-1.0's People

Contributors

ianleeder avatar sarf avatar sharparam avatar

Watchers

 avatar  avatar

Forkers

sarf

libbodyguard-1.0's Issues

New summon mechanic on 6.2 PTR

Currently on live, the bodyguard casts a "Reputation Check" spell when being summoned, on the PTR this has changed, as pointed out by Blazeflack on this ticket on WoWAce.

It is now the player casting two spells when summoning a bodyguard: Maintain <bodyguard name> and Summon <bodyguard name>. Below are details about the UNIT_SPELLCAST_SUCCEEDED events:

UNIT_SPELLCAST_SUCCEEDED
arg1: "player"
arg2: "Maintain Delvar Ironfist"
arg3: ""
arg4: 0
arg5: 173638
UNIT_SPELLCAST_SUCCEEDED
arg1: "player"
arg2: "Summon Delvar Ironfist"
arg3: ""
arg4: 0
arg5: 173633

These will need to be incorporated into the library to properly detect the bodyguard summon again. The relevant spell IDs should be able to be found through Wowhead.

Add support for Legion bodyguards

ℹ️ This issue will be continously updated as new information is gathered.

TODO

  • Detect if a follower is assigned as a "Combat Ally"
  • Detect if said "Combat Ally" is a proper bodyguard (and not just providing some spell)
  • Update library to handle both WoD and Legion bodyguards

Analysis

The library should support Legion bodyguards.

This might require some reworking in how bodyguards are handled, to account for bodyguards from different expansions (WoD and Legion). Or perhaps there can be a seamless transition?

On my Horde Druid, out of the visible followers, only one can be a bodyguard that follows you around in the world: Broll Bearmantle.

The output of C_Garrison.GetFollowers() gives this (trimmed to only show Broll Bearmantle):

[3]={
  displayHeight=0.5,
  followerTypeID=4,
  zoneSupportSpellID=218603,
  iLevel=760,
  scale=0.60000002384186,
  classAtlas="GarrMission_ClassIcon-Druid-Feral",
  isTroop=false,
  displayIDs={
    [1]={
      followerPageScale=1,
      showWeapon=true,
      id=65529
    }
  },
  displayScale=1,
  status="Combat Ally",
  level=103,
  quality=1,
  portraitIconID=1360256,
  isFavorite=false,
  slotSoundKitID=67139,
  xp=702,
  className="Feral Druid",
  classSpec=112,
  isMaxLevel=false,
  name="Broll Bearmantle",
  followerID="0x00000000023CDF49",
  height=1.3500000238419,
  levelXP=800,
  isCollected=true,
  garrFollowerID=641
},

(The above table is inside the first table returned by the function.)

The entry zoneSupportSpellID=218603 gives information on the "Combat Ally" spell for the follower. The output of GetSpellInfo(218603) is the following:

[1]="Bodyguard",
[2]="",
[3]=571585,
[4]=0,
[5]=0,
[6]=40,
[7]=218603

⚠️ This should be tested to see if all Bodyguard followers share that same spell. ⚠️

@InvisiBilldotnet did some investigating and found the following bodyguard spells:

Class Spec Follower Spell
Death Knight Blood Koltira Deathweaver 222365
Demon Hunter Vengeance Belath Dawnblade 222964
Druid Feral Broll Bearmantle 218603
Hunter Survival Addie Fizzlebog 219995
Hunter Survival Rexxar 220814
Mage Fire Millhouse Manastorm 220212
Mage Frost Archmage Modera 220125
Monk Brewmaster Chen Stormstout 211945
Monk Windwalker The Monkey King 212145
Paladin Protection Vindicator Boros 221625
Paladin Retribution Arator the Redeemer 221713
Priest Holy Sol 222080
Priest Shadow Zabra Hexx 222070
Rogue Outcast Akama 222820
Rogue Outcast Shade of Akama 222842
Rogue Outlaw Vanessa VanCleef 221496
Shaman Enhancement Rehgar Earthfury 217849
Shaman Elemental Stormcaller Mylra 218154
Warlock Destruction Ritssyn Flamescowl 216090
Warrior Fury Dvalen Ironrune 222827

Track auras (buffs and debuffs)

As suggested in SharpWoW/BodyguardHealth#12.

CLEU on applied aura (buff):
CLEU dump on applied buff

CLEU on removed/expired aura (buff):
CLEU dump on removed buff

CLEU on refreshed buff:
CLEU dump on refreshed buff

Data:

COMBAT_LOG_EVENT_UNFILTERED
arg 1: <irrelevant>
arg 2: "SPELL_AURA_APPLIED", "SPELL_AURA_REFRESH", "SPELL_AURA_REMOVED"
arg 4: <sender (player) GUID>
arg 5: <sender (player) name>
arg 6: <flags>
arg 7: <flags>
arg 8: <target (bodyguard) GUID>
arg 9: <target (bodyguard) name>
arg 10: <flags>
arg 11: <flags>
arg 12: <aura spell ID>
arg 13: <aura name>
arg 14: <spell school>
arg 15: <aura type, "BUFF"/"DEBUFF">

Might also need to track SPELL_AURA_BROKEN and other similar events.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.