新的技能测试

This commit is contained in:
milimoe 2024-09-10 00:54:37 +08:00
parent 4ed2c0127a
commit 9673c1a1b2
Signed by: milimoe
GPG Key ID: 05D280912DA6C69E
8 changed files with 129 additions and 10 deletions

View File

@ -6,12 +6,11 @@ namespace Milimoe.FunGame.Testing.Effects
{ {
public class (Skill skill) : Effect(skill) public class (Skill skill) : Effect(skill)
{ {
public override long Id => 1; public override long Id => Skill.Id;
public override string Name => "冰霜攻击"; public override string Name => "冰霜攻击";
public override string Description => $"对目标敌人造成 {Calculation.Round4Digits(1.2 * (1 + 1.8 * (Skill.Level - 1))) * 100}%智力 [ {Damage} ] 点{CharacterSet.GetMagicName(MagicType)}。"; public override string Description => $"对目标敌人造成 {Calculation.Round2Digits(90 + 60 * (Skill.Level - 1))} + {Calculation.Round2Digits((1.2 + 1.8 * (Skill.Level - 1)) * 100)}%智力 [ {Damage} ] 点{CharacterSet.GetMagicName(MagicType)}。";
public override bool TargetSelf => false; public override bool TargetSelf => false;
public override int TargetCount => 1; public override int TargetCount => 1;
public override MagicType MagicType => MagicType.None;
private double Damage private double Damage
{ {
@ -20,7 +19,7 @@ namespace Milimoe.FunGame.Testing.Effects
double d = 0; double d = 0;
if (Skill.Character != null) if (Skill.Character != null)
{ {
d = Calculation.Round2Digits(1.2 * (1 + 1.8 * (Skill.Level - 1)) * Skill.Character.INT); d = Calculation.Round2Digits(90 + 60 * (Skill.Level - 1) + (1.2 + 1.8 * (Skill.Level - 1)) * Skill.Character.INT);
} }
return d; return d;
} }

View File

@ -6,14 +6,13 @@ namespace Milimoe.FunGame.Testing.Effects
{ {
public class (Skill skill) : Effect(skill) public class (Skill skill) : Effect(skill)
{ {
public override long Id => 1; public override long Id => Skill.Id;
public override string Name => "天赐之力"; public override string Name => "天赐之力";
public override string Description => $"{Duration} 时间内,获得 25% 闪避率(不可叠加),普通攻击硬直时间额外减少 20%,基于 {Calculation.Round4Digits((1.2 + (1 + 0.6 * (Skill.Level - 1))) * 100)}% 核心属性 [ {伤害加成} ] 强化普通攻击的伤害。"; public override string Description => $"{Duration} 时间内,获得 25% 闪避率(不可叠加),普通攻击硬直时间额外减少 20%,基于 {Calculation.Round2Digits((1.2 + (1 + 0.6 * (Skill.Level - 1))) * 100)}% 核心属性 [ {伤害加成} ] 强化普通攻击的伤害。";
public override bool TargetSelf => false; public override bool TargetSelf => false;
public override int TargetCount => 1; public override int TargetCount => 1;
public override bool Durative => true; public override bool Durative => true;
public override double Duration => 40; public override double Duration => 40;
public override MagicType MagicType => MagicType.Element;
private double private double
{ {

View File

@ -0,0 +1,85 @@
using Milimoe.FunGame.Core.Api.Utility;
using Milimoe.FunGame.Core.Entity;
using Milimoe.FunGame.Core.Library.Constant;
namespace Milimoe.FunGame.Testing.Effects
{
public class (Skill skill) : Effect(skill)
{
public override long Id => Skill.Id;
public override string Name => "疾风步";
public override string Description => $"进入不可选中状态,获得 100 行动速度,持续 {Duration} 时间。在持续时间内,首次造成伤害会附加 {Calculation.Round2Digits((1.5 + 1.5 * (Skill.Level - 1)) * 100)}% 敏捷 [ {伤害加成} ] 的强化伤害,并解除不可选中状态。剩余的持续时间内,提高 15% 闪避率和暴击率。";
public override bool TargetSelf => true;
public override bool Durative => true;
public override double Duration => 15 + (2 * (Level - 1));
private double
{
get
{
double d = 0;
if (Skill.Character != null)
{
d = Calculation.Round2Digits((1.5 + 1.5 * (Skill.Level - 1)) * Skill.Character.AGI);
}
return d;
}
}
private bool { get; set; } = true;
private bool { get; set; } = false;
public override void OnEffectGained(Character character)
{
character.IsUnselectable = true;
Skill.IsInEffect = true;
character.ExSPD += 100;
}
public override void OnEffectLost(Character character)
{
Skill.IsInEffect = false;
if ()
{
character.ExEvadeRate -= 0.15;
character.ExCritRate -= 0.15;
}
else
{
character.IsUnselectable = false;
}
character.ExSPD -= 100;
}
public override bool AlterActualDamageAfterCalculation(Character character, Character enemy, double damage, bool isNormalAttack, bool isMagicDamage, MagicType magicType, bool isCritical, out double newDamage)
{
if ()
{
= false;
newDamage = Calculation.Round2Digits(damage + );
Console.WriteLine($"[ {character} ] 发动了 [ 疾风步 ] 的特效,获得了 [ {伤害加成} ] 点伤害加成!");
= true;
character.ExEvadeRate += 0.15;
character.ExCritRate += 0.15;
character.IsUnselectable = false;
return true;
}
else
{
newDamage = damage;
return true;
}
}
public override void OnSkillCasted(ActionQueue queue, Character actor, List<Character> enemys, List<Character> teammates, Dictionary<string, object> others)
{
if (!actor.Effects.Contains(this))
{
= true;
= false;
RemainDuration = Duration;
actor.Effects.Add(this);
OnEffectGained(actor);
}
}
}
}

View File

@ -57,6 +57,15 @@ foreach (string moduledll in moduledllsha512.Keys)
} }
} }
// M = 0, W = 7, P1 = 1, P3 = 1
// M = 1, W = 6, P1 = 2, P3 = 0
// M = 2, W = 4, P1 = 0, P3 = 2
// M = 2, W = 5, P1 = 0, P3 = 0
// M = 3, W = 3, P1 = 1, P3 = 1
// M = 4, W = 2, P1 = 2, P3 = 0
// M = 5, W = 0, P1 = 0, P3 = 2
// M = 5, W = 1, P1 = 0, P3 = 0
if (list.Count > 3) if (list.Count > 3)
{ {
Console.WriteLine(); Console.WriteLine();
@ -100,6 +109,13 @@ if (list.Count > 3)
c.Skills.Add(); c.Skills.Add();
} }
if (c.ToString() == character9.ToString())
{
Skill = new (c);
.Level += 6;
c.Skills.Add();
}
Skill = new (c); Skill = new (c);
.Level += 6; .Level += 6;
c.Skills.Add(); c.Skills.Add();

View File

@ -5,7 +5,7 @@ namespace Milimoe.FunGame.Testing.Skills
{ {
public class : Skill public class : Skill
{ {
public override long Id => 1; public override long Id => 2001;
public override string Name => "冰霜攻击"; public override string Name => "冰霜攻击";
public override string Description => Effects.Count > 0 ? Effects.First().Description : ""; public override string Description => Effects.Count > 0 ? Effects.First().Description : "";
public override double MPCost => BaseMPCost + (50 * (Level - 1)); public override double MPCost => BaseMPCost + (50 * (Level - 1));

View File

@ -5,7 +5,7 @@ namespace Milimoe.FunGame.Testing.Skills
{ {
public class : Skill public class : Skill
{ {
public override long Id => 1; public override long Id => 5001;
public override string Name => "大岛特性"; public override string Name => "大岛特性";
public override string Description => Effects.Count > 0 ? Effects.First().Description : ""; public override string Description => Effects.Count > 0 ? Effects.First().Description : "";

View File

@ -5,7 +5,7 @@ namespace Milimoe.FunGame.Testing.Skills
{ {
public class : Skill public class : Skill
{ {
public override long Id => 1; public override long Id => 3001;
public override string Name => "天赐之力"; public override string Name => "天赐之力";
public override string Description => Effects.Count > 0 ? Effects.First().Description : ""; public override string Description => Effects.Count > 0 ? Effects.First().Description : "";
public override double EPCost => 100; public override double EPCost => 100;

View File

@ -0,0 +1,20 @@
using Milimoe.FunGame.Core.Entity;
using Milimoe.FunGame.Testing.Effects;
namespace Milimoe.FunGame.Testing.Skills
{
public class : Skill
{
public override long Id => 4001;
public override string Name => "疾风步";
public override string Description => Effects.Count > 0 ? Effects.First().Description : "";
public override double EPCost => 35;
public override double CD => 35;
public override double HardnessTime => 5;
public (Character character) : base(true, false, character)
{
Effects.Add(new (this));
}
}
}