Show battle pet level
Hi there,
im trying to create an tag for battle pet level showing, but without any success... Can some one show me right code for this? my code for normal units seems like Code:
tags[myaddon:levelclassification'] = function(unit) |
Third return of C_PetJournal.GetPetInfoByPetID().
Lua Code:
This only works for your current summoned pet. The API does not support getting info from other player's pets, you'll have to scrape their tooltip for their level. |
And what about pet quality? Need to be same summoned?
|
Quote:
health, maxHealth, power, speed, rarity = C_PetJournal.GetPetStats("petID") |
For reference, the default [level] tag:
https://github.com/oUF-wow/oUF/blob/....lua#L221-L232 Lua Code:
|
@p3lim
thank you very much! Exactly what i looked for. Have searched whole google, and didn't found this :D |
All times are GMT -6. The time now is 08:34 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI