Files
SVSimServer/SVSim.BattleEngine/Engine/Wizard/AIDamageCutInfo.cs
gamer147 824309ec44 feat(battle-engine): close the AI-simulation subsystem (verbatim)
Copied the 89 uncopied AI*SimulationUtility/extension files defining the
AIVirtualCard/AIVirtualField extension methods; the compile loop then auto-closed
the revealed type deps (~3049 files total, drift-clean). 10.0k -> 62 errors.
2026-06-05 20:30:59 -04:00

42 lines
1.0 KiB
C#

using System.Collections.Generic;
using UnityEngine;
namespace Wizard;
public class AIDamageCutInfo : AIBarrierInfoBase
{
public override AIBarrierType BarrierType => AIBarrierType.DamageCut;
public AIDamageCutInfo(int amount, AIDamageType damageType, AIBarrierStopTiming stopTiming)
: base(amount, damageType, stopTiming)
{
UpdateHash();
}
public AIDamageCutInfo(int amount, AIDamageType damageType, List<AIBarrierStopTiming> stopTimingList)
: base(amount, damageType, stopTimingList)
{
UpdateHash();
}
public override AIBarrierInfoBase Clone()
{
return new AIDamageCutInfo(base.BarrierAmount, base.DamageType, base.StopTimingList);
}
public override bool IsShield()
{
return false;
}
protected override int CalcDamage(AIVirtualCard owner, int damage)
{
return Mathf.Max(0, damage - base.BarrierAmount);
}
protected override void UpdateHash()
{
base.Hash = AIBarrierSimulationUtility.CalculateDamageCutInfoHash(base.DamageType, BarrierType, base.StopTimingList, base.BarrierAmount);
}
}