Thread Tools Display Modes
01/28/15, 08:55 AM   #1
ZOS_ChipHilseberg
ZOS Staff!
Premium Member
Yes this person is from ZeniMax!
Join Date: Oct 2014
Posts: 551
1.6 Addon API Feedback

Feel free to post any questions or concerns about the 1.6 Addon API changes here.
  Reply With Quote
01/28/15, 02:10 PM   #2
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 1,578
Admit it! You are actually testing your updates against our addons to ensure maximum mayhem
I just tried my addons on the pts and most of them won't run without some fixes.

Also a bit sad that there are no updates to the trading house search API. Could use a few improvements.

Other than that I haven't looked to deeply into the changes yet. Will save that for the weekend.
  Reply With Quote
01/28/15, 03:04 PM   #3
ZOS_ChipHilseberg
ZOS Staff!
Premium Member
Yes this person is from ZeniMax!
Join Date: Oct 2014
Posts: 551
Originally Posted by sirinsidiator View Post
Also a bit sad that there are no updates to the trading house search API. Could use a few improvements.
What kind of functions would you like to see added?
  Reply With Quote
01/28/15, 03:11 PM   #4
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,966
Maybe a dumb question but where can I find the changes to the API with patch 1.6 listed?
  Reply With Quote
01/28/15, 03:27 PM   #5
SnowmanDK
 
SnowmanDK's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 161
Originally Posted by Baertram View Post
Maybe a dumb question but where can I find the changes to the API with patch 1.6 listed?
Only thing I have found so far is THIS

btw... is there an issue with existing version of LibMapPins-1.0 in 1.6?
I can't see any changes made to the API that should affect my Destinations addon, but there are no tooltips on ANY of the pins.

Last edited by SnowmanDK : 01/28/15 at 03:30 PM.
  Reply With Quote
01/28/15, 03:38 PM   #6
QuadroTony
Banned
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 828
Originally Posted by ZOS_ChipHilseberg View Post
What kind of functions would you like to see added?
mby this, please

Originally Posted by sirinsidiator
Originally Posted by Ashtaris
Maybe I'm missing something but when I have reset all filters and just do a search in the search field text box for something like "Undaunted" and click Search, it will often return no items found even though I can do a manual search and find all kinds of Undaunted pieces. Is the search limited to one page only or across the entire store?
The name filter is only applied to the current page. This is due to technical limitations of the guild store API.
  Reply With Quote
01/28/15, 03:48 PM   #7
Randactyl
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 251
I haven't really started banging on any of mine yet, but I was pleasantly surprised to log in to only one error message from an addon under my care.

