2025-07-10 01:34:43 +08:00

55 lines
2.3 KiB
C#

using Milimoe.FunGame.Core.Api.Utility;
using Milimoe.FunGame.Core.Entity;
using Oshima.FunGame.OshimaModules.Skills;
namespace Oshima.FunGame.OshimaModules.Effects.SkillEffects
{
public class : Effect
{
public override long Id => Skill.Id;
public override string Name => Skill.Name;
public override string Description => $"吸取{Skill.TargetDescription()}的{(是否是百分比 ? $" {Calculation.PercentageCheck(Earned) * 100:0.##}% " : $" {Earned:0.##} ")}魔法值(每个角色)," +
$"并将吸取总量的 {转化百分比 * 100:0.##}% 转化为自身魔法值。";
private double Earned => Skill.Level > 0 ? + * (Skill.Level - 1) : ;
private double { get; set; } = 150;
private double { get; set; } = 75;
private bool { get; set; } = false;
private double { get; set; } = 1;
public (Skill skill, double , double , bool = false, double = 1) : base(skill)
{
GamingQueue = skill.GamingQueue;
this. = ;
this. = ;
this. = ;
this. = Calculation.PercentageCheck();
}
public override void OnSkillCasted(Character caster, List<Character> targets, Dictionary<string, object> others)
{
double total = 0;
foreach (Character target in targets)
{
double earned = Earned;
if ()
{
earned = target.MP * earned;
}
else if (earned > target.MP)
{
earned = target.MP;
}
if (earned > 0)
{
target.MP -= earned;
total += earned;
}
}
total *= ;
caster.MP += total;
WriteLine($"[ {caster} ] 吸取了 [ {string.Join(" ] / [ ", targets)} ] 的 {total:0.##} 点魔法值!");
}
}
}