public void InitInteractable(ICombatUnit parent) { ParentCombatUnit = parent; }
private void OnUnitDied(ICombatUnit unit) { UnityEngine.Debug.Log(unit.GetName() + " died"); OnCombatUnitDied?.Invoke(unit); }
public AbilityDamageAction(string name, ICombatUnit caster, DamageInfo damageInfo) : base(name, caster) { DamageInfo = damageInfo; }
private void OnTargetEntered(ICombatUnit unit) { Trigger(); }
public AbilityModifierBase(string name, ICombatUnit caster) : base(name, caster) { Events = new List <AbilityEventBase>(); }
private void OnDealtDamage(DamageInfo damageInfo, ICombatUnit other) { Unbind(); Trigger(); }
public void DealtDamage(DamageInfo damageInfo, ICombatUnit other) { FireOnDealtDamage(damageInfo, other); }
public EventConditionBase(ICombatUnit caster) { Caster = caster; }
public static TFlag GetFlag <TFlag>(this ICombatUnit unit) where TFlag : CombatUnitFlagBase { return((TFlag)unit.Flags.SingleOrDefault(val => val is TFlag)); }
public DamageInfo DealDamage(DamageInfo damageInfo, ICombatUnit other) { damageInfo = ((IDealDamageDecorator)this).Decorate(damageInfo); return(damageInfo); }
public AbilityHealAction(string name, ICombatUnit caster, float healthAmount) : base(name, caster) { HealtAmount = healthAmount; }
void HealTarget(ICombatUnit combatUnit) { ((IHealthOwnerCombatUnit)combatUnit).Heal(HealtAmount); FireOnActionEnded(); }
public GameBuffManager(ICombatUnit unit) { m_owner = unit; }
public AbilityThinkerModifier(string name, ICombatUnit caster, float duration, float thinkInterval) : base(name, caster) { Duration = duration; ThinkInterval = thinkInterval; }
public abstract void Attack(ICombatUnit target, System.Action onAttackEnded);
public abstract bool IsSatisfied(ICombatUnit target);
public ImmuneDamageStateDecorator(ICombatUnit parentUnit, params DamageType[] damageTypeArr) : base(parentUnit) { ImmuneDamageTypes = damageTypeArr.ToList(); }
public TargetSelectorBase(ICombatUnit caster, AbilityActionBase parentAction) { _caster = caster; _parentAciton = parentAction; }
public CombatUnitStateDecoratorBase(ICombatUnit parentUnit) { ParentUnit = parentUnit; Conditions = new List <StateDecoratorConditionBase>(); }
public void SetAttackableTiles(ICombatUnit unit, Tile tile) { if (unit is AirCombatUnit) { AirCombatUnit airUnit = (AirCombatUnit)unit; unit.AttackableTiles = GetAirAttackableTiles(airUnit, tile); } else if (unit is SeaCombatUnit) { SeaCombatUnit seaUnit = (SeaCombatUnit)unit; unit.AttackableTiles = GetSeaAttackableTiles(seaUnit, tile); } else if (unit is LandCombatUnit) { LandCombatUnit landUnit = (LandCombatUnit)unit; unit.AttackableTiles = GetLandAttackableTiles(landUnit, tile); } }
public SelectOtherTargetSelector(ICombatUnit caster, AbilityActionBase parentAction) : base(caster, parentAction) { }
public AbilityCreateThinkerAction(string name, ICombatUnit caster, AbilityThinkerModifier thinker) : base(name, caster) { Thinker = thinker; }
public ResistanceDamageStateDecorator(ICombatUnit parentUnit, params ResistanceInfo[] resistanceArr) : base(parentUnit) { ResistanceInfoList = resistanceArr.ToList(); }
public AbilityActionBase(string name, ICombatUnit caster) { Caster = caster; Conditions = new List <EventConditionBase>(); }
public ElementalCondition(ICombatUnit caster, bool doesInclude, params ElementalType[] elementalTypes) : base(caster) { DoesInclude = doesInclude; ElementalTypes = elementalTypes.ToList(); }