From ab98da42c3f3638bced4aab24886343244e32b24 Mon Sep 17 00:00:00 2001 From: Slendy Date: Tue, 20 Jun 2023 02:16:48 -0500 Subject: [PATCH] Fix LBP2 recently played for story levels --- .../Controllers/Slots/SlotsController.cs | 2 +- ProjectLighthouse/Types/Serialization/GameDeveloperSlot.cs | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/ProjectLighthouse.Servers.GameServer/Controllers/Slots/SlotsController.cs b/ProjectLighthouse.Servers.GameServer/Controllers/Slots/SlotsController.cs index 1607dbee..519c6742 100644 --- a/ProjectLighthouse.Servers.GameServer/Controllers/Slots/SlotsController.cs +++ b/ProjectLighthouse.Servers.GameServer/Controllers/Slots/SlotsController.cs @@ -73,7 +73,7 @@ public class SlotsController : ControllerBase { slots.Add(new GameDeveloperSlot { - SlotId = slotId, + InternalSlotId = slotId, }); continue; } diff --git a/ProjectLighthouse/Types/Serialization/GameDeveloperSlot.cs b/ProjectLighthouse/Types/Serialization/GameDeveloperSlot.cs index be59f663..ae0aaed0 100644 --- a/ProjectLighthouse/Types/Serialization/GameDeveloperSlot.cs +++ b/ProjectLighthouse/Types/Serialization/GameDeveloperSlot.cs @@ -32,6 +32,8 @@ public class GameDeveloperSlot : SlotBase, INeedsPreparationForSerialization public async Task PrepareSerialization(DatabaseContext database) { + if (this.SlotId == 0 || this.InternalSlotId == 0) return; + var stats = await database.Slots.Where(s => s.SlotId == this.SlotId) .Select(_ => new {