diff --git a/Source/Framework/Constants/Network/Opcodes.cs b/Source/Framework/Constants/Network/Opcodes.cs index 8dc307c83..ab4ecd5e7 100644 --- a/Source/Framework/Constants/Network/Opcodes.cs +++ b/Source/Framework/Constants/Network/Opcodes.cs @@ -217,6 +217,7 @@ namespace Framework.Constants ConnectToFailed = 0x35d4, ContributionContribute = 0x3558, ContributionGetState = 0x3559, + ConversationLineStarted = 0x354A, ConvertConsumptionTime = 0x36f9, ConvertRaid = 0x364e, CreateCharacter = 0x3643, diff --git a/Source/Game/DataStorage/ConversationDataStorage.cs b/Source/Game/DataStorage/ConversationDataStorage.cs index 38ad0379a..d122046ae 100644 --- a/Source/Game/DataStorage/ConversationDataStorage.cs +++ b/Source/Game/DataStorage/ConversationDataStorage.cs @@ -60,7 +60,7 @@ namespace Game.DataStorage Log.outInfo(LogFilter.ServerLoading, "Loaded 0 Conversation actor templates. DB table `conversation_actor_template` is empty."); } - SQLResult lineTemplates = DB.World.Query("SELECT Id, StartTime, UiCameraID, ActorIdx, Unk FROM conversation_line_template"); + SQLResult lineTemplates = DB.World.Query("SELECT Id, StartTime, UiCameraID, ActorIdx, Flags FROM conversation_line_template"); if (!lineTemplates.IsEmpty()) { uint oldMSTime = Time.GetMSTime(); @@ -79,8 +79,8 @@ namespace Game.DataStorage conversationLine.Id = id; conversationLine.StartTime = lineTemplates.Read(1); conversationLine.UiCameraID = lineTemplates.Read(2); - conversationLine.ActorIdx = lineTemplates.Read(3); - conversationLine.Unk = lineTemplates.Read(4); + conversationLine.ActorIdx = lineTemplates.Read(3); + conversationLine.Flags = lineTemplates.Read(4); _conversationLineTemplateStorage[id] = conversationLine; } @@ -226,8 +226,9 @@ namespace Game.DataStorage public uint Id; // Link to ConversationLine.db2 public uint StartTime; // Time in ms after conversation creation the line is displayed public uint UiCameraID; // Link to UiCamera.db2 - public ushort ActorIdx; // Index from conversation_actors - public ushort Unk; + public byte ActorIdx; // Index from conversation_actors + public byte Flags; + public ushort Padding; } public class ConversationTemplate diff --git a/sql/updates/world/master/2018_08_24_00_world.sql b/sql/updates/world/master/2018_08_24_00_world.sql new file mode 100644 index 000000000..9805a86fa --- /dev/null +++ b/sql/updates/world/master/2018_08_24_00_world.sql @@ -0,0 +1,6 @@ +ALTER TABLE `conversation_line_template` ADD `Flags` tinyint(3) unsigned NOT NULL DEFAULT '0' AFTER `ActorIdx`; +UPDATE `conversation_line_template` SET `Flags`=(`ActorIdx`>>8); +UPDATE `conversation_line_template` SET `ActorIdx`=`ActorIdx`&0xFF; +ALTER TABLE `conversation_line_template` + CHANGE `ActorIdx` `ActorIdx` tinyint(3) unsigned NOT NULL DEFAULT '0' AFTER `UiCameraID`, + DROP `Unk`;