数值调整;测试任务计划

This commit is contained in:
milimoe 2024-12-12 01:50:38 +08:00
parent 85186ac819
commit 1cd8ebd551
Signed by: milimoe
GPG Key ID: 05D280912DA6C69E
8 changed files with 56 additions and 57 deletions

View File

@ -116,7 +116,7 @@ namespace Oshima.Core.WebAPI
} }
} }
}); });
Task taskCache = Task.Factory.StartNew(async () => Milimoe.FunGame.Core.Api.Utility.TaskScheduler.Shared.AddRecurringTask("刷新存档缓存", TimeSpan.FromSeconds(20), () =>
{ {
string directoryPath = $@"{AppDomain.CurrentDomain.BaseDirectory}configs/saved"; string directoryPath = $@"{AppDomain.CurrentDomain.BaseDirectory}configs/saved";
if (Directory.Exists(directoryPath)) if (Directory.Exists(directoryPath))
@ -135,8 +135,7 @@ namespace Oshima.Core.WebAPI
} }
Controller.WriteLine("读取 FunGame 存档缓存"); Controller.WriteLine("读取 FunGame 存档缓存");
} }
await Task.Delay(3000 * 60 * 10); }, true);
});
} }
} }
} }

View File

@ -36,7 +36,7 @@ namespace Oshima.Core.Utils
Dictionary<string, Item> exItems = Factory.GetGameModuleInstances<Item>(OshimaGameModuleConstant.General, OshimaGameModuleConstant.Item); Dictionary<string, Item> exItems = Factory.GetGameModuleInstances<Item>(OshimaGameModuleConstant.General, OshimaGameModuleConstant.Item);
Equipment.AddRange(exItems.Values.Where(i => (int)i.ItemType >= 0 && (int)i.ItemType < 5)); Equipment.AddRange(exItems.Values.Where(i => (int)i.ItemType >= 0 && (int)i.ItemType < 5));
Equipment.AddRange([new 10(), new 20(), new 35(), new 50()]); Equipment.AddRange([new 5(), new 15(), new 25(), new 35()]);
Items.AddRange(exItems.Values.Where(i => (int)i.ItemType > 4)); Items.AddRange(exItems.Values.Where(i => (int)i.ItemType > 4));
@ -428,14 +428,14 @@ namespace Oshima.Core.Utils
foreach (Character inventoryCharacter in characters) foreach (Character inventoryCharacter in characters)
{ {
Character realCharacter = CharacterBuilder.Build(inventoryCharacter, false); Character realCharacter = CharacterBuilder.Build(inventoryCharacter, false, Items, Skills);
realCharacter.User = user; realCharacter.User = user;
user.Inventory.Characters.Add(realCharacter); user.Inventory.Characters.Add(realCharacter);
} }
foreach (Item inventoryItem in items) foreach (Item inventoryItem in items)
{ {
Item realItem = inventoryItem.Copy(true, true); Item realItem = inventoryItem.Copy(true, true, true, Items, Skills);
if (realItem.IsEquipment) if (realItem.IsEquipment)
{ {
IEnumerable<Character> has = user.Inventory.Characters.Where(character => IEnumerable<Character> has = user.Inventory.Characters.Where(character =>

View File

@ -5,29 +5,42 @@ using Oshima.FunGame.OshimaModules.Skills;
namespace Oshima.FunGame.OshimaModules.Items namespace Oshima.FunGame.OshimaModules.Items
{ {
public class 10 : Item public class 5 : Item
{ {
public override long Id => (long)AccessoryID.10; public override long Id => (long)AccessoryID.5;
public override string Name => "攻击之爪 +10"; public override string Name => "攻击之爪 +5";
public override string Description => Skills.Passives.Count > 0 ? Skills.Passives.First().Description : ""; public override string Description => Skills.Passives.Count > 0 ? Skills.Passives.First().Description : "";
public override QualityType QualityType => QualityType.White; public override QualityType QualityType => QualityType.White;
public 10(Character? character = null) : base(ItemType.Accessory) public 5(Character? character = null) : base(ItemType.Accessory)
{ {
Skills.Passives.Add(new (character, this, 10)); Skills.Passives.Add(new (character, this, 5));
} }
} }
public class 20 : Item public class 15 : Item
{ {
public override long Id => (long)AccessoryID.20; public override long Id => (long)AccessoryID.15;
public override string Name => "攻击之爪 +20"; public override string Name => "攻击之爪 +15";
public override string Description => Skills.Passives.Count > 0 ? Skills.Passives.First().Description : ""; public override string Description => Skills.Passives.Count > 0 ? Skills.Passives.First().Description : "";
public override QualityType QualityType => QualityType.Green; public override QualityType QualityType => QualityType.Green;
public 20(Character? character = null) : base(ItemType.Accessory) public 15(Character? character = null) : base(ItemType.Accessory)
{ {
Skills.Passives.Add(new (character, this, 20)); Skills.Passives.Add(new (character, this, 15));
}
}
public class 25 : Item
{
public override long Id => (long)AccessoryID.25;
public override string Name => "攻击之爪 +25";
public override string Description => Skills.Passives.Count > 0 ? Skills.Passives.First().Description : "";
public override QualityType QualityType => QualityType.Blue;
public 25(Character? character = null) : base(ItemType.Accessory)
{
Skills.Passives.Add(new (character, this, 25));
} }
} }
@ -36,26 +49,13 @@ namespace Oshima.FunGame.OshimaModules.Items
public override long Id => (long)AccessoryID.35; public override long Id => (long)AccessoryID.35;
public override string Name => "攻击之爪 +35"; public override string Name => "攻击之爪 +35";
public override string Description => Skills.Passives.Count > 0 ? Skills.Passives.First().Description : ""; public override string Description => Skills.Passives.Count > 0 ? Skills.Passives.First().Description : "";
public override QualityType QualityType => QualityType.Blue; public override QualityType QualityType => QualityType.Purple;
public 35(Character? character = null) : base(ItemType.Accessory) public 35(Character? character = null) : base(ItemType.Accessory)
{ {
Skills.Passives.Add(new (character, this, 35)); Skills.Passives.Add(new (character, this, 35));
} }
} }
public class 50 : Item
{
public override long Id => (long)AccessoryID.50;
public override string Name => "攻击之爪 +50";
public override string Description => Skills.Passives.Count > 0 ? Skills.Passives.First().Description : "";
public override QualityType QualityType => QualityType.Purple;
public 50(Character? character = null) : base(ItemType.Accessory)
{
Skills.Passives.Add(new (character, this, 50));
}
}
public class : Skill public class : Skill
{ {

View File

@ -2,9 +2,9 @@
{ {
public enum AccessoryID : long public enum AccessoryID : long
{ {
10 = 14001, 5 = 14001,
20 = 14002, 15 = 14002,
35 = 14003, 25 = 14003,
50 = 14004, 35 = 14004,
} }
} }

View File

@ -25,10 +25,10 @@ namespace Oshima.FunGame.OshimaModules
{ {
return id switch return id switch
{ {
(long)AccessoryID.10 => new 10(), (long)AccessoryID.5 => new 5(),
(long)AccessoryID.20 => new 20(), (long)AccessoryID.15 => new 15(),
(long)AccessoryID.25 => new 25(),
(long)AccessoryID.35 => new 35(), (long)AccessoryID.35 => new 35(),
(long)AccessoryID.50 => new 50(),
_ => null, _ => null,
}; };
}; };

View File

@ -16,7 +16,7 @@ namespace Oshima.FunGame.OshimaModules.Skills
public (Character? character = null) : base(SkillType.Magic, character) public (Character? character = null) : base(SkillType.Magic, character)
{ {
Effects.Add(new _无基础伤害(this, 1.4, 0.28, true)); Effects.Add(new _无基础伤害(this, 1.3, 0.28, true));
} }
} }
} }

View File

@ -16,8 +16,8 @@ namespace Oshima.FunGame.OshimaModules.Skills
public (Character? character = null) : base(SkillType.Magic, character) public (Character? character = null) : base(SkillType.Magic, character)
{ {
Effects.Add(new _带基础伤害(this, 40, 40, 0.3, 0.25));
Effects.Add(new (this, true, 15, 0)); Effects.Add(new (this, true, 15, 0));
Effects.Add(new _带基础伤害(this, 40, 40, 0.5, 0.3));
} }
} }
} }

