Core/Characters: removed unused variables and some demon hunter and evoker leftovers

This commit is contained in:
Ovahlord
2024-09-18 18:58:30 +02:00
parent 1e2b189277
commit 48969b28ca

View File

@@ -760,7 +760,6 @@ void WorldSession::HandleCharCreateOpcode(WorldPackets::Character::CreateCharact
Field* field = result->Fetch();
uint8 accRace = field[1].GetUInt8();
uint8 accClass = field[2].GetUInt8();
// need to check team only for first character
/// @todo what to if account already has characters of both races?
@@ -786,7 +785,6 @@ void WorldSession::HandleCharCreateOpcode(WorldPackets::Character::CreateCharact
field = result->Fetch();
accRace = field[1].GetUInt8();
accClass = field[2].GetUInt8();
if (!haveSameRace)
haveSameRace = createInfo->Race == accRace;
@@ -848,7 +846,7 @@ void WorldSession::HandleCharCreateOpcode(WorldPackets::Character::CreateCharact
});
};
if (allowTwoSideAccounts && !skipCinematics && createInfo->Class != CLASS_DEMON_HUNTER)
if (allowTwoSideAccounts && !skipCinematics)
{
finalizeCharacterCreation(PreparedQueryResult(nullptr));
return;
@@ -856,7 +854,7 @@ void WorldSession::HandleCharCreateOpcode(WorldPackets::Character::CreateCharact
CharacterDatabasePreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_SEL_CHAR_CREATE_INFO);
stmt->setUInt32(0, GetAccountId());
stmt->setUInt32(1, (skipCinematics == 1 || createInfo->Class == CLASS_DEMON_HUNTER || createInfo->Class == CLASS_EVOKER) ? 1200 : 1); // 200 (max chars per realm) + 1000 (max deleted chars per realm)
stmt->setUInt32(1, (skipCinematics == 1) ? 1200 : 1); // 200 (max chars per realm) + 1000 (max deleted chars per realm)
queryCallback.WithPreparedCallback(std::move(finalizeCharacterCreation)).SetNextQuery(CharacterDatabase.AsyncQuery(stmt));
}));
}