Core/PacketIO: Updated packet structures to 9.2.5
Port From (https://github.com/TrinityCore/TrinityCore/commit/d3c4216de8e1dcb9f62d2fcc1b9b72852e5409c9)
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -17,22 +17,57 @@
|
|||||||
|
|
||||||
namespace Framework.Constants
|
namespace Framework.Constants
|
||||||
{
|
{
|
||||||
|
public enum ReportType
|
||||||
|
{
|
||||||
|
Chat = 0,
|
||||||
|
InWorld = 1,
|
||||||
|
ClubFinderPosting = 2,
|
||||||
|
ClubFinderApplicant = 3,
|
||||||
|
GroupFinderPosting = 4,
|
||||||
|
GroupFinderApplicant = 5,
|
||||||
|
ClubMember = 6,
|
||||||
|
GroupMember = 7,
|
||||||
|
Friend = 8,
|
||||||
|
Pet = 9,
|
||||||
|
BattlePet = 10,
|
||||||
|
Calendar = 11,
|
||||||
|
Mail = 12,
|
||||||
|
PvP = 13,
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum ReportMajorCategory
|
||||||
|
{
|
||||||
|
InappropriateCommunication = 0,
|
||||||
|
GameplaySabotage = 1,
|
||||||
|
Cheating = 2,
|
||||||
|
InappropriateName = 3,
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum ReportMinorCategory
|
||||||
|
{
|
||||||
|
TextChat = 0x0001,
|
||||||
|
Boosting = 0x0002,
|
||||||
|
Spam = 0x0004,
|
||||||
|
Afk = 0x0008,
|
||||||
|
IntentionallyFeeding = 0x0010,
|
||||||
|
BlockingProgress = 0x0020,
|
||||||
|
Hacking = 0x0040,
|
||||||
|
Botting = 0x0080,
|
||||||
|
Advertisement = 0x0100,
|
||||||
|
BTag = 0x0200,
|
||||||
|
GroupName = 0x0400,
|
||||||
|
CharacterName = 0x0800,
|
||||||
|
GuildName = 0x1000,
|
||||||
|
Description = 0x2000,
|
||||||
|
Name = 0x4000,
|
||||||
|
}
|
||||||
|
|
||||||
public enum GMTicketSystemStatus
|
public enum GMTicketSystemStatus
|
||||||
{
|
{
|
||||||
Disabled = 0,
|
Disabled = 0,
|
||||||
Enabled = 1
|
Enabled = 1
|
||||||
}
|
}
|
||||||
|
|
||||||
public enum GMSupportComplaintType
|
|
||||||
{
|
|
||||||
None = 0,
|
|
||||||
Language = 2,
|
|
||||||
PlayerName = 4,
|
|
||||||
Cheat = 15,
|
|
||||||
GuildName = 23,
|
|
||||||
Spamming = 24
|
|
||||||
}
|
|
||||||
|
|
||||||
public enum SupportSpamType
|
public enum SupportSpamType
|
||||||
{
|
{
|
||||||
Mail = 0,
|
Mail = 0,
|
||||||
|
|||||||
@@ -304,7 +304,7 @@ namespace Framework.Database
|
|||||||
PrepareStatement(CharStatements.INS_GUILD_MEMBER_WITHDRAW_MONEY, "INSERT INTO guild_member_withdraw (guid, money) VALUES (?, ?) ON DUPLICATE KEY UPDATE money = VALUES (money)");
|
PrepareStatement(CharStatements.INS_GUILD_MEMBER_WITHDRAW_MONEY, "INSERT INTO guild_member_withdraw (guid, money) VALUES (?, ?) ON DUPLICATE KEY UPDATE money = VALUES (money)");
|
||||||
PrepareStatement(CharStatements.DEL_GUILD_MEMBER_WITHDRAW, "TRUNCATE guild_member_withdraw");
|
PrepareStatement(CharStatements.DEL_GUILD_MEMBER_WITHDRAW, "TRUNCATE guild_member_withdraw");
|
||||||
|
|
||||||
PrepareStatement(CharStatements.SEL_CHAR_DATA_FOR_GUILD, "SELECT name, level, class, gender, zone, account FROM characters WHERE guid = ?");
|
PrepareStatement(CharStatements.SEL_CHAR_DATA_FOR_GUILD, "SELECT name, level, race, class, gender, zone, account FROM characters WHERE guid = ?");
|
||||||
PrepareStatement(CharStatements.DEL_GUILD_ACHIEVEMENT, "DELETE FROM guild_achievement WHERE guildId = ? AND achievement = ?");
|
PrepareStatement(CharStatements.DEL_GUILD_ACHIEVEMENT, "DELETE FROM guild_achievement WHERE guildId = ? AND achievement = ?");
|
||||||
PrepareStatement(CharStatements.INS_GUILD_ACHIEVEMENT, "INSERT INTO guild_achievement (guildId, achievement, date, guids) VALUES (?, ?, ?, ?)");
|
PrepareStatement(CharStatements.INS_GUILD_ACHIEVEMENT, "INSERT INTO guild_achievement (guildId, achievement, date, guids) VALUES (?, ?, ?, ?)");
|
||||||
PrepareStatement(CharStatements.DEL_GUILD_ACHIEVEMENT_CRITERIA, "DELETE FROM guild_achievement_progress WHERE guildId = ? AND criteria = ?");
|
PrepareStatement(CharStatements.DEL_GUILD_ACHIEVEMENT_CRITERIA, "DELETE FROM guild_achievement_progress WHERE guildId = ? AND criteria = ?");
|
||||||
@@ -439,8 +439,8 @@ namespace Framework.Database
|
|||||||
PrepareStatement(CharStatements.DEL_ALL_GM_BUGS, "TRUNCATE TABLE gm_bug");
|
PrepareStatement(CharStatements.DEL_ALL_GM_BUGS, "TRUNCATE TABLE gm_bug");
|
||||||
|
|
||||||
// GM Complaint
|
// GM Complaint
|
||||||
PrepareStatement(CharStatements.SEL_GM_COMPLAINTS, "SELECT id, playerGuid, note, createTime, mapId, posX, posY, posZ, facing, targetCharacterGuid, complaintType, reportLineIndex, assignedTo, closedBy, comment FROM gm_complaint");
|
PrepareStatement(CharStatements.SEL_GM_COMPLAINTS, "SELECT id, playerGuid, note, createTime, mapId, posX, posY, posZ, facing, targetCharacterGuid, reportType, reportMajorCategory, reportMinorCategoryFlags, reportLineIndex, assignedTo, closedBy, comment FROM gm_complaint");
|
||||||
PrepareStatement(CharStatements.REP_GM_COMPLAINT, "REPLACE INTO gm_complaint (id, playerGuid, note, createTime, mapId, posX, posY, posZ, facing, targetCharacterGuid, complaintType, reportLineIndex, assignedTo, closedBy, comment) VALUES (?, ?, ?, UNIX_TIMESTAMP(NOW()), ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)");
|
PrepareStatement(CharStatements.REP_GM_COMPLAINT, "REPLACE INTO gm_complaint (id, playerGuid, note, createTime, mapId, posX, posY, posZ, facing, targetCharacterGuid, reportType, reportMajorCategory, reportMinorCategoryFlags, reportLineIndex, assignedTo, closedBy, comment) VALUES (?, ?, ?, UNIX_TIMESTAMP(NOW()), ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)");
|
||||||
PrepareStatement(CharStatements.DEL_GM_COMPLAINT, "DELETE FROM gm_complaint WHERE id = ?");
|
PrepareStatement(CharStatements.DEL_GM_COMPLAINT, "DELETE FROM gm_complaint WHERE id = ?");
|
||||||
PrepareStatement(CharStatements.SEL_GM_COMPLAINT_CHATLINES, "SELECT timestamp, text FROM gm_complaint_chatlog WHERE complaintId = ? ORDER BY lineId ASC");
|
PrepareStatement(CharStatements.SEL_GM_COMPLAINT_CHATLINES, "SELECT timestamp, text FROM gm_complaint_chatlog WHERE complaintId = ? ORDER BY lineId ASC");
|
||||||
PrepareStatement(CharStatements.INS_GM_COMPLAINT_CHATLINE, "INSERT INTO gm_complaint_chatlog (complaintId, lineId, timestamp, text) VALUES (?, ?, ?, ?)");
|
PrepareStatement(CharStatements.INS_GM_COMPLAINT_CHATLINE, "INSERT INTO gm_complaint_chatlog (complaintId, lineId, timestamp, text) VALUES (?, ?, ?, ?)");
|
||||||
|
|||||||
@@ -3569,7 +3569,7 @@ namespace Game.Entities
|
|||||||
public UpdateFieldArray<float> WeaponDmgMultipliers = new(3, 585, 586);
|
public UpdateFieldArray<float> WeaponDmgMultipliers = new(3, 585, 586);
|
||||||
public UpdateFieldArray<float> WeaponAtkSpeedMultipliers = new(3, 585, 589);
|
public UpdateFieldArray<float> WeaponAtkSpeedMultipliers = new(3, 585, 589);
|
||||||
public UpdateFieldArray<uint> BuybackPrice = new(12, 592, 593);
|
public UpdateFieldArray<uint> BuybackPrice = new(12, 592, 593);
|
||||||
public UpdateFieldArray<uint> BuybackTimestamp = new(12, 592, 605);
|
public UpdateFieldArray<long> BuybackTimestamp = new(12, 592, 605);
|
||||||
public UpdateFieldArray<uint> CombatRatings = new(32, 617, 618);
|
public UpdateFieldArray<uint> CombatRatings = new(32, 617, 618);
|
||||||
public UpdateFieldArray<PVPInfo> PvpInfo = new(6, 650, 651);
|
public UpdateFieldArray<PVPInfo> PvpInfo = new(6, 650, 651);
|
||||||
public UpdateFieldArray<uint> NoReagentCostMask = new(4, 657, 658);
|
public UpdateFieldArray<uint> NoReagentCostMask = new(4, 657, 658);
|
||||||
@@ -3658,7 +3658,7 @@ namespace Game.Entities
|
|||||||
for (int i = 0; i < 12; ++i)
|
for (int i = 0; i < 12; ++i)
|
||||||
{
|
{
|
||||||
data.WriteUInt32(BuybackPrice[i]);
|
data.WriteUInt32(BuybackPrice[i]);
|
||||||
data.WriteUInt32(BuybackTimestamp[i]);
|
data.WriteInt64(BuybackTimestamp[i]);
|
||||||
}
|
}
|
||||||
data.WriteUInt16(TodayHonorableKills);
|
data.WriteUInt16(TodayHonorableKills);
|
||||||
data.WriteUInt16(YesterdayHonorableKills);
|
data.WriteUInt16(YesterdayHonorableKills);
|
||||||
@@ -4697,7 +4697,7 @@ namespace Game.Entities
|
|||||||
}
|
}
|
||||||
if (changesMask[605 + i])
|
if (changesMask[605 + i])
|
||||||
{
|
{
|
||||||
data.WriteUInt32(BuybackTimestamp[i]);
|
data.WriteInt64(BuybackTimestamp[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3806,10 +3806,8 @@ namespace Game.Entities
|
|||||||
Direction = data.ReadVector3();
|
Direction = data.ReadVector3();
|
||||||
TransportID = data.ReadUInt32();
|
TransportID = data.ReadUInt32();
|
||||||
Magnitude = data.ReadFloat();
|
Magnitude = data.ReadFloat();
|
||||||
|
Unused910 = data.ReadInt32();
|
||||||
Type = (MovementForceType)data.ReadBits<byte>(2);
|
Type = (MovementForceType)data.ReadBits<byte>(2);
|
||||||
bool has910 = data.HasBit();
|
|
||||||
if (has910)
|
|
||||||
Unused910 = data.ReadInt32();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Write(WorldPacket data)
|
public void Write(WorldPacket data)
|
||||||
|
|||||||
@@ -3025,7 +3025,7 @@ namespace Game.Entities
|
|||||||
// if current back slot non-empty search oldest or free
|
// if current back slot non-empty search oldest or free
|
||||||
if (m_items[slot] != null)
|
if (m_items[slot] != null)
|
||||||
{
|
{
|
||||||
uint oldest_time = m_activePlayerData.BuybackTimestamp[0];
|
long oldest_time = m_activePlayerData.BuybackTimestamp[0];
|
||||||
uint oldest_slot = InventorySlots.BuyBackStart;
|
uint oldest_slot = InventorySlots.BuyBackStart;
|
||||||
|
|
||||||
for (byte i = InventorySlots.BuyBackStart + 1; i < InventorySlots.BuyBackEnd; ++i)
|
for (byte i = InventorySlots.BuyBackStart + 1; i < InventorySlots.BuyBackEnd; ++i)
|
||||||
@@ -3037,8 +3037,7 @@ namespace Game.Entities
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint i_time = m_activePlayerData.BuybackTimestamp[i - InventorySlots.BuyBackStart];
|
long i_time = m_activePlayerData.BuybackTimestamp[i - InventorySlots.BuyBackStart];
|
||||||
|
|
||||||
if (oldest_time > i_time)
|
if (oldest_time > i_time)
|
||||||
{
|
{
|
||||||
oldest_time = i_time;
|
oldest_time = i_time;
|
||||||
@@ -3489,7 +3488,7 @@ namespace Game.Entities
|
|||||||
DB.Characters.CommitTransaction(trans);
|
DB.Characters.CommitTransaction(trans);
|
||||||
}
|
}
|
||||||
public void SetBuybackPrice(uint slot, uint price) { SetUpdateFieldValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.BuybackPrice, (int)slot), price); }
|
public void SetBuybackPrice(uint slot, uint price) { SetUpdateFieldValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.BuybackPrice, (int)slot), price); }
|
||||||
public void SetBuybackTimestamp(uint slot, uint timestamp) { SetUpdateFieldValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.BuybackTimestamp, (int)slot), timestamp); }
|
public void SetBuybackTimestamp(uint slot, long timestamp) { SetUpdateFieldValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.BuybackTimestamp, (int)slot), timestamp); }
|
||||||
|
|
||||||
public Item GetItemFromBuyBackSlot(uint slot)
|
public Item GetItemFromBuyBackSlot(uint slot)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -399,6 +399,7 @@ namespace Game.Groups
|
|||||||
MemberSlot member = new();
|
MemberSlot member = new();
|
||||||
member.guid = player.GetGUID();
|
member.guid = player.GetGUID();
|
||||||
member.name = player.GetName();
|
member.name = player.GetName();
|
||||||
|
member.race = player.GetRace();
|
||||||
member._class = (byte)player.GetClass();
|
member._class = (byte)player.GetClass();
|
||||||
member.group = subGroup;
|
member.group = subGroup;
|
||||||
member.flags = 0;
|
member.flags = 0;
|
||||||
@@ -1469,6 +1470,10 @@ namespace Game.Groups
|
|||||||
playerInfos.Name = member.name;
|
playerInfos.Name = member.name;
|
||||||
playerInfos.Class = member._class;
|
playerInfos.Class = member._class;
|
||||||
|
|
||||||
|
ChrRacesRecord race = CliDB.ChrRacesStorage.LookupByKey((uint)member.race);
|
||||||
|
FactionTemplateRecord raceFaction = CliDB.FactionTemplateStorage.LookupByKey(race.FactionID);
|
||||||
|
playerInfos.FactionGroup = raceFaction.FactionGroup;
|
||||||
|
|
||||||
playerInfos.Status = GroupMemberOnlineStatus.Offline;
|
playerInfos.Status = GroupMemberOnlineStatus.Offline;
|
||||||
if (memberPlayer && memberPlayer.GetSession() && !memberPlayer.GetSession().PlayerLogout())
|
if (memberPlayer && memberPlayer.GetSession() && !memberPlayer.GetSession().PlayerLogout())
|
||||||
playerInfos.Status = GroupMemberOnlineStatus.Online | (IsBGGroup() || IsBFGroup() ? GroupMemberOnlineStatus.PVP : 0);
|
playerInfos.Status = GroupMemberOnlineStatus.Online | (IsBGGroup() || IsBFGroup() ? GroupMemberOnlineStatus.PVP : 0);
|
||||||
@@ -2845,6 +2850,7 @@ namespace Game.Groups
|
|||||||
{
|
{
|
||||||
public ObjectGuid guid;
|
public ObjectGuid guid;
|
||||||
public string name;
|
public string name;
|
||||||
|
public Race race;
|
||||||
public byte _class;
|
public byte _class;
|
||||||
public byte group;
|
public byte group;
|
||||||
public GroupMemberFlags flags;
|
public GroupMemberFlags flags;
|
||||||
|
|||||||
+26
-13
@@ -236,6 +236,7 @@ namespace Game.Guilds
|
|||||||
memberData.Level = member.GetLevel();
|
memberData.Level = member.GetLevel();
|
||||||
memberData.ClassID = (byte)member.GetClass();
|
memberData.ClassID = (byte)member.GetClass();
|
||||||
memberData.Gender = (byte)member.GetGender();
|
memberData.Gender = (byte)member.GetGender();
|
||||||
|
memberData.RaceID = (byte)member.GetRace();
|
||||||
|
|
||||||
memberData.Authenticated = false;
|
memberData.Authenticated = false;
|
||||||
memberData.SorEligible = false;
|
memberData.SorEligible = false;
|
||||||
@@ -1650,10 +1651,11 @@ namespace Game.Guilds
|
|||||||
member.SetStats(
|
member.SetStats(
|
||||||
name,
|
name,
|
||||||
result.Read<byte>(1),
|
result.Read<byte>(1),
|
||||||
(Class)result.Read<byte>(2),
|
(Race)result.Read<byte>(2),
|
||||||
(Gender)result.Read<byte>(3),
|
(Class)result.Read<byte>(3),
|
||||||
result.Read<ushort>(4),
|
(Gender)result.Read<byte>(4),
|
||||||
result.Read<uint>(5),
|
result.Read<ushort>(5),
|
||||||
|
result.Read<uint>(6),
|
||||||
0);
|
0);
|
||||||
|
|
||||||
ok = member.CheckStats();
|
ok = member.CheckStats();
|
||||||
@@ -2603,6 +2605,7 @@ namespace Game.Guilds
|
|||||||
{
|
{
|
||||||
m_name = player.GetName();
|
m_name = player.GetName();
|
||||||
m_level = (byte)player.GetLevel();
|
m_level = (byte)player.GetLevel();
|
||||||
|
m_race = player.GetRace();
|
||||||
m_class = player.GetClass();
|
m_class = player.GetClass();
|
||||||
_gender = player.GetNativeGender();
|
_gender = player.GetNativeGender();
|
||||||
m_zoneId = player.GetZoneId();
|
m_zoneId = player.GetZoneId();
|
||||||
@@ -2610,10 +2613,11 @@ namespace Game.Guilds
|
|||||||
m_achievementPoints = player.GetAchievementPoints();
|
m_achievementPoints = player.GetAchievementPoints();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetStats(string name, byte level, Class _class, Gender gender, uint zoneId, uint accountId, uint reputation)
|
public void SetStats(string name, byte level, Race race, Class _class, Gender gender, uint zoneId, uint accountId, uint reputation)
|
||||||
{
|
{
|
||||||
m_name = name;
|
m_name = name;
|
||||||
m_level = level;
|
m_level = level;
|
||||||
|
m_race = race;
|
||||||
m_class = _class;
|
m_class = _class;
|
||||||
_gender = gender;
|
_gender = gender;
|
||||||
m_zoneId = zoneId;
|
m_zoneId = zoneId;
|
||||||
@@ -2685,12 +2689,13 @@ namespace Game.Guilds
|
|||||||
|
|
||||||
SetStats(field.Read<string>(14),
|
SetStats(field.Read<string>(14),
|
||||||
field.Read<byte>(15), // characters.level
|
field.Read<byte>(15), // characters.level
|
||||||
(Class)field.Read<byte>(16), // characters.class
|
(Race)field.Read<byte>(16), // characters.race
|
||||||
(Gender)field.Read<byte>(17), // characters.gender
|
(Class)field.Read<byte>(17), // characters.class
|
||||||
field.Read<ushort>(18), // characters.zone
|
(Gender)field.Read<byte>(18), // characters.gender
|
||||||
field.Read<uint>(19), // characters.account
|
field.Read<ushort>(19), // characters.zone
|
||||||
|
field.Read<uint>(20), // characters.account
|
||||||
0);
|
0);
|
||||||
m_logoutTime = field.Read<ulong>(20); // characters.logout_time
|
m_logoutTime = field.Read<ulong>(21); // characters.logout_time
|
||||||
m_totalActivity = 0;
|
m_totalActivity = 0;
|
||||||
m_weekActivity = 0;
|
m_weekActivity = 0;
|
||||||
m_weekReputation = 0;
|
m_weekReputation = 0;
|
||||||
@@ -2711,13 +2716,19 @@ namespace Game.Guilds
|
|||||||
{
|
{
|
||||||
if (m_level < 1)
|
if (m_level < 1)
|
||||||
{
|
{
|
||||||
Log.outError(LogFilter.Guild, "Player ({0}) has a broken data in field `characters`.`level`, deleting him from guild!", m_guid.ToString());
|
Log.outError(LogFilter.Guild, $"{m_guid} has a broken data in field `characters`.`level`, deleting him from guild!");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_class < Class.Warrior || m_class >= Class.Max)
|
if (!CliDB.ChrRacesStorage.ContainsKey((uint)m_race))
|
||||||
{
|
{
|
||||||
Log.outError(LogFilter.Guild, "Player ({0}) has a broken data in field `characters`.`class`, deleting him from guild!", m_guid.ToString());
|
Log.outError(LogFilter.Guild, $"{m_guid} has a broken data in field `characters`.`race`, deleting him from guild!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!CliDB.ChrClassesStorage.ContainsKey((uint)m_class))
|
||||||
|
{
|
||||||
|
Log.outError(LogFilter.Guild, $"{m_guid} has a broken data in field `characters`.`class`, deleting him from guild!");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
@@ -2790,6 +2801,7 @@ namespace Game.Guilds
|
|||||||
public ulong GetLogoutTime() { return m_logoutTime; }
|
public ulong GetLogoutTime() { return m_logoutTime; }
|
||||||
public string GetPublicNote() { return m_publicNote; }
|
public string GetPublicNote() { return m_publicNote; }
|
||||||
public string GetOfficerNote() { return m_officerNote; }
|
public string GetOfficerNote() { return m_officerNote; }
|
||||||
|
public Race GetRace() { return m_race; }
|
||||||
public Class GetClass() { return m_class; }
|
public Class GetClass() { return m_class; }
|
||||||
public Gender GetGender() { return _gender; }
|
public Gender GetGender() { return _gender; }
|
||||||
public byte GetLevel() { return m_level; }
|
public byte GetLevel() { return m_level; }
|
||||||
@@ -2822,6 +2834,7 @@ namespace Game.Guilds
|
|||||||
string m_name;
|
string m_name;
|
||||||
uint m_zoneId;
|
uint m_zoneId;
|
||||||
byte m_level;
|
byte m_level;
|
||||||
|
Race m_race;
|
||||||
Class m_class;
|
Class m_class;
|
||||||
Gender _gender;
|
Gender _gender;
|
||||||
GuildMemberFlags m_flags;
|
GuildMemberFlags m_flags;
|
||||||
|
|||||||
@@ -177,8 +177,8 @@ namespace Game
|
|||||||
|
|
||||||
// 0 1 2 3 4 5 6 7 8 9 10
|
// 0 1 2 3 4 5 6 7 8 9 10
|
||||||
SQLResult result = DB.Characters.Query("SELECT gm.guildid, gm.guid, rank, pnote, offnote, w.tab0, w.tab1, w.tab2, w.tab3, w.tab4, w.tab5, " +
|
SQLResult result = DB.Characters.Query("SELECT gm.guildid, gm.guid, rank, pnote, offnote, w.tab0, w.tab1, w.tab2, w.tab3, w.tab4, w.tab5, " +
|
||||||
// 11 12 13 14 15 16 17 18 19 20
|
// 11 12 13 14 15 16 17 18 19 20 21
|
||||||
"w.tab6, w.tab7, w.money, c.name, c.level, c.class, c.gender, c.zone, c.account, c.logout_time " +
|
"w.tab6, w.tab7, w.money, c.name, c.level, c.race, c.class, c.gender, c.zone, c.account, c.logout_time " +
|
||||||
"FROM guild_member gm LEFT JOIN guild_member_withdraw w ON gm.guid = w.guid " +
|
"FROM guild_member gm LEFT JOIN guild_member_withdraw w ON gm.guid = w.guid " +
|
||||||
"LEFT JOIN characters c ON c.guid = gm.guid ORDER BY gm.guildid ASC");
|
"LEFT JOIN characters c ON c.guid = gm.guid ORDER BY gm.guildid ASC");
|
||||||
|
|
||||||
|
|||||||
@@ -541,6 +541,33 @@ namespace Game
|
|||||||
SendPacket(response);
|
SendPacket(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[WorldPacketHandler(ClientOpcodes.AuctionRequestFavoriteList)]
|
||||||
|
void HandleAuctionRequestFavoriteList(AuctionRequestFavoriteList requestFavoriteList)
|
||||||
|
{
|
||||||
|
PreparedStatement stmt = DB.Characters.GetPreparedStatement(CharStatements.SEL_CHARACTER_FAVORITE_AUCTIONS);
|
||||||
|
stmt.AddValue(0, _player.GetGUID().GetCounter());
|
||||||
|
GetQueryProcessor().AddCallback(DB.Characters.AsyncQuery(stmt)).WithCallback(favoriteAuctionResult =>
|
||||||
|
{
|
||||||
|
AuctionFavoriteList favoriteItems = new();
|
||||||
|
if (!favoriteAuctionResult.IsEmpty())
|
||||||
|
{
|
||||||
|
do
|
||||||
|
{
|
||||||
|
AuctionFavoriteInfo item = new();
|
||||||
|
item.Order = favoriteAuctionResult.Read<uint>(0);
|
||||||
|
item.ItemID = favoriteAuctionResult.Read<uint>(1);
|
||||||
|
item.ItemLevel = favoriteAuctionResult.Read<uint>(2);
|
||||||
|
item.BattlePetSpeciesID = favoriteAuctionResult.Read<uint>(3);
|
||||||
|
item.SuffixItemNameDescriptionID = favoriteAuctionResult.Read<uint>(4);
|
||||||
|
favoriteItems.Items.Add(item);
|
||||||
|
|
||||||
|
} while (favoriteAuctionResult.NextRow());
|
||||||
|
|
||||||
|
}
|
||||||
|
SendPacket(favoriteItems);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
[WorldPacketHandler(ClientOpcodes.AuctionSellCommodity)]
|
[WorldPacketHandler(ClientOpcodes.AuctionSellCommodity)]
|
||||||
void HandleAuctionSellCommodity(AuctionSellCommodity sellCommodity)
|
void HandleAuctionSellCommodity(AuctionSellCommodity sellCommodity)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -880,29 +880,6 @@ namespace Game
|
|||||||
// Place character in world (and load zone) before some object loading
|
// Place character in world (and load zone) before some object loading
|
||||||
pCurrChar.LoadCorpse(holder.GetResult(PlayerLoginQueryLoad.CorpseLocation));
|
pCurrChar.LoadCorpse(holder.GetResult(PlayerLoginQueryLoad.CorpseLocation));
|
||||||
|
|
||||||
stmt = DB.Characters.GetPreparedStatement(CharStatements.SEL_CHARACTER_FAVORITE_AUCTIONS);
|
|
||||||
stmt.AddValue(0, pCurrChar.GetGUID().GetCounter());
|
|
||||||
GetQueryProcessor().AddCallback(DB.Characters.AsyncQuery(stmt)).WithCallback(favoriteAuctionResult =>
|
|
||||||
{
|
|
||||||
AuctionFavoriteList favoriteItems = new();
|
|
||||||
if (!favoriteAuctionResult.IsEmpty())
|
|
||||||
{
|
|
||||||
do
|
|
||||||
{
|
|
||||||
AuctionFavoriteInfo item = new();
|
|
||||||
item.Order = favoriteAuctionResult.Read<uint>(0);
|
|
||||||
item.ItemID = favoriteAuctionResult.Read<uint>(1);
|
|
||||||
item.ItemLevel = favoriteAuctionResult.Read<uint>(2);
|
|
||||||
item.BattlePetSpeciesID = favoriteAuctionResult.Read<uint>(3);
|
|
||||||
item.SuffixItemNameDescriptionID = favoriteAuctionResult.Read<uint>(4);
|
|
||||||
favoriteItems.Items.Add(item);
|
|
||||||
|
|
||||||
} while (favoriteAuctionResult.NextRow());
|
|
||||||
|
|
||||||
}
|
|
||||||
SendPacket(favoriteItems);
|
|
||||||
});
|
|
||||||
|
|
||||||
// setting Ghost+speed if dead
|
// setting Ghost+speed if dead
|
||||||
if (pCurrChar.GetDeathState() == DeathState.Dead)
|
if (pCurrChar.GetDeathState() == DeathState.Dead)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -364,5 +364,13 @@ namespace Game
|
|||||||
Log.outDebug(LogFilter.Network, "WorldSession.HandleSetContactNotesOpcode: Contact: {0}, Notes: {1}", packet.Player.Guid.ToString(), packet.Notes);
|
Log.outDebug(LogFilter.Network, "WorldSession.HandleSetContactNotesOpcode: Contact: {0}, Notes: {1}", packet.Player.Guid.ToString(), packet.Notes);
|
||||||
GetPlayer().GetSocial().SetFriendNote(packet.Player.Guid, packet.Notes);
|
GetPlayer().GetSocial().SetFriendNote(packet.Player.Guid, packet.Notes);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[WorldPacketHandler(ClientOpcodes.SocialContractRequest)]
|
||||||
|
void HandleSocialContractRequest(SocialContractRequest socialContractRequest)
|
||||||
|
{
|
||||||
|
SocialContractRequestResponse response = new();
|
||||||
|
response.ShowSocialContract = false;
|
||||||
|
SendPacket(response);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -83,7 +83,9 @@ namespace Game
|
|||||||
comp.SetFacing(packet.Header.Facing);
|
comp.SetFacing(packet.Header.Facing);
|
||||||
comp.SetChatLog(packet.ChatLog);
|
comp.SetChatLog(packet.ChatLog);
|
||||||
comp.SetTargetCharacterGuid(packet.TargetCharacterGUID);
|
comp.SetTargetCharacterGuid(packet.TargetCharacterGUID);
|
||||||
comp.SetComplaintType((GMSupportComplaintType)packet.ComplaintType);
|
comp.SetReportType((ReportType)packet.ReportType);
|
||||||
|
comp.SetMajorCategory((ReportMajorCategory)packet.MajorCategory);
|
||||||
|
comp.SetMinorCategoryFlags((ReportMinorCategory)packet.MinorCategoryFlags);
|
||||||
comp.SetNote(packet.Note);
|
comp.SetNote(packet.Note);
|
||||||
|
|
||||||
Global.SupportMgr.AddTicket(comp);
|
Global.SupportMgr.AddTicket(comp);
|
||||||
|
|||||||
@@ -347,6 +347,13 @@ namespace Game.Networking.Packets
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class AuctionRequestFavoriteList : ClientPacket
|
||||||
|
{
|
||||||
|
public AuctionRequestFavoriteList(WorldPacket packet) : base(packet) { }
|
||||||
|
|
||||||
|
public override void Read() { }
|
||||||
|
}
|
||||||
|
|
||||||
class AuctionSellCommodity : ClientPacket
|
class AuctionSellCommodity : ClientPacket
|
||||||
{
|
{
|
||||||
public ObjectGuid Auctioneer;
|
public ObjectGuid Auctioneer;
|
||||||
|
|||||||
@@ -400,34 +400,29 @@ namespace Game.Networking.Packets
|
|||||||
public string CustomName = "";
|
public string CustomName = "";
|
||||||
}
|
}
|
||||||
|
|
||||||
class GarrisonMission
|
class GarrisonEncounter
|
||||||
{
|
{
|
||||||
|
public int GarrEncounterID;
|
||||||
|
public List<int> Mechanics = new();
|
||||||
|
public int GarrAutoCombatantID;
|
||||||
|
public int Health;
|
||||||
|
public int MaxHealth;
|
||||||
|
public int Attack;
|
||||||
|
public sbyte BoardIndex;
|
||||||
|
|
||||||
public void Write(WorldPacket data)
|
public void Write(WorldPacket data)
|
||||||
{
|
{
|
||||||
data.WriteUInt64(DbID);
|
data.WriteInt32(GarrEncounterID);
|
||||||
data.WriteInt64(OfferTime);
|
data.WriteInt32(Mechanics.Count);
|
||||||
data.WriteUInt32(OfferDuration);
|
data.WriteInt32(GarrAutoCombatantID);
|
||||||
data.WriteInt64(StartTime);
|
data.WriteInt32(Health);
|
||||||
data.WriteUInt32(TravelDuration);
|
data.WriteInt32(MaxHealth);
|
||||||
data.WriteUInt32(MissionDuration);
|
data.WriteInt32(Attack);
|
||||||
data.WriteUInt32(MissionRecID);
|
data.WriteInt8(BoardIndex);
|
||||||
data.WriteUInt32(MissionState);
|
|
||||||
data.WriteUInt32(SuccessChance);
|
|
||||||
data.WriteUInt32(Flags);
|
|
||||||
data.WriteFloat(MissionScalar);
|
|
||||||
}
|
|
||||||
|
|
||||||
public ulong DbID;
|
if (!Mechanics.Empty())
|
||||||
public uint MissionRecID;
|
Mechanics.ForEach(id => data.WriteInt32(id));
|
||||||
public long OfferTime;
|
}
|
||||||
public uint OfferDuration;
|
|
||||||
public long StartTime = 2288912640;
|
|
||||||
public uint TravelDuration;
|
|
||||||
public uint MissionDuration;
|
|
||||||
public uint MissionState;
|
|
||||||
public uint SuccessChance;
|
|
||||||
public uint Flags;
|
|
||||||
public float MissionScalar = 1.0f;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
struct GarrisonMissionReward
|
struct GarrisonMissionReward
|
||||||
@@ -458,6 +453,53 @@ namespace Game.Networking.Packets
|
|||||||
public ItemInstance ItemInstance;
|
public ItemInstance ItemInstance;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class GarrisonMission
|
||||||
|
{
|
||||||
|
public ulong DbID;
|
||||||
|
public int MissionRecID;
|
||||||
|
public long OfferTime;
|
||||||
|
public uint OfferDuration;
|
||||||
|
public long StartTime = 2288912640;
|
||||||
|
public uint TravelDuration;
|
||||||
|
public uint MissionDuration;
|
||||||
|
public int MissionState = 0;
|
||||||
|
public int SuccessChance = 0;
|
||||||
|
public uint Flags = 0;
|
||||||
|
public float MissionScalar = 1.0f;
|
||||||
|
public int ContentTuningID = 0;
|
||||||
|
public List<GarrisonEncounter> Encounters = new();
|
||||||
|
public List<GarrisonMissionReward> Rewards = new();
|
||||||
|
public List<GarrisonMissionReward> OvermaxRewards = new();
|
||||||
|
|
||||||
|
public void Write(WorldPacket data)
|
||||||
|
{
|
||||||
|
data.WriteUInt64(DbID);
|
||||||
|
data.WriteInt32(MissionRecID);
|
||||||
|
data.WriteInt64(OfferTime);
|
||||||
|
data.WriteUInt32(OfferDuration);
|
||||||
|
data.WriteInt64(StartTime);
|
||||||
|
data.WriteUInt32(TravelDuration);
|
||||||
|
data.WriteUInt32(MissionDuration);
|
||||||
|
data.WriteInt32(MissionState);
|
||||||
|
data.WriteInt32(SuccessChance);
|
||||||
|
data.WriteUInt32(Flags);
|
||||||
|
data.WriteFloat(MissionScalar);
|
||||||
|
data.WriteInt32(ContentTuningID);
|
||||||
|
data.WriteInt32(Encounters.Count);
|
||||||
|
data.WriteInt32(Rewards.Count);
|
||||||
|
data.WriteInt32(OvermaxRewards.Count);
|
||||||
|
|
||||||
|
foreach (GarrisonEncounter encounter in Encounters)
|
||||||
|
encounter.Write(data);
|
||||||
|
|
||||||
|
foreach (GarrisonMissionReward missionRewardItem in Rewards)
|
||||||
|
missionRewardItem.Write(data);
|
||||||
|
|
||||||
|
foreach (GarrisonMissionReward missionRewardItem in OvermaxRewards)
|
||||||
|
missionRewardItem.Write(data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
struct GarrisonMissionBonusAbility
|
struct GarrisonMissionBonusAbility
|
||||||
{
|
{
|
||||||
public void Write(WorldPacket data)
|
public void Write(WorldPacket data)
|
||||||
|
|||||||
@@ -1638,6 +1638,8 @@ namespace Game.Networking.Packets
|
|||||||
data.WriteUInt8(Level);
|
data.WriteUInt8(Level);
|
||||||
data.WriteUInt8(ClassID);
|
data.WriteUInt8(ClassID);
|
||||||
data.WriteUInt8(Gender);
|
data.WriteUInt8(Gender);
|
||||||
|
data.WriteUInt64(GuildClubMemberID);
|
||||||
|
data.WriteUInt8(RaceID);
|
||||||
|
|
||||||
data.WriteBits(Name.GetByteCount(), 6);
|
data.WriteBits(Name.GetByteCount(), 6);
|
||||||
data.WriteBits(Note.GetByteCount(), 8);
|
data.WriteBits(Note.GetByteCount(), 8);
|
||||||
@@ -1670,6 +1672,8 @@ namespace Game.Networking.Packets
|
|||||||
public byte Level;
|
public byte Level;
|
||||||
public byte ClassID;
|
public byte ClassID;
|
||||||
public byte Gender;
|
public byte Gender;
|
||||||
|
public ulong GuildClubMemberID;
|
||||||
|
public byte RaceID;
|
||||||
public bool Authenticated;
|
public bool Authenticated;
|
||||||
public bool SorEligible;
|
public bool SorEligible;
|
||||||
public GuildRosterProfessionData[] Profession = new GuildRosterProfessionData[2];
|
public GuildRosterProfessionData[] Profession = new GuildRosterProfessionData[2];
|
||||||
|
|||||||
@@ -762,6 +762,8 @@ namespace Game.Networking.Packets
|
|||||||
Id = data.ReadUInt32();
|
Id = data.ReadUInt32();
|
||||||
Type = (RideType)data.ReadUInt32();
|
Type = (RideType)data.ReadUInt32();
|
||||||
Time = data.ReadInt64();
|
Time = data.ReadInt64();
|
||||||
|
Unknown925 = data.HasBit();
|
||||||
|
data.ResetBitPos();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Write(WorldPacket data)
|
public void Write(WorldPacket data)
|
||||||
@@ -770,12 +772,15 @@ namespace Game.Networking.Packets
|
|||||||
data.WriteUInt32(Id);
|
data.WriteUInt32(Id);
|
||||||
data.WriteUInt32((uint)Type);
|
data.WriteUInt32((uint)Type);
|
||||||
data.WriteInt64(Time);
|
data.WriteInt64(Time);
|
||||||
|
data.WriteBit(Unknown925);
|
||||||
|
data.FlushBits();
|
||||||
}
|
}
|
||||||
|
|
||||||
public ObjectGuid RequesterGuid;
|
public ObjectGuid RequesterGuid;
|
||||||
public uint Id;
|
public uint Id;
|
||||||
public RideType Type;
|
public RideType Type;
|
||||||
public long Time;
|
public long Time;
|
||||||
|
public bool Unknown925;
|
||||||
}
|
}
|
||||||
|
|
||||||
public enum RideType
|
public enum RideType
|
||||||
|
|||||||
@@ -342,12 +342,9 @@ namespace Game.Networking.Packets
|
|||||||
|
|
||||||
data.WriteUInt32(movementForce.TransportID);
|
data.WriteUInt32(movementForce.TransportID);
|
||||||
data.WriteFloat(movementForce.Magnitude);
|
data.WriteFloat(movementForce.Magnitude);
|
||||||
|
data.WriteInt32(movementForce.Unused910);
|
||||||
data.WriteBits((byte)movementForce.Type, 2);
|
data.WriteBits((byte)movementForce.Type, 2);
|
||||||
data.WriteBit(movementForce.Unused910 != 0);
|
|
||||||
data.FlushBits();
|
data.FlushBits();
|
||||||
|
|
||||||
if (movementForce.Unused910 != 0)
|
|
||||||
data.WriteInt32(movementForce.Unused910);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1084,6 +1084,7 @@ namespace Game.Networking.Packets
|
|||||||
data.WriteUInt8(Flags);
|
data.WriteUInt8(Flags);
|
||||||
data.WriteUInt8(RolesAssigned);
|
data.WriteUInt8(RolesAssigned);
|
||||||
data.WriteUInt8(Class);
|
data.WriteUInt8(Class);
|
||||||
|
data.WriteUInt8(FactionGroup);
|
||||||
data.WriteString(Name);
|
data.WriteString(Name);
|
||||||
if (!VoiceStateID.IsEmpty())
|
if (!VoiceStateID.IsEmpty())
|
||||||
data.WriteString(VoiceStateID);
|
data.WriteString(VoiceStateID);
|
||||||
@@ -1097,6 +1098,7 @@ namespace Game.Networking.Packets
|
|||||||
public byte Subgroup;
|
public byte Subgroup;
|
||||||
public byte Flags;
|
public byte Flags;
|
||||||
public byte RolesAssigned;
|
public byte RolesAssigned;
|
||||||
|
public byte FactionGroup;
|
||||||
public bool FromSocialQueue;
|
public bool FromSocialQueue;
|
||||||
public bool VoiceChatSilenced;
|
public bool VoiceChatSilenced;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -169,6 +169,26 @@ namespace Game.Networking.Packets
|
|||||||
public QualifiedGUID Player;
|
public QualifiedGUID Player;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class SocialContractRequest : ClientPacket
|
||||||
|
{
|
||||||
|
public SocialContractRequest(WorldPacket packet) : base(packet) { }
|
||||||
|
|
||||||
|
public override void Read() { }
|
||||||
|
}
|
||||||
|
|
||||||
|
class SocialContractRequestResponse : ServerPacket
|
||||||
|
{
|
||||||
|
public bool ShowSocialContract;
|
||||||
|
|
||||||
|
public SocialContractRequestResponse() : base(ServerOpcodes.SocialContractRequestResponse) { }
|
||||||
|
|
||||||
|
public override void Write()
|
||||||
|
{
|
||||||
|
_worldPacket.WriteBit(ShowSocialContract);
|
||||||
|
_worldPacket.FlushBits();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//Structs
|
//Structs
|
||||||
public class ContactInfo
|
public class ContactInfo
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -129,8 +129,10 @@ namespace Game.Networking.Packets
|
|||||||
{
|
{
|
||||||
Header.Read(_worldPacket);
|
Header.Read(_worldPacket);
|
||||||
TargetCharacterGUID = _worldPacket.ReadPackedGuid();
|
TargetCharacterGUID = _worldPacket.ReadPackedGuid();
|
||||||
|
ReportType = _worldPacket.ReadInt32();
|
||||||
|
MajorCategory = _worldPacket.ReadInt32();
|
||||||
|
MinorCategoryFlags = _worldPacket.ReadInt32();
|
||||||
ChatLog.Read(_worldPacket);
|
ChatLog.Read(_worldPacket);
|
||||||
ComplaintType = _worldPacket.ReadBits<byte>(5);
|
|
||||||
|
|
||||||
uint noteLength = _worldPacket.ReadBits<uint>(10);
|
uint noteLength = _worldPacket.ReadBits<uint>(10);
|
||||||
bool hasMailInfo = _worldPacket.HasBit();
|
bool hasMailInfo = _worldPacket.HasBit();
|
||||||
@@ -209,7 +211,9 @@ namespace Game.Networking.Packets
|
|||||||
public SupportTicketHeader Header;
|
public SupportTicketHeader Header;
|
||||||
public SupportTicketChatLog ChatLog;
|
public SupportTicketChatLog ChatLog;
|
||||||
public ObjectGuid TargetCharacterGUID;
|
public ObjectGuid TargetCharacterGUID;
|
||||||
public byte ComplaintType;
|
public int ReportType;
|
||||||
|
public int MajorCategory;
|
||||||
|
public int MinorCategoryFlags;
|
||||||
public string Note;
|
public string Note;
|
||||||
public SupportTicketHorusChatLog HorusChatLog;
|
public SupportTicketHorusChatLog HorusChatLog;
|
||||||
public SupportTicketMailInfo? MailInfo;
|
public SupportTicketMailInfo? MailInfo;
|
||||||
@@ -578,10 +582,12 @@ namespace Game.Networking.Packets
|
|||||||
MapID = packet.ReadUInt32();
|
MapID = packet.ReadUInt32();
|
||||||
Position = packet.ReadVector3();
|
Position = packet.ReadVector3();
|
||||||
Facing = packet.ReadFloat();
|
Facing = packet.ReadFloat();
|
||||||
|
Program = packet.ReadInt32();
|
||||||
}
|
}
|
||||||
|
|
||||||
public uint MapID;
|
public uint MapID;
|
||||||
public Vector3 Position;
|
public Vector3 Position;
|
||||||
public float Facing;
|
public float Facing;
|
||||||
|
public int Program;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -213,7 +213,9 @@ namespace Game.SupportSystem
|
|||||||
{
|
{
|
||||||
float _facing;
|
float _facing;
|
||||||
ObjectGuid _targetCharacterGuid;
|
ObjectGuid _targetCharacterGuid;
|
||||||
GMSupportComplaintType _complaintType;
|
ReportType _reportType;
|
||||||
|
ReportMajorCategory _majorCategory;
|
||||||
|
ReportMinorCategory _minorCategoryFlags = ReportMinorCategory.TextChat;
|
||||||
SupportTicketSubmitComplaint.SupportTicketChatLog _chatLog;
|
SupportTicketSubmitComplaint.SupportTicketChatLog _chatLog;
|
||||||
string _note;
|
string _note;
|
||||||
|
|
||||||
@@ -239,7 +241,9 @@ namespace Game.SupportSystem
|
|||||||
_pos = new Vector3(fields.Read<float>(++idx), fields.Read<float>(++idx), fields.Read<float>(++idx));
|
_pos = new Vector3(fields.Read<float>(++idx), fields.Read<float>(++idx), fields.Read<float>(++idx));
|
||||||
_facing = fields.Read<float>(++idx);
|
_facing = fields.Read<float>(++idx);
|
||||||
_targetCharacterGuid = ObjectGuid.Create(HighGuid.Player, fields.Read<ulong>(++idx));
|
_targetCharacterGuid = ObjectGuid.Create(HighGuid.Player, fields.Read<ulong>(++idx));
|
||||||
_complaintType = (GMSupportComplaintType)fields.Read<byte>(++idx);
|
_reportType = (ReportType)fields.Read<int>(++idx);
|
||||||
|
_majorCategory = (ReportMajorCategory)fields.Read<int>(++idx);
|
||||||
|
_minorCategoryFlags = (ReportMinorCategory)fields.Read<int>(++idx);
|
||||||
int reportLineIndex = fields.Read<int>(++idx);
|
int reportLineIndex = fields.Read<int>(++idx);
|
||||||
if (reportLineIndex != -1)
|
if (reportLineIndex != -1)
|
||||||
_chatLog.ReportLineIndex = (uint)reportLineIndex;
|
_chatLog.ReportLineIndex = (uint)reportLineIndex;
|
||||||
@@ -282,7 +286,9 @@ namespace Game.SupportSystem
|
|||||||
stmt.AddValue(++idx, _pos.Z);
|
stmt.AddValue(++idx, _pos.Z);
|
||||||
stmt.AddValue(++idx, _facing);
|
stmt.AddValue(++idx, _facing);
|
||||||
stmt.AddValue(++idx, _targetCharacterGuid.GetCounter());
|
stmt.AddValue(++idx, _targetCharacterGuid.GetCounter());
|
||||||
stmt.AddValue(++idx, (byte)_complaintType);
|
stmt.AddValue(++idx, (int)_reportType);
|
||||||
|
stmt.AddValue(++idx, (int)_majorCategory);
|
||||||
|
stmt.AddValue(++idx, (int)_minorCategoryFlags);
|
||||||
if (_chatLog.ReportLineIndex.HasValue)
|
if (_chatLog.ReportLineIndex.HasValue)
|
||||||
stmt.AddValue(++idx, _chatLog.ReportLineIndex.Value);
|
stmt.AddValue(++idx, _chatLog.ReportLineIndex.Value);
|
||||||
else
|
else
|
||||||
@@ -342,7 +348,9 @@ namespace Game.SupportSystem
|
|||||||
}
|
}
|
||||||
|
|
||||||
ObjectGuid GetTargetCharacterGuid() { return _targetCharacterGuid; }
|
ObjectGuid GetTargetCharacterGuid() { return _targetCharacterGuid; }
|
||||||
GMSupportComplaintType GetComplaintType() { return _complaintType; }
|
ReportType GetReportType() { return _reportType; }
|
||||||
|
ReportMajorCategory GetMajorCategory() { return _majorCategory; }
|
||||||
|
ReportMinorCategory GetMinorCategoryFlags() { return _minorCategoryFlags; }
|
||||||
string GetNote() { return _note; }
|
string GetNote() { return _note; }
|
||||||
|
|
||||||
public void SetFacing(float facing) { _facing = facing; }
|
public void SetFacing(float facing) { _facing = facing; }
|
||||||
@@ -350,7 +358,9 @@ namespace Game.SupportSystem
|
|||||||
{
|
{
|
||||||
_targetCharacterGuid = targetCharacterGuid;
|
_targetCharacterGuid = targetCharacterGuid;
|
||||||
}
|
}
|
||||||
public void SetComplaintType(GMSupportComplaintType type) { _complaintType = type; }
|
public void SetReportType(ReportType reportType) { _reportType = reportType; }
|
||||||
|
public void SetMajorCategory(ReportMajorCategory majorCategory) { _majorCategory = majorCategory; }
|
||||||
|
public void SetMinorCategoryFlags(ReportMinorCategory minorCategoryFlags) { _minorCategoryFlags = minorCategoryFlags; }
|
||||||
public void SetChatLog(SupportTicketSubmitComplaint.SupportTicketChatLog log) { _chatLog = log; }
|
public void SetChatLog(SupportTicketSubmitComplaint.SupportTicketChatLog log) { _chatLog = log; }
|
||||||
public void SetNote(string note) { _note = note; }
|
public void SetNote(string note) { _note = note; }
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2063,7 +2063,9 @@ CREATE TABLE `gm_complaint` (
|
|||||||
`posZ` float NOT NULL DEFAULT '0',
|
`posZ` float NOT NULL DEFAULT '0',
|
||||||
`facing` float NOT NULL DEFAULT '0',
|
`facing` float NOT NULL DEFAULT '0',
|
||||||
`targetCharacterGuid` bigint unsigned NOT NULL,
|
`targetCharacterGuid` bigint unsigned NOT NULL,
|
||||||
`complaintType` smallint unsigned NOT NULL,
|
`reportType` int NOT NULL DEFAULT '0',
|
||||||
|
`reportMajorCategory` int NOT NULL DEFAULT '0',
|
||||||
|
`reportMinorCategoryFlags` int NOT NULL DEFAULT '0',
|
||||||
`reportLineIndex` int NOT NULL,
|
`reportLineIndex` int NOT NULL,
|
||||||
`closedBy` bigint NOT NULL DEFAULT '0',
|
`closedBy` bigint NOT NULL DEFAULT '0',
|
||||||
`assignedTo` bigint unsigned NOT NULL DEFAULT '0' COMMENT 'GUID of admin to whom ticket is assigned',
|
`assignedTo` bigint unsigned NOT NULL DEFAULT '0' COMMENT 'GUID of admin to whom ticket is assigned',
|
||||||
@@ -3667,7 +3669,8 @@ INSERT INTO `updates` VALUES
|
|||||||
('2022_01_31_02_characters.sql','6E3A3F02276287DD540BC4C17E246DFB850260D8','ARCHIVED','2022-01-31 21:43:38',0),
|
('2022_01_31_02_characters.sql','6E3A3F02276287DD540BC4C17E246DFB850260D8','ARCHIVED','2022-01-31 21:43:38',0),
|
||||||
('2022_02_28_00_characters_2020_09_27_00_characters.sql','2292A1ED0E7F46DEC41384F75FA6D9461464EEB8','ARCHIVED','2022-02-28 12:43:58',0),
|
('2022_02_28_00_characters_2020_09_27_00_characters.sql','2292A1ED0E7F46DEC41384F75FA6D9461464EEB8','ARCHIVED','2022-02-28 12:43:58',0),
|
||||||
('2022_03_06_00_characters.sql','474AAF9D03E6A56017899C968DC9875368301934','ARCHIVED','2022-03-06 15:12:24',0),
|
('2022_03_06_00_characters.sql','474AAF9D03E6A56017899C968DC9875368301934','ARCHIVED','2022-03-06 15:12:24',0),
|
||||||
('2022_03_11_00_characters_2021_07_18_00_characters.sql','0BA579ED21F4E75AC2B4797421B5029568B3F6E2','RELEASED','2022-03-11 18:56:07',0);
|
('2022_03_11_00_characters_2021_07_18_00_characters.sql','0BA579ED21F4E75AC2B4797421B5029568B3F6E2','RELEASED','2022-03-11 18:56:07',0),
|
||||||
|
('2022_06_01_00_characters.sql','582AC6E256F8365F83AB70BA165CCC8B218E19FF','RELEASED','2022-06-01 21:16:56',0);
|
||||||
/*!40000 ALTER TABLE `updates` ENABLE KEYS */;
|
/*!40000 ALTER TABLE `updates` ENABLE KEYS */;
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,12 @@
|
|||||||
|
ALTER TABLE `gm_complaint`
|
||||||
|
ADD `reportType` int NOT NULL DEFAULT '0' AFTER `complaintType`,
|
||||||
|
ADD `reportMajorCategory` int NOT NULL DEFAULT '0' AFTER `reportType`,
|
||||||
|
ADD `reportMinorCategoryFlags` int NOT NULL DEFAULT '0' AFTER `reportMajorCategory`;
|
||||||
|
|
||||||
|
UPDATE `gm_complaint` SET `reportType`=0,`reportMajorCategory`=0,`reportMinorCategoryFlags`=0x1 WHERE `complaintType`=2;
|
||||||
|
UPDATE `gm_complaint` SET `reportType`=1,`reportMajorCategory`=3,`reportMinorCategoryFlags`=0x800 WHERE `complaintType`=4;
|
||||||
|
UPDATE `gm_complaint` SET `reportType`=1,`reportMajorCategory`=2,`reportMinorCategoryFlags`=0x40 WHERE `complaintType`=15;
|
||||||
|
UPDATE `gm_complaint` SET `reportType`=1,`reportMajorCategory`=3,`reportMinorCategoryFlags`=0x1000 WHERE `complaintType`=23;
|
||||||
|
UPDATE `gm_complaint` SET `reportType`=0,`reportMajorCategory`=0,`reportMinorCategoryFlags`=0x4 WHERE `complaintType`=24;
|
||||||
|
|
||||||
|
ALTER TABLE `gm_complaint` DROP `complaintType`;
|
||||||
Reference in New Issue
Block a user