Buffet ignores Demonic Runes/Dark Runes after scan (Classic)
skywardpixel opened this issue ยท 0 comments
Describe the bug
After a scan, Demonic Runes and Dark Runes are no longer recognized by Buffet.
My analysis
Looks like Core.Scan
fails to parse the description text of Demonic Runes and Dark Runes, causing them to be ignored after 5 failed scans.
The description reads
Use: Restores 900 to 1500 mana at the cost of 600 to 1000 life. (2 Min Cooldown)
B/c this contains the word life
, it is categorized as isHealth
in addition to isMana
. Therefore in Engine.ParseValues
, the code loops through patterns of Locales.Patterns.HealthAndMana
(as opposed to Locales.Patterns.Mana
), which do not match Demonic Rune's description text. They ended up being scanned with isMana = true
and mana = 0
, which is considered invalid.
Proposed Fix
Maybe consider adding a condition in Engine.CheckHealth
: if the text contains "at the cost of ... life/health", do not categorize it as isHealth
.
Alternatively, simply whitelist these two items (12662, 20520) to not ignore them during scanning.
To Reproduce
Steps to reproduce the behavior if applicable:
- Have a Demonic Rune or Dark Rune in the bag.
- Reload, and type
/buffet bests
. The Demonic Rune or the Dark Rune is shown. - Add something else to the bag to trigger another scan.
- Type
/buffet bests
again. Runes are no longer shown.
Related Item
Please provide a WowHead link to the related item if applicable:
Language
Please specify the language of your wow client: enUS