View File

@ -688,7 +688,7 @@
"圣洁之盾": { "圣洁之盾": {
"Id": 12503, "Id": 12503,
"Name": "圣洁之盾", "Name": "圣洁之盾",
"Description": "增加 10% 物理伤害减免。", "Description": "增加 12% 物理伤害减免。",
"BackgroundStory": "传说中由圣光祝福的盾牌,能够抵挡邪恶的力量。", "BackgroundStory": "传说中由圣光祝福的盾牌,能够抵挡邪恶的力量。",
"ItemType": 2, "ItemType": 2,
"WeaponType": 0, "WeaponType": 0,
@ -703,7 +703,7 @@
"Effects": [ "Effects": [
{ {
"Id": 8019, "Id": 8019,
"expdr": 0.10 "expdr": 0.12
} }
] ]
} }
@ -743,7 +743,7 @@
"炼狱战铠": { "炼狱战铠": {
"Id": 12505, "Id": 12505,
"Name": "炼狱战铠", "Name": "炼狱战铠",
"Description": "增加角色 40 点物理护甲,增加角色 10 点每时间生命回复。", "Description": "增加角色 40 点物理护甲,增加角色 5 点每时间生命回复。",
"BackgroundStory": "在无尽战火中锻造而成,具有极高的防御力。", "BackgroundStory": "在无尽战火中锻造而成,具有极高的防御力。",
"ItemType": 2, "ItemType": 2,
"WeaponType": 0, "WeaponType": 0,
@ -762,7 +762,7 @@
}, },
{ {
"Id": 8021, "Id": 8021,
"exhr": 10 "exhr": 5
} }
] ]
} }
@ -1025,7 +1025,7 @@
"辉煌光环": { "辉煌光环": {
"Id": 14504, "Id": 14504,
"Name": "辉煌光环", "Name": "辉煌光环",
"Description": "增加角色 80 点最大魔法值和 5 点每时间魔法回复。", "Description": "增加角色 80 点最大魔法值和 2 点每时间魔法回复。",
"BackgroundStory": "流光溢彩的光环。", "BackgroundStory": "流光溢彩的光环。",
"ItemType": 4, "ItemType": 4,
"WeaponType": 0, "WeaponType": 0,
@ -1044,7 +1044,7 @@
}, },
{ {
"Id": 8022, "Id": 8022,
"exmr": 5 "exmr": 2
} }
] ]
} }
@ -1145,7 +1145,7 @@
"精灵之戒": { "精灵之戒": {
"Id": 14508, "Id": 14508,
"Name": "精灵之戒", "Name": "精灵之戒",
"Description": "增加角色 10 每时间魔法回复,并增加角色 8 点智力。", "Description": "增加角色 5 每时间魔法回复,并增加角色 8 点智力。",
"BackgroundStory": "这枚戒指由精灵制成,能够帮助法师更快地恢复法力。", "BackgroundStory": "这枚戒指由精灵制成,能够帮助法师更快地恢复法力。",
"ItemType": 4, "ItemType": 4,
"WeaponType": 0, "WeaponType": 0,
@ -1160,7 +1160,7 @@
"Effects": [ "Effects": [
{ {
"Id": 8022, "Id": 8022,
"exmr": 10 "exmr": 5
}, },
{ {
"Id": 8005, "Id": 8005,
@ -1203,7 +1203,7 @@
"YukiのCalfSocks": { "YukiのCalfSocks": {
"Id": 14510, "Id": 14510,
"Name": "YukiのCalfSocks", "Name": "YukiのCalfSocks",
"Description": "增加角色 10% 暴击率和 20% 暴击伤害。", "Description": "增加角色 15% 暴击率和 30% 暴击伤害。",
"BackgroundStory": "小雪的小腿袜,拥有神秘的力量,令人神往。", "BackgroundStory": "小雪的小腿袜,拥有神秘的力量,令人神往。",
"ItemType": 4, "ItemType": 4,
"WeaponType": 0, "WeaponType": 0,
@ -1218,11 +1218,11 @@
"Effects": [ "Effects": [
{ {
"Id": 8014, "Id": 8014,
"excr": 0.1 "excr": 0.15
}, },
{ {
"Id": 8015, "Id": 8015,
"excrd": 0.2 "excrd": 0.3
} }
] ]
} }
@ -1232,7 +1232,7 @@
"诺尔希的现代汉语字典": { "诺尔希的现代汉语字典": {
"Id": 14511, "Id": 14511,
"Name": "诺尔希的现代汉语字典", "Name": "诺尔希的现代汉语字典",
"Description": "增加角色 15% 攻击力和 8% 物理护甲。", "Description": "增加角色 25% 攻击力和 160% 物理护甲。",
"BackgroundStory": "懂又不懂。", "BackgroundStory": "懂又不懂。",
"ItemType": 4, "ItemType": 4,
"WeaponType": 0, "WeaponType": 0,
@ -1247,11 +1247,11 @@
"Effects": [ "Effects": [
{ {
"Id": 8024, "Id": 8024,
"exdef": 0.08 "exdef": 1.6
}, },
{ {
"Id": 8023, "Id": 8023,
"exatk": 0.15 "exatk": 0.25
} }
] ]
} }
@ -1286,7 +1286,7 @@
"路人哥的cos服": { "路人哥的cos服": {
"Id": 14513, "Id": 14513,
"Name": "路人哥的cos服", "Name": "路人哥的cos服",
"Description": "增加角色 10% 攻击力,增加角色 10% 魔法抗性,但是会减少 8% 物理伤害减免。", "Description": "增加角色 15% 攻击力,增加角色 10% 魔法抗性,但是会减少 8% 物理伤害减免。",
"BackgroundStory": "一套神秘的服饰,据说穿上后会引发未知的力量变化。", "BackgroundStory": "一套神秘的服饰,据说穿上后会引发未知的力量变化。",
"ItemType": 4, "ItemType": 4,
"WeaponType": 0, "WeaponType": 0,
@ -1301,7 +1301,7 @@
"Effects": [ "Effects": [
{ {
"Id": 8023, "Id": 8023,
"exatk": 0.1 "exatk": 0.15
}, },
{ {
"Id": 8020, "Id": 8020,
@ -1320,7 +1320,7 @@
"白月光的玉佩": { "白月光的玉佩": {
"Id": 14514, "Id": 14514,
"Name": "白月光的玉佩", "Name": "白月光的玉佩",
"Description": "增加角色 15% 魔法抗性,8 点每时间魔法回复和 15% 冷却缩减。", "Description": "增加角色 15% 魔法抗性,4 点每时间魔法回复和 15% 冷却缩减。",
"BackgroundStory": "据说每个总裁都有一个救命恩人,还有一个冒充救命恩人的人。", "BackgroundStory": "据说每个总裁都有一个救命恩人,还有一个冒充救命恩人的人。",
"ItemType": 4, "ItemType": 4,
"WeaponType": 0, "WeaponType": 0,
@ -1340,7 +1340,7 @@
}, },
{ {
"Id": 8022, "Id": 8022,
"exmr": 8 "exmr": 4
}, },
{ {
"Id": 8011, "Id": 8011,