Fix presentation of messages with items (rewards & insurance returns) (#265)

This commit is contained in:
hulkhan22
2025-05-21 23:29:34 +02:00
committed by GitHub
parent e941213e0e
commit aef3a4202f
14 changed files with 50 additions and 50 deletions
@@ -147,7 +147,7 @@ public class DialogueController(
var result = new DialogueInfo
{
Id = dialogueId,
Type = dialogue?.Type ?? MessageType.NPC_TRADER,
Type = dialogue?.Type ?? MessageType.NpcTraderMessage,
Message = _dialogueHelper.GetMessagePreview(dialogue),
New = dialogue?.New,
AttachmentsNew = dialogue?.AttachmentsNew,
@@ -173,7 +173,7 @@ public class DialogueController(
var profile = _saveServer.GetProfile(sessionId);
// User to user messages are special in that they need the player to exist in them, add if they don't
if (messageType == MessageType.USER_MESSAGE &&
if (messageType == MessageType.UserMessage &&
dialog?.Users is not null &&
dialog.Users.All(userDialog => userDialog.Id != profile.CharacterData?.PmcData?.SessionId))
{
@@ -253,7 +253,7 @@ public class DialogueController(
Type = request.Type
};
if (request.Type != MessageType.USER_MESSAGE)
if (request.Type != MessageType.UserMessage)
{
return profile.DialogueRecords[request.DialogId!];
}