The error was in Dye Station Achievement Links, had to change ZO_Dyeing to DYEING (which was originally how I thought it should have worked, but didn't).

I noticed in the source code some inconsistencies with the usage of collectible/collectable. Might consider ironing that out

I'm excited to see what may be possible with the champion UI, collections UI, and crown store UI.
  Reply With Quote
01/28/15, 04:00 PM   #8
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
Originally Posted by SnowmanDK View Post
Only thing I have found so far is THIS

btw... is there an issue with existing version of LibMapPins-1.0 in 1.6?
I can't see any changes made to the API that should affect my Destinations addon, but there are no tooltips on ANY of the pins.
WorldMap pins have different tooltip creators in patch 1.6. Key "tooltip" is now mode (number betwen 1 and 4) instead of actual tooltip control. In other words just change "tooltip = InformationTooltip," to "tooltip = 1,".
http://www.esoui.com/forums/showthre...8442#post18442
  Reply With Quote
01/28/15, 04:10 PM   #9
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
In one of my addons I'm using item link in the label text:

Lua Code:
  1. zo_strformat("<<1>> (<<t:2>>)", GetString("SI_ITEMSTYLE", ITEMSTYLE_RACIAL_ORC), GetItemLinkName("|H0:item:33257:30:1:0:0:0:0:0:0:0:0:0:0:0:0:3:0:0:0:0|h|h"))
On live server is displayed "Orc (Manganese)", but on PTS just "Orc ()". Is there any change in label control?

Text is set in this code (actualy it is in LibAddonMenu-2.0, this is just simplified version):
Lua Code:
  1. local name = zo_strformat("<<1>> (<<t:2>>)", GetString("SI_ITEMSTYLE", ITEMSTYLE_RACIAL_ORC), GetItemLinkName("|H0:item:33257:30:1:0:0:0:0:0:0:0:0:0:0:0:0:3:0:0:0:0|h|h"))
  2. local label = WINDOW_MANAGER:CreateControl(nil, control, CT_LABEL)
  3. label:SetFont("ZoFontWinH4")
  4. label:SetText(name)
  5. label:SetWrapMode(TEXT_WRAP_MODE_ELLIPSIS)
  6. label:SetHeight(26)


The same goes for tooltip:
Lua Code:
  1. local tooltipText = "|H0:item:16426:1:50:0:0:0:0:0:0:0:0:0:0:0:0:3:0:0:0:0|h|h"
  2. InitializeTooltip(InformationTooltip, control, BOTTOMLEFT, 0, -2, TOPLEFT)
  3. SetTooltipText(InformationTooltip, tooltipText)
If this code is used on live server you will get "Racial Motifs 8: The Orcs", but on PTS you will get just "h".

Last edited by Garkin : 01/28/15 at 04:17 PM.
  Reply With Quote
01/28/15, 04:37 PM   #10
Halja
 
Halja's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 111
Chip thank you for GetAPIVersion. It is small thing but nice to have. I only had a chance to play PTS for a couple hours so far and not delved into add-on parts yet.
  Reply With Quote
01/28/15, 05:01 PM   #11
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 1,578
Originally Posted by ZOS_ChipHilseberg View Post
What kind of functions would you like to see added?
A few suggestions that have gathered in my head over time:
  1. SetTradingHouseFilter currently accepts up to 8 filter arguments.
    In order to be able to implement an "all" subcategory for crafting mats in AwesomeGuildStore I would need to pass 19 arguments to get all the item types.
    A few possible solutions:
    • add 11 more arguments (sounds as bad as it probably is)
    • remove all but one and allow a table to be passed with up to 19 filter arguments (sounds equally as bad)
    • add an EQUIP_TYPE_CRAFTING for crafting items (ugly hack, but probably the easiest solution)
    • add new meta item types that allow to search for item categories (e.g. ITEM_CATEGORY_WEAPON, ITEM_CATEGORY_CRAFTING, etc.) (might be the cleanest solution but probably requires some work in the backend)
  2. New filter types for:
    • item name
    • set name
    • set boni
    • known state (for recipes and motifs)
    • per unit price range
    • stack size range
  3. New sort flag to allow sorting by per unit price.
  4. GetSearchResultPageCount()
    Returns how many pages the current search offers.
  5. GetSearchResultItemCount()
    Returns how many items are found overall with the current search.
  6. SetPendingItemPurchase and GetTradingHouseSearchResultItemInfo only accept a local index within the last searched page.
    If the search results had indices that are independent of the current page it would allow us to locally cache pages and still be able to purchase items regardless of which page of the current search we are requesting.
  7. Increase the search result limit from 100. It would save a lot of time that we loose because of the search cooldown if we could just request more at once.
    Maybe even add a function (SetSearchResultLimit) so we can set it ourselves to any value below a certain hard limit.
    A limit of 5000 results would allow downloading all items in most guild stores in 1-2 request and filtering them locally afterwards.
    This could potentially save a lot of processing power on the server and allow for much faster user interaction.

Would be nice to see any or all of them in the future

Last edited by sirinsidiator : 01/28/15 at 05:04 PM.
  Reply With Quote
01/29/15, 02:29 AM   #12
Sasky
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 231
I wasn't able to get the main API functions to work for setting pending points or adjusting them. ClearPendingChampionPoints doesn't take any arguments, but wouldn't work from /script. I could get a dump of the points in each skill but feeding those same indices back in didn't do anything.

However, I was able to directly update the controls on the ui with something like this:
Lua Code:
  1. function AddPendingPoints(i,j,num)
  2.     CHAMPION_PERKS.constellations[i]:GetStars()[j].pendingPoints = num
  3. end

What's the correct syntax for AddPendingChampionPoints and such? Does it need to be prefixed by particular calls or is it just not working?
  Reply With Quote
01/29/15, 08:57 AM   #13
ZOS_ChipHilseberg
ZOS Staff!
Premium Member
Yes this person is from ZeniMax!
Join Date: Oct 2014
Posts: 551
Originally Posted by Sasky View Post
What's the correct syntax for AddPendingChampionPoints and such? Does it need to be prefixed by particular calls or is it just not working?
The Clear, Add, and Spend functions are meant to be used together in the following way:
1) Clear the pending point storage in the client.
2) Add points that you want to spend by passing the discipline (constellation) index, skill index, and number of points to spend.
3) Call SpendPendingChampion points. If are just adding points, pass in false and the pending points will be interpreted as points to add to each skill. If you are respecing, pass in true and the pending points will be interpreted as the final point values for each skill.

