ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   Wish List (https://www.esoui.com/forums/forumdisplay.php?f=177)
-   -   [implemented] GetCharacterInfo() or GetClassInfo() returning wrong values (https://www.esoui.com/forums/showthread.php?t=7963)

Baertram 08/05/18 05:22 PM

[implemented] GetCharacterInfo() or GetClassInfo() returning wrong values
 
Hey there Chip,

the function GetCharacterInfo() is returning the classId of a character as 4th return parameter:
Code:

            --- @return name string,gender [Gender|#Gender],level integer,classId integer,raceId integer,alliance [Alliance|#Alliance],id string,locationId integer
It returns classId = 6 for Templars and classId = 4 for Wardens.

But the function GetClassInfo(classIdndex) is using the classIndex and not the classId so it will not return any data for the classId 6
Code:

    --- @return defId integer,lore string,normalIconKeyboard textureName,pressedIconKeyboard textureName,mouseoverIconKeyboard textureName,isSelectable bool,ingameIconKeyboard textureName,ingameIconGamepad textureName,normalIconGamepad textureName,pressedIconGamepad textureName
Code:

[Empty String]
/esoui/art/icons/icon_missing.dds
/esoui/art/icons/icon_missing.dds
/esoui/art/icons/icon_missing.dds
false
/esoui/art/icons/icon_missing.dds
/esoui/art/icons/icon_missing.dds
/esoui/art/icons/icon_missing.dds
/esoui/art/icons/icon_missing.dds

and it will return wrong data for the classId 4. It's the Templar not the Warden:
Code:

6
Diese wandernden Ritter rufen die Mächte des Lichts und der sengenden Sonne an, um ihren Gegnern massiven Schaden zuzufügen, während sie bei ihren Verbündeten Leben, Magicka und Ausdauer wiederherstellen.
/esoui/art/charactercreate/charactercreate_templaricon_up.dds
/esoui/art/charactercreate/charactercreate_templaricon_down.dds
/esoui/art/charactercreate/charactercreate_templaricon_over.dds
true
/esoui/art/icons/class/class_templar.dds
/esoui/art/icons/class/gamepad/gp_class_templar.dds
/esoui/art/charactercreate/gamepad/charactercreate_templaricon_up.dds
/esoui/art/charactercreate/gamepad/charactercreate_templaricon_down.dds

@ZOS
What about a new function GetClassIndexById(classId) using an internally build mapping table between classID and classIndex so we do not need to rebuild it and build our own code each time?

Kyoma 08/05/18 06:35 PM

I replied on Gitter but I'll reply here too for others. GetClassInfo takes an index, from use with GetNumClasses(), not a classId.

Baertram 08/05/18 06:56 PM

Thanks.

I'm somehow confused why there isn't a returning value "classIndex" within function GetCharacterInfo() then.
This is somehow annoying: Need to build a mapping table between classId and classIndex then :-(

Please move the thread to the WishList @sirinsidiator

@ZOS
What about a new function GetClassIndexById(classId) using an internally build mapping table between classID and classIndex so we do not need to rebuild it and build our own code each time?

ZOS_ChipHilseberg 08/06/18 07:58 AM

Yeah, we can do that.


All times are GMT -6. The time now is 04:10 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI