diff --git a/EpinelPS/GameData/GameData.cs b/EpinelPS/GameData/GameData.cs index ef52d8b..c6d75fd 100644 --- a/EpinelPS/GameData/GameData.cs +++ b/EpinelPS/GameData/GameData.cs @@ -66,6 +66,7 @@ namespace EpinelPS.StaticInfo public readonly Dictionary mediasProductTable = []; public readonly Dictionary towerTable = []; public readonly Dictionary TriggerTable = []; + public readonly Dictionary InfracoreTable = []; public byte[] Sha256Hash; @@ -507,6 +508,12 @@ namespace EpinelPS.StaticInfo { this.TriggerTable.Add(obj.id, obj); } + + var infracoreTable = await LoadZip("InfraCoreGradeTable.json", progress); + foreach (var obj in infracoreTable.records) + { + this.InfracoreTable.Add(obj.id, obj); + } } public MainQuestCompletionRecord? GetMainQuestForStageClearCondition(int stage) diff --git a/EpinelPS/GameData/JsonStaticData.cs b/EpinelPS/GameData/JsonStaticData.cs index 70ae09b..688d8fc 100644 --- a/EpinelPS/GameData/JsonStaticData.cs +++ b/EpinelPS/GameData/JsonStaticData.cs @@ -673,4 +673,20 @@ { public List records = []; } + public class InfracoreFunction + { + public int function; + } + public class InfracoreRecord + { + public int id; + public int grade; + public int reard_id; + public int infra_core_exp; + public List function_list = []; + } + public class InfracoreTable + { + public List records = []; + } } diff --git a/EpinelPS/LobbyServer/Mission/ObtainAchievement.cs b/EpinelPS/LobbyServer/Mission/ObtainAchievement.cs index a5ca168..09b51fe 100644 --- a/EpinelPS/LobbyServer/Mission/ObtainAchievement.cs +++ b/EpinelPS/LobbyServer/Mission/ObtainAchievement.cs @@ -1,3 +1,4 @@ +using EpinelPS.Database; using EpinelPS.StaticInfo; using EpinelPS.Utils; @@ -30,6 +31,8 @@ namespace EpinelPS.LobbyServer.Mission response.Reward = NetUtils.MergeRewards(rewards, user); + JsonDb.Save(); + await WriteDataAsync(response); } }