Relic tier information
Is there a way to get tier information without being at the crucible forge?
Basically what I'm trying to do is get the additional item level bonuses. Code:
C_ArtifactUI.GetItemLevelIncreaseProvidedByRelic Code:
local SCANNER = CreateFrame("GameTooltip", "TooltipScanner", nil, "GameTooltipTemplate") |
I'm guessing what you want to do, is capture the extra +5 item levels you get by selecting the first tier from the crucible?
If that is what you are trying to do, C_ArtifactUI.GetRelicSlotRankInfo(relicSlotIndex) can kind of sort of give you what you want indirectly. The first return of that call gives you the number of ranks you purchased from the crucible, so basically if the first return shows a 1, 2 or 3, you can conclude that you are getting the extra +5 from the relic. So I would suggest grabbing the base ilvl using C_ArtifactUI.GetItemLevelIncreaseProvidedByRelic(), then doing a check on the first return of C_ArtifactUI.GetRelicSlotRankInfo(relicSlotIndex) to see if it is greater or equal to 1, and if it does then you can just +5 to the return from the first ilvl lookup. |
Yeah that's what I'm trying to do, grab the +5 item levels line.
However, what you said I already tried which is why I said grab the info without being at the forge / having artifact window open as that's the only time that information is available. With that all in mind I just remembered about forcing the artifact window open through SocketInventoryItem(16) and then with a quick google search I found my solution. Code:
UIParent:UnregisterEvent("ARTIFACT_UPDATE") |
Well still running into an issue...
Code:
local rank = C_ArtifactUI.GetRelicSlotRankInfo(1) |
Okay, try this:
Grab the second return of C_ArtifactUI.GetRelicSlotRankInfo(1) also. The second return is a true/false boolean that lets you know if you can purchase the different tiers at the crucible. If the first return is 1 and the second return is true, then the relic has not yet be given the bonus +5 ilvls, add that check to your code also and you should be good. I just tested the output of the call on a character that I had yet to visit the crucible on and the second return on a rank 1 relic going from true to false after taking the passive at the forge does happen. I was not able to test to see if the user had a high enough artifact weapon with more than one relic tier available and none of them being chosen, so you may run into a slight issue if you are socketing a new relic with enough points to immediately unlock more than 1 tier, but I'm not sure. That would require more testing that I can not do. For example, I'm not sure how the outputs progress when you socket a fresh relic. When you first put in a new relic into slot 1 on a say level 70 artifact, does the first output return 1 or 3? |
I did have the 2nd return value before but, really didn't know what it was telling me so I removed it. Thanks for explaining. I can't check fresh relics atm as I don't have any on my toon that has the crucible unlocked and there's no relic rewards for the specs I don't use atm so, I'll have to do further testing next time one's available.
Thanks again. |
All times are GMT -6. The time now is 01:22 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI