Files
Cielonos/Assets/Scripts/MainGame/Managers/CombatManager/EnemySubmodule/SearchingFunctions.cs
SoulliesOfficial 39b43680a9 爆更
2026-07-18 03:16:20 -04:00

27 lines
929 B
C#

using Cielonos.MainGame.Buffs.Character;
using Cielonos.MainGame.Characters;
namespace Cielonos.MainGame
{
public partial class CombatManager
{
public partial class EnemySubmodule
{
/// <summary>
/// 判断敌人当前是否可被指定 Breakthrough 类型打断。
/// 目前用于 Query().PreferDisruptable() 给可打断目标提高索敌优先级。
/// </summary>
public bool IsDisruptable(Enemy enemy, Breakthrough.Type breakthroughType = Breakthrough.Type.Disruption)
{
if (enemy == null || enemy.statusSm.isDead)
{
return false;
}
bool hasBuff = enemy.buffSm.HasBuff<BreakthroughResistanceModification>();
return hasBuff && !enemy.reactionSc.breakthroughResistances[breakthroughType].Value;
}
}
}
}