Quantcast Notable API changes in Legion - Page 2 - WoWInterface
 
Thread Tools Display Modes
04-15-16, 02:11 AM   #21
ObbleYeah
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Sep 2008
Posts: 210
ah, okay! (10chars)
 
04-15-16, 05:24 AM   #22
Lombra
A Molten Giant
 
Lombra's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2006
Posts: 554
Originally Posted by ObbleYeah View Post
that is such a weird call name to choose over just consolidating it all into UnitIsTapped
I could agree with the new function sounding a bit complicated, but it should make more sense. What the current UnitIsTapped actually means is... "UnitIsTappedBySomeoneElse". Had to look that up actually, thought it meant "UnitIsNotYetTappedBySomeoneElse".
__________________
Grab your sword and fight the Horde!
 
04-24-16, 11:12 AM   #23
galvin
A Frostmaul Preserver
Join Date: Nov 2006
Posts: 263
Anyway to turn a fileID back into a path name?
GetSpellInfo now returns a fileID instead of path on the 3rd parm. I have a spell scanner, and it excludes spells that are professions, by looking at the path name.

Also is there anyway to quickly find out if a spell with a cast time returns a resource. Like Lava Burst spellID 51505. This returns 12 maeslstrom. Balance druids have a few spells that return resource as well.

Edit: Took the hard way and scanned the spell book for spells with cast times that return power.

Last edited by galvin : 04-24-16 at 06:39 PM.
 
04-24-16, 07:14 PM   #24
TOM_RUS
A Warpwood Thunder Caller
Join Date: Sep 2008
Posts: 95
Originally Posted by galvin View Post
Anyway to turn a fileID back into a path name?
GetSpellInfo now returns a fileID instead of path on the 3rd parm. I have a spell scanner, and it excludes spells that are professions, by looking at the path name.
You can't. Unless you want to use hardcoded table with id->name that can be exported from db2 file...
 
04-24-16, 11:44 PM   #25
galvin
A Frostmaul Preserver
Join Date: Nov 2006
Posts: 263
So anyway I can exclude profession spells?
 
04-25-16, 01:50 AM   #26
TOM_RUS
A Warpwood Thunder Caller
Join Date: Sep 2008
Posts: 95
I don't think this information is exposed through the API, you can make a suggestion for blizzard... Few lines of code to make someone happy, may be they consider it worthy?
 
04-25-16, 02:56 AM   #27
ObbleYeah
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Sep 2008
Posts: 210
could you compare against type with GetSpellBookItemInfo?

edit: heh, just saw your own post edit

Last edited by ObbleYeah : 04-25-16 at 03:05 AM.
 
04-25-16, 05:15 PM   #28
galvin
A Frostmaul Preserver
Join Date: Nov 2006
Posts: 263
I want it to scan all spells, not just player.
 
05-01-16, 04:22 PM   #29
galvin
A Frostmaul Preserver
Join Date: Nov 2006
Posts: 263
Fonts can get really large now, some where around 180 to 190 is the max size. And even at huge size they look really good, they stay smooth, doesn't get pixelated. It wouldn't throw an error so I have no way to find out the max value. 31 or 32 has always been the max size on live.

font size video https://www.youtube.com/watch?v=jYGA5qFDqGc

Last edited by galvin : 05-01-16 at 04:37 PM.
 
05-04-16, 05:23 PM   #30
galvin
A Frostmaul Preserver
Join Date: Nov 2006
Posts: 263
Found out how to filter out trade skills when looking thru spells.
local TradeSkillID = C_TradeSkillUI.GetTradeSkillLineForRecipe(TradeSkillID)

Comes back nil then its not a spell that belongs to any crafting.
 
05-04-16, 10:14 PM   #31
TOM_RUS
A Warpwood Thunder Caller
Join Date: Sep 2008
Posts: 95
Originally Posted by galvin View Post
Found out how to filter out trade skills when looking thru spells.
local TradeSkillID = C_TradeSkillUI.GetTradeSkillLineForRecipe(TradeSkillID)

Comes back nil then its not a spell that belongs to any crafting.
I guess parameter is spellID, not TradeSkillID then?

In blizz UI they call it "recipeID", and use that value for both C_TradeSkillUI.GetTradeSkillLineForRecipe and GetSpellInfo, so it's safe to assume it's spell id after all.
 
