API Changes Patch 1.3.0

6,449pages on
this wiki
Add New Page
Comments0 Share

Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.

Quill small

Cleanup needed: This article or section is lacking in some way and needs to be rewritten to conform to Hammerwiki guidelines. Please help by fixing spelling and article structure. It may need editing for style, and appropriate sub-sections, images and templates/tables may need to be added where necessary. If you do rewrite this article, please remove this notice.

The events used by the Scenario Queue window have been changed, because the available queues list is now automatically kept up-to-date:

INTERACT_SELECT_SCENARIO_QUEUE_LISThas been removed. INTERACT_SHOW_SCENARIO_QUEUE_LISThas been added (and should be fired to show the window). INTERACT_UPDATED_SCENARIO_QUEUE_LIST has been added (and is automatically fired by the game when the list of available scenarios is updated).

The potential data returned by GetMapPointData() has been expanded to include some new types of info:

In addition to existing PQ reward types, SystemData.PublicQuestTypes.TOKEN_REWARDSis now also a possible value. The .realmproperty has been added to chapter hubs/warcamps to indicate the owner of that point. Its value will be either GameData.Realm.ORDER or GameData.Realm.DESTRUCTION if applicable. Chapter hubs and warcamps can now potentially be factionless (not controlled by a specific race); so .faction may now be GameData.Factions.NONEfor these points. The .glyphAwardedproperty has been added for PQs that reward a Glyph (LotD). This property will be set to the name of the glyph awarded by the PQ, or nil if no glyph is awarded by the PQ. The .glyphsRequired property has been added for landmarks that require glyphs for entry. If relevant, this property will be a table whose values are the names of the glyphs required; otherwise it will be nil.

With the addition of the new crafting/currency bags, new API functions have been added for those bags and existing functions have been modified to handle them:

SendGuildVaultCommand() and CreateAuction()now both take a second argument to specify which type of backpack should be acted upon. SendMailboxCommand()now takes a second argument which is a table of backpack types to correspond with each item specified. If no items are specified in the command, pass {} instead. The values EA_Window_Backpack.TYPE_CURRENCY and EA_Window_Backpack.TYPE_CRAFTING have been added (in addition to the existing EA_Window_Backpack.TYPE_QUEST and EA_Window_Backpack.TYPE_INVENTORY). The functions GetCraftingItemData() and GetCurrencyItemData() have been added. They behave exactly like GetInventoryItemData(), except that they return tables for the Crafting or Currency backpacks, respectively. Both functions also have corresponding DataUtils functions: DataUtils.GetCraftingItems() and DataUtils.GetCurrencyItems(). Using the DataUtils very is more efficient for repeated access as it does not regenerate the table each time.

The function TransferBetweenBackpacks()has been added to move an item between one backpack and another. The constant GameData.Player.numCraftingSlotshas been added. The constants GameData.ItemLocs.CRAFTING_ITEM and GameData.ItemLocs.CURRENCY_ITEMhave been added. The variable GameData.InteractStoreData.CurrentBackpackIndexhas been added. The events PLAYER_CRAFTING_SLOT_UPDATED and PLAYER_CURRENCY_SLOT_UPDATED have been added. They behave exactly like PLAYER_INVENTORY_SLOT_UPDATED, except for the crafting and currency backpacks respectively.

The function MapBeginAutoUpdating() now takes a third argument, a table of flags specifying which kinds of information on the map should be updated (flags are from the SystemData.AutoUpdateType.* set of constants).

The EA_CityInstanceSelectionWindow module has been removed, since city instances are no longer user-selectable. In addition, the following API elements have been modified due to this change:

The events CITY_CAPTURE_JOIN, CITY_CAPTURE_CLEAR_JUMP, CITY_CAPTURE_LEAVE, and CITY_SCENARIO_INSTANCE_LIST_UPDATEDhave been removed. The function GameData.GetCityInstances()has been removed. The events CITY_CAPTURE_LEAVE_QUEUE and CITY_CAPTURE_FLEEhave been added. The variable GameData.CityQueueData.selectedId has been removed. Instead, use the separate events specified above to specify between leaving the queue and fleeing.

QuestUtils.SetCompletionIcon() no longer takes a boolean value as its first parameter, but instead a questData table. Also, it will now change the slice for the DynamicImage instead of changing the texture.

The function GetGameTime() has been added. It returns the number of seconds elapsed since the game client initialized. This can be used to keep track of things such as talisman timers which are reported relative to the game time.

The attribute bonus system has been rewritten and new API support for it is now available:

GetBuffBonus() and GetItemSetData()have been removed. GetBonus() has been added. It takes two parameters, the first is the id of the attribute you wish to query, and the second is the base value of the attribute. The return value is the total value of the attribute. (This change was made to allow for multiplicative bonuses, as opposed to just additive ones.) and have been removed, as they are unnecessary due to GameData.Player.level which should be used instead.

Registering a Lua event handler for the TextLog-update event corresponding to the UiLog will no longer cause an infinite loop CTD when Function Logging is enabled.

Passing weird types (non-string/number) to error() should no longer cause a CTD.

To support the new opt-out feature for PQs, the following additions have been made:

The event PUBLIC_QUEST_OPTOUThas been added. It supplies two parameters to its handler - the first is the objective id whose opt-out status has been updated, and the second is a boolean value. The function LootRollOptOut()has been added. It takes two arguments, the first being the id of the objective to change the opt-out state of, and the second being a boolean value. The PQData object now has a .optedOut property, as does the table returned by GetPQTopContributors().

EASystem_ActionBarClusterManager has had support for new layout modes added (including the option for a 5th action bar). Specifically, LAYOUT_MODE_3_ACTION_BARS and LAYOUT_MODE_5_ACTION_BARS have been added.

Key bindings are now saved as part of a UI profile. As part of this, the event KEYBINDINGS_UPDATED has been added.

As part of the new Sigils system, the following additions have been made:

TargetInfo:UnitSigilEntryId()can be used to get info on which sigil (if any) a given hostile npc has. Will return 0 if the target is not related to any sigil. The function TomeGetSigilDisplayInfo()has been added. It takes a sigil id and returns an info table for that sigil. The constant GameData.Tome.SECTION_ARMORY_SIGILS has been added.

Related to map support for the Tomb Kings live expansion, the following additions have been made:

The GameData.ExpansionMapRegion.TOMB_KINGSconstant has been added. The function GetZoneRanksForCurrentRealm()has been added. It takes one parameter, the zone id. The RRQProgressBar module has been added to support tracking of the Realm Resource Quests. The GlyphDisplay module has been added to support tracking of Glyphs needed for entry into certain areas. The function EA_Window_WorldMap.CreateAppropriateZoneTooltip() has been added.

The addons window now has enable all/disable all buttons available.

The function DataUtils.PlayerCanEventuallyUseItem() has been added.

Also on Fandom

Random Wiki