public static ActionEffect GetActionEffect(ActionEffectData actionEffectData, BaseCharacterMaster optionalTarget = null) { switch (actionEffectData.AbilityEffectType) { case ActionEffectType.Damage: return(new DamageEffect(actionEffectData)); case ActionEffectType.Heal: return(new HealEffect(actionEffectData)); case ActionEffectType.Taunt: return(new TauntEffect(actionEffectData, optionalTarget)); case ActionEffectType.Shield: return(new ShieldEffect(actionEffectData)); default: Debug.Log("[ActionEffectFactory] ActionEffectType not defined in the ActionEffectFactory"); return(new DamageEffect(0, 0)); } }
protected ActionEffect(ActionEffectData actionEffectData) { TurnsLeftAffected = actionEffectData.AbilityLenght; Power = actionEffectData.AbilityPower; }
public DamageEffect(ActionEffectData abilitySetupSO) : base(abilitySetupSO) { }
public TauntEffect(ActionEffectData actionEffectData, BaseCharacterMaster tauntTarget) : base(actionEffectData) { this.tauntTarget = tauntTarget; }
public HealEffect(ActionEffectData abilitySetupSO) : base(abilitySetupSO) { }
public ShieldEffect(ActionEffectData actionEffectData) : base(actionEffectData) { }