Core/DB: Fixes sometimes wrong values added to DB, also fixes errors when trying to convert updatefield to object.

This commit is contained in:
hondacrx
2021-04-21 18:06:46 -04:00
parent 897ca11273
commit ba064327b0
30 changed files with 149 additions and 89 deletions
+3 -3
View File
@@ -1252,7 +1252,7 @@ namespace Game
// Update name and at_login flag in the db
PreparedStatement stmt = DB.Characters.GetPreparedStatement(CharStatements.UPD_CHAR_NAME_AT_LOGIN);
stmt.AddValue(0, renameInfo.NewName);
stmt.AddValue(1, atLoginFlags);
stmt.AddValue(1, (ushort)atLoginFlags);
stmt.AddValue(2, lowGuid);
trans.Append(stmt);
@@ -1467,7 +1467,7 @@ namespace Game
{
stmt = DB.Characters.GetPreparedStatement(CharStatements.UPD_CHAR_NAME_AT_LOGIN);
stmt.AddValue(0, customizeInfo.CharName);
stmt.AddValue(1, atLoginFlags);
stmt.AddValue(1, (ushort)atLoginFlags);
stmt.AddValue(2, lowGuid);
trans.Append(stmt);
@@ -1794,7 +1794,7 @@ namespace Game
// Race Change
{
stmt = DB.Characters.GetPreparedStatement(CharStatements.UPD_CHAR_RACE);
stmt.AddValue(0, factionChangeInfo.RaceID);
stmt.AddValue(0, (byte)factionChangeInfo.RaceID);
stmt.AddValue(1, lowGuid);
trans.Append(stmt);