Full state of the live install: prodigeomix fork content plus local OctoWoW patches (MC/Onyxia/ZG/Karazhan timers, Golemagg, Thaurissan, aura-scan perf, world markers), and the BWL changes from raid feedback: - Razorgore: exact egg count via SuperWoW cast events, count synced - Firemaw: Flame Buffet timer on by default, retimed from logs - Blackwing Alchemist: assist marking, no Skull/Cross or mob marks, mark follows the fire chain - Wyrmguard/Overseer: vulnerability read from the buff, one bar per mob with its raid mark and click-to-target - Bars: BigWigs_SetBarRaidMark event to show a raid mark beside a bar Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
190 lines
9.0 KiB
Plaintext
190 lines
9.0 KiB
Plaintext
|
|
-------------------
|
|
modulePrototype API
|
|
-------------------
|
|
module:RegisterYellEngage(yell)
|
|
|
|
module:OnEnable() -- called once when any module is enabled
|
|
module:OnSetup() -- called when a module is enabled or rebooted
|
|
module:OnEngage() -- called on every fight start
|
|
module:OnDisengage() -- called on reboot (eg wipe) or disable (eg victory)
|
|
|
|
module:SendEngageSync()
|
|
module:SendBossDeathSync()
|
|
|
|
module:Sync(sync)
|
|
module:DelayedSync(delay, sync)
|
|
module:CancelDelayedSync(sync)
|
|
module:ThrottleSync(throttle, sync)
|
|
|
|
-- set sound to false for fully silent messages; setting noRaidSay to true prevents personal warnings from being pushed to /rw by the RaidWarn plugin; broadcastOnly is the obverse (no local action, only /rw if enabled through RaidWarn)
|
|
module:Message(text, color, noRaidSay, sound, broadcastOnly)
|
|
module:DelayedMessage(delay, text, color, noRaidSay, sound, broadcastOnly)
|
|
module:CancelDelayedMessage(text)
|
|
|
|
module:Bar(text, time, icon, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10, emphasize, target, spell)
|
|
module:RemoveBar(text)
|
|
module:DelayedBar(delay, text, time, icon, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10, emphasize, target, spell)
|
|
module:CancelDelayedBar(text)
|
|
|
|
module:IntervalBar(text, intervalMin, intervalMax, icon, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10)
|
|
module:DelayedIntervalBar(delay, text, intervalMin, intervalMax, icon, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10)
|
|
|
|
module:ClickBar(text, time, icon, target, spell, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10, emphasize)
|
|
module:DelayedClickBar(delay, text, time, icon, target, spell, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10, emphasize)
|
|
|
|
module:MonitorBar(barName, icon, guid, type, displayText, insertMark, emphazise, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10)
|
|
module:DelayedMonitorBar(delay, barName, icon, guid, type, displayText, insertMark, emphazise, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10)
|
|
|
|
module:CounterBar(barName, max, icon, target, spell, emphasize, timeFormat, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10) -- emphasize defaults to false, timeFormat defaults to "%d"; use module:UpdateBar() to update count
|
|
module:DelayedCounterBar(delay, barName, max, icon, target, spell, emphasize, timeFormat, otherColor, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10)
|
|
|
|
-- Bar Utility Functions - all parameters except the first are optional, just nil what you don't need
|
|
module:UpdateBar(barName, value, displayText, paused) -- value is a number (positive will set remaining time, negative will set elapsed time) used to update paused bars without impacting bar sorting; paused can be true or false
|
|
module:SetBar(barName, timeLeft, timeTotal, timeFormat) -- timeLeft and timeTotal are numbers that will fully adjust bars (which can impact sorting) but leave emphasis events unaffected (recommended to only use on bars without scheduled emphasis - either set to false or start a short bar and then lengthen it using this); timeFormat must be a valid first parameter for string.format
|
|
module:ColorBar(barName, color, bgcolor) -- use PaintChips names (see below)
|
|
registered, time, elapsed, running = module:BarStatus(text)
|
|
|
|
module:Sound(sound)
|
|
module:DelayedSound(delay, sound, id)
|
|
module:CancelDelayedSound(sound, id)
|
|
|
|
module:Icon(name, iconnumber)
|
|
module:RemoveIcon()
|
|
|
|
module:WarningSign(icon, duration, force, text) -- forced overwrites existing signs (but cannot overwrite forced signs)
|
|
module:RemoveWarningSign(icon, forceHide) -- forceHide clears everything
|
|
module:DelayedWarningSign(delay, icon, duration, id)
|
|
module:CancelDelayedWarningSign(icon, id)
|
|
|
|
module:Say(msg)
|
|
|
|
module:Proximity()
|
|
module:RemoveProximity()
|
|
|
|
module:SetRaidTargetForPlayer(player, mark) -- mark can be index or capitalized name
|
|
module:GetAvailableRaidMark(excludeMarks, reverse)
|
|
module:RestorePreviousRaidTargetForPlayer(player)
|
|
module:RestoreInitialRaidTargetForPlayer(player)
|
|
|
|
module:OnEnemyDeath(msg) -- do not register CHAT_MSG_COMBAT_HOSTILE_DEATH
|
|
module:OnFriendlyDeath(msg) -- do not register CHAT_MSG_COMBAT_FRIENDLY_DEATH
|
|
|
|
|
|
----------------
|
|
Helper Functions
|
|
----------------
|
|
|
|
BigWigs:CancelAuraId(spellId) -- requires SuperWoW
|
|
BigWigs:CancelAuraTexture(texture)
|
|
BigWigs:BuffNameByIndex(buffIndex) -- returns localized name from tooltip
|
|
BigWigs:BuffIsPresent(unitId, spellId) -- check UnitBuff(), return true or nil
|
|
BigWigs:DebuffIsPresent(unitId, spellId) -- check UnitDebuff(), return true or nil
|
|
BigWigs:AuraIsPresent(unitId, spellId) -- check both, return true or nil
|
|
BigWigs:GetCastTimeCoefficient(unitId) -- return cast time multiplier based on presence of Curse of Tongues and Mind-numbing Poison on the unit
|
|
|
|
-- depth (integer) specifies which units to scan (0 = raidN, 1 = raidNtarget, 2 = raidNtargettarget, etc).
|
|
BigWigs:GetUnitIdByName(name, depth) -- returns "raidN", "raidNtarget", etc
|
|
BigWigs:GetTargetByName(name, depth) -- returns "targetName" of named unit
|
|
BigWigs:GetGUIDByName(name, depth, ignoredGUIDs) -- ignoredGUIDs must be a table
|
|
BigWigs:OffsetGUID(input, offset) -- adds offset (signed integer) to GUID string
|
|
|
|
BigWigs:RaidTargetLookup(input, colorize) -- For string input (eg "star", "Circle", "none") returns raid target index for use with SetRaidTarget(unit, index). For integer input (eg 1, 8, nil) returns raid target name to translate the output of GetRaidTargetIndex(unit); if colorize arg is provided, the name will be returned as a colorized string.
|
|
|
|
BigWigs:FormatLargeNumber(integer) -- returns the 4 most significant digits as a string (eg "42", "3172", "80.93k", "143.2k", "2168k", "45.82m")
|
|
|
|
BigWigs:GetHealthPercent(unitId, round) -- returns nil if unit does not exist
|
|
|
|
|
|
----------------
|
|
Available Colors
|
|
----------------
|
|
|
|
Message Colors - Plugins\Messages.lua & Plugins\Colors.lua
|
|
--------------
|
|
Messages sent by module:Message() default to white color. There are 3 ways of coloring them:
|
|
|
|
A) Urgency Keywords
|
|
You can use certain Keywords to access colors representing different levels of urgency, as provided by the Colors plugin. Keywords need to be capitalized. Below you can find the default values, but users can change them through the in-game menu at Plugins>Colors>Messages (which can be very important to color-blind people, so I suggest mostly sticking to Keywords to allow users customization):
|
|
Important = Red = "ff0000"
|
|
Personal = "ff0000"
|
|
Purple = "660099"
|
|
Urgent = Orange = "ff7f00"
|
|
Attention = Yellow = "ffff00"
|
|
Positive = Green = "00ff00"
|
|
Bosskill = "00ff00"
|
|
Core = Cyan = "00ffff"
|
|
ex: self:Message("Hello World", "Urgent")
|
|
|
|
B) RGB Tables
|
|
The color argument of Message() accepts a table with 3 key-value pairs of r, g, b directly, where the value has to be a number between 0 and 1.
|
|
ex: self:Message("Hello World", {r=1, g=0.5, b=0.5})
|
|
|
|
C) PaintChips
|
|
Colors that do not fit either of the above patterns (captialized keywords, RGB table) will be attempted to be resolved through the PaintChips library (see below).
|
|
ex: self:Message("Hello World", "magenta")
|
|
|
|
|
|
PaintChips - Libs\PaintChips-2.0\PaintChips-2.0.lua
|
|
----------
|
|
Colors are handled by the PaintChips library, so all new colors need to be registered with it for use with messages or bars. The Colors plugin offers an easy way to register custom colors on the fly via BigWigsColors:RegHex(hex) for use in a module's OnEnable().
|
|
ex: BigWigsColors:RegHex("3366CC")
|
|
|
|
PaintChips runs all incoming strings through string.lower(), so capitalization does not matter (both when registering and when recalling).
|
|
|
|
Hardcoded colors in PaintChips:
|
|
white = "ffffff"
|
|
black = "000000"
|
|
blue = "0000ff"
|
|
magenta = "ff00ff"
|
|
cyan = "00ffff"
|
|
green = "00ff00"
|
|
yellow = "ffff00"
|
|
orange = "ff7f00"
|
|
red = "ff0000"
|
|
|
|
PaintChips also makes colors from the client's UI available (note - addons may change these, below are only default values!):
|
|
DebuffTypeCurse = "9900ff"
|
|
DebuffTypeDisease = "996600"
|
|
DebuffTypeMagic = "3399ff"
|
|
DebuffTypePoison = "009900"
|
|
DebuffTypenone = "cc0000"
|
|
|
|
DRUID = "ff7d0a"
|
|
HUNTER = "abd473"
|
|
MAGE = "69ccf0"
|
|
PALADIN = "f58cba"
|
|
PRIEST = "ffffff"
|
|
ROGUE = "fff569"
|
|
SHAMAN = "2459ff" -- TBC (eg ShaguTweaks), unmodded 1.12 = same as paladin
|
|
WARLOCK = "9482c9"
|
|
WARRIOR = "c79c6e"
|
|
|
|
ItemQuality0 = ItemQualityPoor = "9d9d9d" -- grey
|
|
ItemQuality1 = ItemQualityCommon = "ffffff" -- white
|
|
ItemQuality2 = ItemQualityUncommon = "1eff00" -- green
|
|
ItemQuality3 = ItemQualityRare = "0070dd" -- dark blue
|
|
ItemQuality4 = ItemQualityEpic = "a335ee" -- purple
|
|
ItemQuality5 = ItemQualityLegendary = "ff8000" -- orange
|
|
ItemQuality6 = ItemQualityArtifact = "e6cc80" -- gold
|
|
|
|
Plugins\Colors.lua registers hardcoded raid target (raid mark) colors:
|
|
unmarked = "bababa" -- light grey
|
|
Star = "ffff00" -- yellow
|
|
Circle = "ffa500" -- orange
|
|
Diamond = "ff20ff" -- purple
|
|
Triangle = "00ff00" -- green
|
|
Moon = "e0ffff" -- very light cyan
|
|
Square = "00baff" -- bright blue
|
|
Cross = "ff2020" -- red
|
|
Skull = "ffffff" -- white
|
|
|
|
|
|
Color Utility Functions - Plugins\Colors.lua
|
|
-----------------------
|
|
BigWigsColors:RegHex(hex) -- hex can be a string or a table of strings
|
|
BigWigsColors:RGBToHex(r, g, b) -- r/g/b are between 0 and 1, returns hex string
|
|
BigWigsColors:ColorizeString(input, color) -- returns input string colorized
|
|
|
|
|