These functions have no impact on the UI. They are just used to pass all of the requested points to the client.
  Reply With Quote
01/29/15, 09:05 AM   #14
Fyrakin
 
Fyrakin's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 129
Actually I was hoping for the Object function SetShapeType to do something usefull .
At least for controlls like Scroll. Values to be passed are SHAPE_BOX and SHAPE_CIRCLE, but it is well known that this function doesn't do anything.
So, my question is - are there any plans on to make SetShapeType do anything at all?
  Reply With Quote
01/29/15, 09:43 AM   #15
ZOS_ChipHilseberg
ZOS Staff!
Premium Member
Yes this person is from ZeniMax!
Join Date: Oct 2014
Posts: 551
Originally Posted by Fyrakin View Post
Actually I was hoping for the Object function SetShapeType to do something usefull .
At least for controlls like Scroll. Values to be passed are SHAPE_BOX and SHAPE_CIRCLE, but it is well known that this function doesn't do anything.
So, my question is - are there any plans on to make SetShapeType do anything at all?
Shape type is only used for mouse hit detection. If shape type is circle, the hit area for the control will be a circle centered over the control center with a diameter equal to the width of the control.
  Reply With Quote
01/29/15, 09:45 AM   #16
Sasky
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 231
Originally Posted by ZOS_ChipHilseberg View Post
The Clear, Add, and Spend functions are meant to be used together in the following way:
1) Clear the pending point storage in the client.
2) Add points that you want to spend by passing the discipline (constellation) index, skill index, and number of points to spend.
3) Call SpendPendingChampion points. If are just adding points, pass in false and the pending points will be interpreted as points to add to each skill. If you are respecing, pass in true and the pending points will be interpreted as the final point values for each skill.

These functions have no impact on the UI. They are just used to pass all of the requested points to the client.
I'll try that. However, one of the cases that I'm thinking would be useful for an addon that distributes points would be to throw all the points into pending but leave the final submit/confirm to the user. That'd need it to update the UI.
  Reply With Quote
01/29/15, 10:31 AM   #17
ZOS_ChipHilseberg
ZOS Staff!
Premium Member
Yes this person is from ZeniMax!
Join Date: Oct 2014
Posts: 551
Originally Posted by Sasky View Post
I'll try that. However, one of the cases that I'm thinking would be useful for an addon that distributes points would be to throw all the points into pending but leave the final submit/confirm to the user. That'd need it to update the UI.
In that case I'd look at ZO_ChampionStar:SpendPoints and ZO_ChampionStar:RemovePoints. And if that doesn't give enough control then you can set the star's pendingPoints member and call the callbacks in ZO_ChampionStar:OnValueChanged to update the UI.
  Reply With Quote
01/29/15, 12:18 PM   #18
ZOS_ChipHilseberg
ZOS Staff!
Premium Member
Yes this person is from ZeniMax!
Join Date: Oct 2014
Posts: 551
Originally Posted by Garkin View Post
On live server is displayed "Orc (Manganese)", but on PTS just "Orc ()". Is there any change in label control?
This is a result of the link format expanding to add a bit for stolen state. Stolen is now the 3rd from the last bit. Enchant Charges/Condition and instance data were pushed down to accommodate it. So it's now: ...Stolen:Enchant Charges/Condition:Instance Data. I'll add that to the patch notes.
  Reply With Quote
01/29/15, 12:35 PM   #19
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
Originally Posted by ZOS_ChipHilseberg View Post
This is a result of the link format expanding to add a bit for stolen state. Stolen is now the 3rd from the last bit. Enchant Charges/Condition and instance data were pushed down to accommodate it. So it's now: ...Stolen:Enchant Charges/Condition:Instance Data. I'll add that to the patch notes.
Ah, thanks. I didn't properly check if the item link is valid on PTS, I was using old item links from the live server.
  Reply With Quote
01/29/15, 12:58 PM   #20
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
There are 4 (or 5) variables leaking to global.

http://www.esoui.com/forums/showpost...1&postcount=16
  Reply With Quote

ESOUI » Developer Discussions » General Authoring Discussion » 1.6 Addon API Feedback


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off