Wikia

WoWWiki

Patch 2.4.0/API changes

Talk0
101,513pages on
this wiki

< Patch 2.4.0 | Redirected from Patch 2.4.0/Consolidated API changes


This article covers the cumulative AddOn UI Customization and Macro API changes for Patch 2.4.0. See API change summaries for a list of API change summaries for all patches.
API change summaries

Significant Changes Edit

  • The combat logging mechanism is completely overhauled with explicit data instead of text strings delivered to the UI. See slouken's post below for a sneak-peak at some of the current details. Highlights include detailed flags indicating relationship of involved units to player, unique identifiers for units with the same name within the combat log -- great for log analysis.
  • The In-game Interface Options screen is being revamped and the new architecture should allow AddOn authors to modify its contents without the taint issues presented by the current system. Additionally this system will contain an area for AddOn authors to present their own configuration options. Authors interested in this feature should be sure to experiment on the PTRs before patch 2.4 is released so that any issues can be surfaced and discussed. Basic details on how to use this system can be found in code comments in the 2.4 UIOptionsPanels.lua.

Events Edit

Secure Templates Edit

  • The SecureStateHeader now provides a mechanism to change its own attributes in response to state changes.

Debugging Edit

  • In 2.4, you'll be able to pass a coroutine as a first (optional) parameter to debugstack()

Visual Settings Edit

  • There's a new cVar unitHighlights; 0 = no model highlighting with Alt-Z, 1 = model highlighting on with Alt-Z. (e.g. /console unitHighlights 1)
  • Players can now toggle the display of Friendly and Enemy player names, as well as their pets and creations. You can toggle cosmetic pet names too. :)

Tooltip Methods Edit

Font String Display Edit

  • Textures can now be included in FontStrings locally using a new | escape code: |T<path>:<width>[:<height>:<xOffset>:<yOffset>]|t
  • Selected textures can also be included in Chat messages and sent to other users, the current available textures are represented in a form like: {star}

Character Functions Edit

Channel Functions Edit

Combat Log Functions Edit

Friend Functions Edit

Guild Functions Edit

Guild Bank Functions Edit

Inventory Functions Edit

  • NEW - freeSlots, itemFamily = GetContainerNumFreeSlots(bagIndex) -- Returns the number of free slots in a bag, and the type of items that can go in the bag. For bagType, 0 means any item can go in the bag.

Item Functions Edit

  • NEW - bagType = GetItemFamily(itemId or itemName or itemLink or itemString) -- When used with a container, this returns the type of container. When used with an item, it returns the type of container the item can go in. However, bagType is a bitflag, so GetItemFamily for something that could go in a quiver (bagType 1) and an ammo pouch (bagType 2) would return 3. A bag that can hold both arrows and bullets would also return 3.
    • 0 = Unspecified (for bags it means any item, for items it means no special bag type)
    • 1 = Quiver
    • 2 = Ammo Pouch
    • 4 = Soul Bag
    • 8 = Leatherworking Bag
    • 16 = Unknown
    • 32 = Herb Bags
    • 64 = Enchanting Bags
    • 128 = Engineering Bag
    • 256 = Keyring
    • 512 = Gem Bag
    • 1024 = Mining Bag
    • 2048 = Unknown
    • 4096 = Vanity Pets
  • NEW - icon = GetItemIcon(itemId or itemName or itemLink or itemString) -- Returns the icon for an item (as long as the item is valid), even if GetItemInfo returns nil.

Quest Functions Edit

Language Functions Edit

Loot Functions Edit

  • NEW - isOptOutOfLoot = GetOptOutOfLoot()
  • NEW - SetOptOutOfLoot(boolean)
    • false: You are now eliglible for random loot.
    • true: You are now passing on random loot.

Spell Functions Edit

  • NEW - name, rank, icon, cost, isFunnel, powerType, castTime, minRange, maxRange = GetSpellInfo(spellId or spellName or spellLink)
  • NEW - spellLink = GetSpellLink(spellId or spellName or spellLink)
  • NEW - spellLink = GetTalentLink(tab, index[, inspect])

Summon Functions Edit

Totem Functions Edit

  • NEW - haveTotem, name, startTime, duration, icon = GetTotemInfo(slot)
    • 1 = Fire
    • 2 = Earth
    • 3 = Water
    • 4 = Air
  • NEW - timeleft = GetTotemTimeLeft(slot)

Unit Functions Edit

  • NEW - healthMod = GetUnitMaxHealthModifier("unit")
  • NEW - inRange = UnitInRange("unit") -- Determines if a unit is within a (fixed by Blizzard) useful range based on flash heal/cure range) This is now used by the Blizzard Raid UI
  • NEW - classLocal, class = UnitClassBase("unit")
  • NEW - raceLocal, race = UnitRaceBase("unit")
  • NEW - guid = UnitGUID("unit") -- Returns a string representing a unique identifier for the given unit. This is the same string that is used in the combat log to identify a unit.

Unknown Functions Edit

Around Wikia's network

Random Wiki