From bd4bff4a551618ffa563ebf1cf851214b27a52ee Mon Sep 17 00:00:00 2001 From: milimoe Date: Wed, 25 Dec 2024 01:41:38 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E8=A7=92=E8=89=B2=E7=BB=83?= =?UTF-8?q?=E7=BA=A7=E3=80=81=E6=8A=80=E8=83=BD=E5=8D=87=E7=BA=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- OshimaCore/Controllers/FunGameController.cs | 403 +++++++++++++++++++- OshimaCore/Utils/FunGameService.cs | 215 ++++++++++- OshimaModules/Items/ItemID.cs | 3 + OshimaModules/Items/SpecialItem/奥术符文.cs | 13 + OshimaModules/Items/SpecialItem/技能卷轴.cs | 13 + OshimaModules/Items/SpecialItem/智慧之果.cs | 13 + OshimaModules/Modules/ItemModule.cs | 3 + 7 files changed, 650 insertions(+), 13 deletions(-) create mode 100644 OshimaModules/Items/SpecialItem/奥术符文.cs create mode 100644 OshimaModules/Items/SpecialItem/技能卷轴.cs create mode 100644 OshimaModules/Items/SpecialItem/智慧之果.cs diff --git a/OshimaCore/Controllers/FunGameController.cs b/OshimaCore/Controllers/FunGameController.cs index 84273f0..c3bd6d3 100644 --- a/OshimaCore/Controllers/FunGameController.cs +++ b/OshimaCore/Controllers/FunGameController.cs @@ -8,6 +8,7 @@ using Oshima.Core.Configs; using Oshima.Core.Models; using Oshima.Core.Utils; using Oshima.FunGame.OshimaModules.Characters; +using Oshima.FunGame.OshimaModules.Items; namespace Oshima.Core.Controllers { @@ -1346,18 +1347,7 @@ namespace Oshima.Core.Controllers if (user1 != null && user2 != null) { - Character? character1 = user1.Inventory.Characters.FirstOrDefault(c => c.Id == user1.Id); - if (character1 is null) - { - return [$"ƺûԽɫ뷢͡Խɫ"]; - } - Character? character2 = user2.Inventory.Characters.FirstOrDefault(c => c.Id == user2.Id); - if (character2 is null) - { - return [$"ԷƺûԽɫ뷢͡Խɫ"]; - } - - return FunGameActionQueue.StartGame([character1, character2], false, false, false, false, false, showAllRound); + return FunGameActionQueue.StartGame([user1.Inventory.MainCharacter, user2.Inventory.MainCharacter], false, false, false, false, false, showAllRound); } else { @@ -2239,6 +2229,395 @@ namespace Oshima.Core.Controllers } } + [HttpPost("setmain")] + public string SetMain([FromQuery] long? qq = null, [FromQuery] int? c = null) + { + try + { + long userid = qq ?? Convert.ToInt64("10" + Verification.CreateVerifyCode(VerifyCodeType.NumberVerifyCode, 11)); + int characterIndex = c ?? 0; + + PluginConfig pc = new("saved", userid.ToString()); + pc.LoadConfig(); + + if (pc.Count > 0) + { + User user = FunGameService.GetUser(pc); + + Character? character = null; + if (characterIndex > 0 && characterIndex <= user.Inventory.Characters.Count) + { + character = user.Inventory.Characters.ToList()[characterIndex - 1]; + } + else + { + return NetworkUtility.JsonSerialize($"ûҵӦĽɫ"); + } + + user.Inventory.MainCharacter = character; + user.LastTime = DateTime.Now; + pc.Add("user", user); + pc.SaveConfig(); + return NetworkUtility.JsonSerialize($"սɫɹ{character}"); + } + else + { + return NetworkUtility.JsonSerialize(noSaved); + } + } + catch (Exception e) + { + return NetworkUtility.JsonSerialize(e.ToString()); + } + } + + [HttpPost("starttraining")] + public string StartTraining([FromQuery] long? qq = null, [FromQuery] int? c = null) + { + try + { + long userid = qq ?? Convert.ToInt64("10" + Verification.CreateVerifyCode(VerifyCodeType.NumberVerifyCode, 11)); + int characterIndex = c ?? 0; + + PluginConfig pc = new("saved", userid.ToString()); + pc.LoadConfig(); + + if (pc.Count > 0) + { + User user = FunGameService.GetUser(pc); + + Character? character = null; + if (characterIndex > 0 && characterIndex <= user.Inventory.Characters.Count) + { + character = user.Inventory.Characters.ToList()[characterIndex - 1]; + } + else + { + return NetworkUtility.JsonSerialize($"ûҵӦĽɫ"); + } + + if (user.Inventory.Training.Count > 0) + { + return NetworkUtility.JsonSerialize($"ѾнɫУʹá㡿ָȡ{user.Inventory.Training.First()}"); + } + + user.Inventory.Training[character.Id] = DateTime.Now; + user.LastTime = DateTime.Now; + pc.Add("user", user); + pc.SaveConfig(); + return NetworkUtility.JsonSerialize($"ɫ [{character}] ʼһʱС㡿ʱԽԽʢʱ 1440 ӣ24Сʱʱκ棬뼰ʱȡ"); + } + else + { + return NetworkUtility.JsonSerialize(noSaved); + } + } + catch (Exception e) + { + return NetworkUtility.JsonSerialize(e.ToString()); + } + } + + [HttpPost("stoptraining")] + public string StopTraining([FromQuery] long? qq = null) + { + try + { + long userid = qq ?? Convert.ToInt64("10" + Verification.CreateVerifyCode(VerifyCodeType.NumberVerifyCode, 11)); + + PluginConfig pc = new("saved", userid.ToString()); + pc.LoadConfig(); + + if (pc.Count > 0) + { + User user = FunGameService.GetUser(pc); + + if (user.Inventory.Training.Count == 0) + { + return NetworkUtility.JsonSerialize($"ĿǰûнɫУʹá+ɫšָ"); + } + + long cid = user.Inventory.Training.Keys.First(); + DateTime time = user.Inventory.Training[cid]; + DateTime now = DateTime.Now; + Character? character = user.Inventory.Characters.FirstOrDefault(c => c.Id == cid); + if (character != null) + { + user.Inventory.Training.Remove(cid); + + TimeSpan diff = now - time; + string msg = FunGameService.GetTrainingInfo(diff, false, out int totalExperience, out int smallBookCount, out int mediumBookCount, out int largeBookCount); + + if (totalExperience > 0) + { + character.EXP += totalExperience; + } + + for (int i = 0; i < smallBookCount; i++) + { + Item item = new С(user); + user.Inventory.Items.Add(item); + } + + for (int i = 0; i < mediumBookCount; i++) + { + Item item = new о(user); + user.Inventory.Items.Add(item); + } + + for (int i = 0; i < largeBookCount; i++) + { + Item item = new (user); + user.Inventory.Items.Add(item); + } + + user.LastTime = DateTime.Now; + pc.Add("user", user); + pc.SaveConfig(); + return NetworkUtility.JsonSerialize($"ɫ [ {character} ] {msg}"); + } + else + { + return NetworkUtility.JsonSerialize($"ĿǰûнɫУҲǿϢȡ쳣Ժԡ"); + } + } + else + { + return NetworkUtility.JsonSerialize(noSaved); + } + } + catch (Exception e) + { + return NetworkUtility.JsonSerialize(e.ToString()); + } + } + + [HttpPost("gettraininginfo")] + public string GetTrainingInfo([FromQuery] long? qq = null) + { + try + { + long userid = qq ?? Convert.ToInt64("10" + Verification.CreateVerifyCode(VerifyCodeType.NumberVerifyCode, 11)); + + PluginConfig pc = new("saved", userid.ToString()); + pc.LoadConfig(); + + if (pc.Count > 0) + { + User user = FunGameService.GetUser(pc); + + if (user.Inventory.Training.Count == 0) + { + return NetworkUtility.JsonSerialize($"ĿǰûнɫУʹá+ɫšָ"); + } + + long cid = user.Inventory.Training.Keys.First(); + DateTime time = user.Inventory.Training[cid]; + DateTime now = DateTime.Now; + Character? character = user.Inventory.Characters.FirstOrDefault(c => c.Id == cid); + if (character != null) + { + TimeSpan diff = now - time; + string msg = FunGameService.GetTrainingInfo(diff, true, out int totalExperience, out int smallBookCount, out int mediumBookCount, out int largeBookCount); + + return NetworkUtility.JsonSerialize($"ɫ [ {character} ] У{msg}\r\nȷ롾㡿ȡ"); + } + else + { + return NetworkUtility.JsonSerialize($"ĿǰûнɫУҲǿϢȡ쳣Ժԡ"); + } + } + else + { + return NetworkUtility.JsonSerialize(noSaved); + } + } + catch (Exception e) + { + return NetworkUtility.JsonSerialize(e.ToString()); + } + } + + [HttpPost("getskilllevelupneedy")] + public string GetSkillLevelUpNeedy([FromQuery] long? qq = null, [FromQuery] int? c = null, [FromQuery] string? s = null) + { + long userid = qq ?? Convert.ToInt64("10" + Verification.CreateVerifyCode(VerifyCodeType.NumberVerifyCode, 11)); + int characterIndex = c ?? 0; + string skillName = s ?? ""; + + PluginConfig pc = new("saved", userid.ToString()); + pc.LoadConfig(); + + if (pc.Count > 0) + { + User user = FunGameService.GetUser(pc); + Character? character; + if (characterIndex > 0 && characterIndex <= user.Inventory.Characters.Count) + { + character = user.Inventory.Characters.ToList()[characterIndex - 1]; + } + else + { + return NetworkUtility.JsonSerialize($"ûҵӦĽɫ"); + } + + if (character.Skills.FirstOrDefault(s => s.Name == skillName) is Skill skill) + { + if (skill.SkillType == SkillType.Skill || skill.SkillType == SkillType.SuperSkill) + { + if (skill.Level + 1 == General.GameplayEquilibriumConstant.MaxSkillLevel) + { + return NetworkUtility.JsonSerialize($"˼ܡ{skill.Name}Ѿ"); + } + + return NetworkUtility.JsonSerialize($"ɫ [ {character} ] ġ{skill.Name}ܵȼ{skill.Level}/{General.GameplayEquilibriumConstant.MaxSkillLevel}" + + $"\r\nһϣ\r\n" + FunGameService.GetSkillLevelUpNeedy(skill.Level + 1)); + } + return NetworkUtility.JsonSerialize($"˼޷"); + } + else + { + return NetworkUtility.JsonSerialize($"˽ɫûС{skillName}ܣ"); + } + } + else + { + return NetworkUtility.JsonSerialize(noSaved); + } + } + + [HttpPost("skilllevelup")] + public string SkillLevelUp([FromQuery] long? qq = null, [FromQuery] int? c = null, [FromQuery] string? s = null) + { + try + { + long userid = qq ?? Convert.ToInt64("10" + Verification.CreateVerifyCode(VerifyCodeType.NumberVerifyCode, 11)); + int characterIndex = c ?? 0; + string skillName = s ?? ""; + + PluginConfig pc = new("saved", userid.ToString()); + pc.LoadConfig(); + + if (pc.Count > 0) + { + User user = FunGameService.GetUser(pc); + + Character? character = null; + if (characterIndex > 0 && characterIndex <= user.Inventory.Characters.Count) + { + character = user.Inventory.Characters.ToList()[characterIndex - 1]; + } + else + { + return NetworkUtility.JsonSerialize($"ûҵӦĽɫ"); + } + + if (character.Skills.FirstOrDefault(s => s.Name == skillName) is Skill skill) + { + string isStudy = skill.Level == 0 ? "ѧϰ" : ""; + + if (skill.SkillType == SkillType.Skill || skill.SkillType == SkillType.SuperSkill) + { + if (skill.Level == General.GameplayEquilibriumConstant.MaxSkillLevel) + { + return NetworkUtility.JsonSerialize($"˼ܡ{skill.Name}Ѿ"); + } + + if (FunGameService.SkillLevelUpList.TryGetValue(skill.Level + 1, out Dictionary? needy) && needy != null && needy.Count > 0) + { + foreach (string key in needy.Keys) + { + int needCount = needy[key]; + if (key == "ɫȼ") + { + if (character.Level < needCount) + { + return NetworkUtility.JsonSerialize($"ɫ [ {character} ] ȼ {needCount} ޷{isStudy}˼ܣ"); + } + } + else if (key == General.GameplayEquilibriumConstant.InGameCurrency) + { + if (user.Inventory.Credits >= needCount) + { + user.Inventory.Credits -= needCount; + } + else + { + return NetworkUtility.JsonSerialize($"{General.GameplayEquilibriumConstant.InGameCurrency} {needCount} أ{isStudy}"); + } + } + else if (key == General.GameplayEquilibriumConstant.InGameMaterial) + { + if (user.Inventory.Materials >= needCount) + { + user.Inventory.Materials -= needCount; + } + else + { + return NetworkUtility.JsonSerialize($"{General.GameplayEquilibriumConstant.InGameMaterial} {needCount} أ{isStudy}"); + } + } + else + { + if (needCount > 0) + { + IEnumerable items = user.Inventory.Items.Where(i => i.Name == key); + if (items.Count() >= needCount) + { + items = items.TakeLast(needCount); + foreach (Item item in items) + { + user.Inventory.Items.Remove(item); + } + } + else + { + return NetworkUtility.JsonSerialize($"Ʒ{key} {needCount} أ{isStudy}"); + } + } + } + } + + skill.Level += 1; + + user.LastTime = DateTime.Now; + pc.Add("user", user); + pc.SaveConfig(); + string msg = $"{isStudy}ܳɹģ{string.Join("", needy.Select(kv => kv.Key + " * " + kv.Value))}ɹ{skill.Name} {skill.Level} "; + + if (skill.Level == General.GameplayEquilibriumConstant.MaxSkillLevel) + { + msg += $"\r\n˼Ѿϲ"; + } + else + { + msg += $"\r\nһϣ\r\n" + FunGameService.GetSkillLevelUpNeedy(skill.Level + 1); + } + + return NetworkUtility.JsonSerialize(msg); + } + + return NetworkUtility.JsonSerialize($"{isStudy}ʧܣɫ [ {character} ] ġ{skill.Name}ܵǰȼ{skill.Level}/{General.GameplayEquilibriumConstant.MaxSkillLevel}" + + $"\r\nһϣ\r\n" + FunGameService.GetSkillLevelUpNeedy(skill.Level + 1)); + } + return NetworkUtility.JsonSerialize($"˼޷{isStudy}"); + } + else + { + return NetworkUtility.JsonSerialize($"˽ɫûС{skillName}ܣ"); + } + } + else + { + return NetworkUtility.JsonSerialize(noSaved); + } + } + catch (Exception e) + { + return NetworkUtility.JsonSerialize(e.ToString()); + } + } + [HttpGet("reload")] public string Relaod([FromQuery] long? master = null) { diff --git a/OshimaCore/Utils/FunGameService.cs b/OshimaCore/Utils/FunGameService.cs index 579618e..ad4bee4 100644 --- a/OshimaCore/Utils/FunGameService.cs +++ b/OshimaCore/Utils/FunGameService.cs @@ -78,6 +78,144 @@ namespace Oshima.Core.Utils }; } } + public static Dictionary> SuperSkillLevelUpList + { + get + { + return new() + { + { + 1, new() + { + { "角色等级", 1 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 2000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 10 }, + { nameof(技能卷轴), 1 }, + } + }, + { + 2, new() + { + { "角色等级", 12 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 5000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 30 }, + { nameof(技能卷轴), 2 }, + } + }, + { + 3, new() + { + { "角色等级", 24 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 10000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 60 }, + { nameof(技能卷轴), 3 }, + { nameof(智慧之果), 1 }, + } + }, + { + 4, new() + { + { "角色等级", 36 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 18000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 100 }, + { nameof(技能卷轴), 4 }, + { nameof(智慧之果), 2 }, + } + }, + { + 5, new() + { + { "角色等级", 48 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 30000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 150 }, + { nameof(技能卷轴), 5 }, + { nameof(智慧之果), 3 }, + { nameof(奥术符文), 1 } + } + }, + { + 6, new() + { + { "角色等级", 60 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 47000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 210 }, + { nameof(技能卷轴), 6 }, + { nameof(智慧之果), 4 }, + { nameof(奥术符文), 2 } + } + } + }; + } + } + public static Dictionary> SkillLevelUpList + { + get + { + return new() + { + { + 1, new() + { + { "角色等级", 6 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 2000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 10 }, + { nameof(技能卷轴), 1 }, + } + }, + { + 2, new() + { + { "角色等级", 12 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 5000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 30 }, + { nameof(技能卷轴), 2 }, + } + }, + { + 3, new() + { + { "角色等级", 24 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 10000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 60 }, + { nameof(技能卷轴), 3 }, + { nameof(智慧之果), 1 }, + } + }, + { + 4, new() + { + { "角色等级", 36 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 18000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 100 }, + { nameof(技能卷轴), 4 }, + { nameof(智慧之果), 2 }, + } + }, + { + 5, new() + { + { "角色等级", 48 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 30000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 150 }, + { nameof(技能卷轴), 5 }, + { nameof(智慧之果), 3 }, + { nameof(奥术符文), 1 } + } + }, + { + 6, new() + { + { "角色等级", 60 }, + { General.GameplayEquilibriumConstant.InGameCurrency, 47000 }, + { General.GameplayEquilibriumConstant.InGameMaterial, 210 }, + { nameof(技能卷轴), 6 }, + { nameof(智慧之果), 4 }, + { nameof(奥术符文), 2 } + } + } + }; + } + } public static void InitFunGame() { @@ -104,7 +242,7 @@ namespace Oshima.Core.Utils Equipment.AddRange([new 攻击之爪5(), new 攻击之爪15(), new 攻击之爪25(), new 攻击之爪35()]); Items.AddRange(exItems.Values.Where(i => (int)i.ItemType > 4)); - Items.AddRange([new 小经验书(), new 中经验书(), new 大经验书(), new 升华之印(), new 流光之印(), new 永恒之印()]); + Items.AddRange([new 小经验书(), new 中经验书(), new 大经验书(), new 升华之印(), new 流光之印(), new 永恒之印(), new 技能卷轴(), new 智慧之果(), new 奥术符文()]); AllItems.AddRange(Equipment); AllItems.AddRange(Items); @@ -503,8 +641,13 @@ namespace Oshima.Core.Utils List characters = new(user.Inventory.Characters); List items = new(user.Inventory.Items); + Character mc = user.Inventory.MainCharacter; + List squad = [.. user.Inventory.Squad.Select(kv => kv.Id)]; + Dictionary training = user.Inventory.Training.ToDictionary(kv => kv.Key, kv => kv.Value); user.Inventory.Characters.Clear(); user.Inventory.Items.Clear(); + user.Inventory.Squad.Clear(); + user.Inventory.Training.Clear(); foreach (Item inventoryItem in items) { @@ -520,6 +663,27 @@ namespace Oshima.Core.Utils user.Inventory.Characters.Add(realCharacter); } + if (user.Inventory.Characters.FirstOrDefault(c => c.Id == mc.Id) is Character newMC) + { + user.Inventory.MainCharacter = newMC; + } + + foreach (long id in squad) + { + if (user.Inventory.Characters.FirstOrDefault(c => c.Id == id) is Character s) + { + user.Inventory.Squad.Add(s); + } + } + + foreach (long cid in training.Keys) + { + if (user.Inventory.Characters.FirstOrDefault(c => c.Id == cid) is Character t) + { + user.Inventory.Training[t.Id] = training[cid]; + } + } + return user; } @@ -952,5 +1116,54 @@ namespace Oshima.Core.Utils return "此魔法卡不存在任何魔法!"; } } + + public static string GetTrainingInfo(TimeSpan diff, bool isPre, out int totalExperience, out int smallBookCount, out int mediumBookCount, out int largeBookCount) + { + int totalMinutes = (int)diff.TotalMinutes; + + // 每分钟经验 + int experiencePerMinute = 1; + + // 最大练级时间 + int dailyTrainingMinutes = 1440; + + // 计算总经验奖励 + totalExperience = Math.Min(totalMinutes, dailyTrainingMinutes) * experiencePerMinute; + + // 计算经验书奖励 + smallBookCount = 0; + mediumBookCount = 0; + largeBookCount = 0; + + // 计算总训练小时数 + int trainingHours = totalMinutes / 60; + + if (trainingHours >= 8) + { + smallBookCount = Math.Min(1, trainingHours); + } + + if (trainingHours >= 16) + { + mediumBookCount = Math.Min(1, (trainingHours - 16) / 1); + } + + if (trainingHours >= 24) + { + largeBookCount = Math.Min(1, (trainingHours - 24) / 1); + } + + return $"练级时长:{totalMinutes} 分钟,{(isPre ? "预计可" : "")}获得:{totalExperience} 点经验值,{smallBookCount} 本小经验书,{mediumBookCount} 本中经验书,{largeBookCount} 本大经验书。" + + $"{(isPre ? "练级时间上限 1440 分钟(24小时),超时将不会再产生收益,请按时领取奖励!" : "")}"; + } + + public static string GetSkillLevelUpNeedy(int level) + { + if (SkillLevelUpList.TryGetValue(level, out Dictionary? needy) && needy != null && needy.Count > 0) + { + return string.Join(",", needy.Select(kv => kv.Key + " * " + kv.Value)); + } + return ""; + } } } diff --git a/OshimaModules/Items/ItemID.cs b/OshimaModules/Items/ItemID.cs index 530d60b..ff8cee3 100644 --- a/OshimaModules/Items/ItemID.cs +++ b/OshimaModules/Items/ItemID.cs @@ -20,5 +20,8 @@ 升华之印 = 18001, 流光之印 = 18002, 永恒之印 = 18003, + 技能卷轴 = 18004, + 智慧之果 = 18005, + 奥术符文 = 18006, } } diff --git a/OshimaModules/Items/SpecialItem/奥术符文.cs b/OshimaModules/Items/SpecialItem/奥术符文.cs new file mode 100644 index 0000000..573b264 --- /dev/null +++ b/OshimaModules/Items/SpecialItem/奥术符文.cs @@ -0,0 +1,13 @@ +using Milimoe.FunGame.Core.Entity; +using Milimoe.FunGame.Core.Library.Constant; + +namespace Oshima.FunGame.OshimaModules.Items +{ + public class 奥术符文() : Item(ItemType.SpecialItem) + { + public override long Id => (long)SpecialItemID.奥术符文; + public override string Name => "奥术符文"; + public override string Description => "升级技能必备的高级材料。"; + public override QualityType QualityType => QualityType.Blue; + } +} diff --git a/OshimaModules/Items/SpecialItem/技能卷轴.cs b/OshimaModules/Items/SpecialItem/技能卷轴.cs new file mode 100644 index 0000000..03f8554 --- /dev/null +++ b/OshimaModules/Items/SpecialItem/技能卷轴.cs @@ -0,0 +1,13 @@ +using Milimoe.FunGame.Core.Entity; +using Milimoe.FunGame.Core.Library.Constant; + +namespace Oshima.FunGame.OshimaModules.Items +{ + public class 技能卷轴() : Item(ItemType.SpecialItem) + { + public override long Id => (long)SpecialItemID.技能卷轴; + public override string Name => "技能卷轴"; + public override string Description => "升级技能必备的初级材料。"; + public override QualityType QualityType => QualityType.White; + } +} diff --git a/OshimaModules/Items/SpecialItem/智慧之果.cs b/OshimaModules/Items/SpecialItem/智慧之果.cs new file mode 100644 index 0000000..59cfc31 --- /dev/null +++ b/OshimaModules/Items/SpecialItem/智慧之果.cs @@ -0,0 +1,13 @@ +using Milimoe.FunGame.Core.Entity; +using Milimoe.FunGame.Core.Library.Constant; + +namespace Oshima.FunGame.OshimaModules.Items +{ + public class 智慧之果() : Item(ItemType.SpecialItem) + { + public override long Id => (long)SpecialItemID.智慧之果; + public override string Name => "智慧之果"; + public override string Description => "升级技能必备的中级材料。"; + public override QualityType QualityType => QualityType.Green; + } +} diff --git a/OshimaModules/Modules/ItemModule.cs b/OshimaModules/Modules/ItemModule.cs index 2e699f8..ffc27da 100644 --- a/OshimaModules/Modules/ItemModule.cs +++ b/OshimaModules/Modules/ItemModule.cs @@ -35,6 +35,9 @@ namespace Oshima.FunGame.OshimaModules (long)SpecialItemID.升华之印 => new 升华之印(), (long)SpecialItemID.流光之印 => new 流光之印(), (long)SpecialItemID.永恒之印 => new 永恒之印(), + (long)SpecialItemID.技能卷轴 => new 技能卷轴(), + (long)SpecialItemID.智慧之果 => new 智慧之果(), + (long)SpecialItemID.奥术符文 => new 奥术符文(), _ => null, }; };