05-05-16, 01:04 AM   #32
galvin
A Frostmaul Preserver
Join Date: Nov 2006
Posts: 263
I just run a spellID thru it. but in some of their code they call it tradeskillid. But its still a spellID.
 
05-12-16, 10:56 PM   #33
Ketho
A Molten Giant
 
Ketho's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2010
Posts: 883
Why are GlobalStrings.lua and GlueStrings.lua gone from the FrameXML?
Is it a bug with extracting the game files or are they now defining it in C?

https://github.com/Gethe/wow-ui-sour...a14341ad01c955

Edit: Ow, okay...

Last edited by Ketho : 05-12-16 at 11:08 PM.
 
05-12-16, 10:59 PM   #34
Gethe
RealUI Developer
 
Gethe's Avatar
Premium Member
Featured
Join Date: Sep 2008
Posts: 924
They moved the global strings to a db file.
__________________
Knowledge = Power; Be OP

 
05-13-16, 04:37 AM   #35
SinusPi
A Deviate Faerie Dragon
AddOn Author - Click to view addons
Join Date: Nov 2008
Posts: 13
DrawLine isn't exactly anything revolutionary, sadly. It's just a shortcut to rotating and resizing texture A on top of texture B so that it resembles a line. It's actually Iriel's code, congratulations on getting featured

Code:
DrawLine(texture, canvasFrame, startX, startY, endX, endY, lineWidth, lineFactor, relPoint)

Last edited by SinusPi : 05-13-16 at 04:40 AM.
 
05-13-16, 09:21 AM   #36
Zavian
A Deviate Faerie Dragon
 
Zavian's Avatar
AddOn Author - Click to view addons
Join Date: Jan 2016
Posts: 10
It seems GetItemTransmogrifyInfo() it's been removed. Occuring here
Lua Code:
  1. local canBeSource = select(3, GetItemTransmogrifyInfo(item))
 
05-13-16, 10:50 AM   #37
VincentSDSH
Non-Canadian Luzer!
 
VincentSDSH's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2006
Posts: 350
Originally Posted by icyblade View Post
  • We can use texture:SetTexture(file_id) now, so GetSpellInfo will not return a texture path as the 3rd return value
We use this code to set an icon now:
Lua Code:
  1. local _, _, icon = GetSpellInfo(spell_id)
  2. texture:SetTexuture(icon)
In Legion, that's easier:
Lua Code:
  1. file_id = GetSpellTexture(spell_id)
  2. texture:SetTexuture(file_id)
Ok, guess I'll be muggins here but can you get the file path somehow or other? From my testing, bgFile doesn't take those index numbers well. (nb: result is a green frame)

lua Code:
  1. local _, _, _, _, _, _, _, _, _, itemTexture = GetItemInfo(v)
  2. hFrame:SetBackdrop( { bgFile = itemTexture })
__________________
AddonsExecutive Assistant User Configurable To-Do ListLegible Mail Choose the Font for Your Mail
 
05-13-16, 06:01 PM   #38
SinusPi
A Deviate Faerie Dragon
AddOn Author - Click to view addons
Join Date: Nov 2008
Posts: 13
GetNumDungeonMapLevels() now - contrary to its name! - returns not the total number, but a list of valid floor numbers on the current map.

lua Code:
  1. local dungeonLevels = { GetNumDungeonMapLevels() };
  2.     for id, floorNum in ipairs(dungeonLevels) do
  3.         ...
  4.     end
 
05-13-16, 06:15 PM   #39
MunkDev
A Scalebane Royal Guard
 
MunkDev's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2015
Posts: 425
Does someone know how to get the localized string for items now that GetAuctionItemClasses has been removed?

This is what I used to have:
Lua Code:
  1. local QUEST = select(10, GetAuctionItemClasses())
__________________
 
05-13-16, 11:28 PM   #40
syncrow
A Flamescale Wyrmkin
 
syncrow's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2014
Posts: 149
New 7th parameter for GetGossipAvailableQuests() - isIgnored

Lua Code:
  1. for i = 1, GetNumGossipAvailableQuests() do
  2.     local name, level, isTrivial, frequency, isRepeatable, isLegendary, isIgnored = select(i*7-6, GetGossipAvailableQuests())
  3.     print(name, level, ...)
  4. end
__________________

Last edited by syncrow : 05-13-16 at 11:34 PM.
 
 

WoWInterface » Site Forums » Archived Beta Forums » Legion Beta archived threads » Notable API changes in Legion

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