mirror of
https://github.com/whoahq/whoa.git
synced 2026-11-27 08:13:50 +03:00
fix(glue): look up records by index in CCharacterCreation::CalcClasses
This commit is contained in:
1 file changed
+2
-2
@@ -19,7 +19,7 @@ void CCharacterCreation::CalcClasses(int32_t raceID) {
|
|||||||
uint32_t classCount = 0;
|
uint32_t classCount = 0;
|
||||||
|
|
||||||
for (int32_t i = 0; i < g_charBaseInfoDB.GetNumRecords(); i++) {
|
for (int32_t i = 0; i < g_charBaseInfoDB.GetNumRecords(); i++) {
|
||||||
auto infoRec = g_charBaseInfoDB.GetRecord(i);
|
auto infoRec = g_charBaseInfoDB.GetRecordByIndex(i);
|
||||||
|
|
||||||
if (infoRec->m_raceID == raceID) {
|
if (infoRec->m_raceID == raceID) {
|
||||||
classCount++;
|
classCount++;
|
||||||
@@ -31,7 +31,7 @@ void CCharacterCreation::CalcClasses(int32_t raceID) {
|
|||||||
uint32_t classIndex = 0;
|
uint32_t classIndex = 0;
|
||||||
|
|
||||||
for (int32_t i = 0; i < g_charBaseInfoDB.GetNumRecords(); i++) {
|
for (int32_t i = 0; i < g_charBaseInfoDB.GetNumRecords(); i++) {
|
||||||
auto infoRec = g_charBaseInfoDB.GetRecord(i);
|
auto infoRec = g_charBaseInfoDB.GetRecordByIndex(i);
|
||||||
|
|
||||||
if (infoRec->m_raceID != raceID) {
|
if (infoRec->m_raceID != raceID) {
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
Reference in new issue
Block a user