Thread Tools Display Modes
05/03/20, 09:41 AM   #1
gdfou
AddOn Author - Click to view addons
Join Date: Dec 2019
Posts: 3
Get craft material level

Hello,

I am trying to get the level of craft material (from 4 to CP150).
For exemple:
- Rubedite Ingot is CP150-CP160
- Kresh Fiber is CP10 - CP30

How can I do this ?

Thanks
  Reply With Quote
05/03/20, 10:27 AM   #2
Dolgubon
 
Dolgubon's Avatar
AddOn Author - Click to view addons
Join Date: Jan 2016
Posts: 408
Are you at the relevant crafting station? Or is this anywhere? When you're at a station you have some extra functions you can use.
  Reply With Quote
05/03/20, 10:35 AM   #3
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 1,566
The game offers no built in way to do this easily. You'd have to create a lookup table or something.
  Reply With Quote
05/03/20, 11:10 AM   #4
Scootworks
 
Scootworks's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2014
Posts: 312
you could use LibItemLink to get your correct level and item level by using:
Lua Code:
  1. LIB_ITEM_LINK:BuildItemLink(itemId, itemQuality, itemLevel, itemChampionPoints, itemStyle, isCrafted, enchantId, enchantQuality, linkStyle)
  Reply With Quote
05/03/20, 11:24 AM   #5
gdfou
AddOn Author - Click to view addons
Join Date: Dec 2019
Posts: 3
Great thanks !
Ii will try what you tell me
  Reply With Quote
05/03/20, 11:41 AM   #6
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,912
Originally Posted by Scootworks View Post
you could use LibItemLink to get your correct level and item level by using:
Lua Code:
  1. LIB_ITEM_LINK:BuildItemLink(itemId, itemQuality, itemLevel, itemChampionPoints, itemStyle, isCrafted, enchantId, enchantQuality, linkStyle)
This won't "get" you the level but you are setting them yourself as you create an itemlink?

If you want to know what crafting material got what level you need to hardcode it, like the addon "Crafting Material Level Display" does, unfortunately.
Or you need the itemlinks of all these crafting materials and try if GetItemLinkRequiredLevel("itemlink of the crafting material") returns something valid (in the past it didn't and just returned 0 in some cases or other values).

Last edited by Baertram : 05/03/20 at 11:44 AM.
  Reply With Quote
05/03/20, 01:33 PM   #7
votan
 
votan's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2014
Posts: 577
The function GetItemCraftingInfo return rankRequirement. The rank 1-10 defines the levels. The relation must be hard-coded.
  Reply With Quote

ESOUI » Developer Discussions » General Authoring Discussion » Get craft material level

Thread Tools
Display Modes

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