using System.Collections.Generic; using Continentis.MainGame.Card; using Continentis.MainGame.Character; using Continentis.MainGame.Commands; using SLSUtilities.General; using UnityEngine; namespace Continentis.Mods.Basic.Cards { public class ShieldBash : CardLogicBase { public override void SetUpLogicComponents() { AddLogicComponent(); AddLogicComponent(); } public override CommandGroup PlayEffect(List targetList) { var mainGroup = ForEachTarget(targetList, target => Cmd.Parallel( new Cmd_PlayAnimation(user.characterView, "Attack"), Cmd.Do(() => AttackTarget(target, GetTargetedFinalDamage(target))) )); mainGroup.AddCommand(Cmd.Do(() => user.AddBlock(GetAttribute("Block")))); return mainGroup; } public override void ApplyAttributeChangesByCard() { LogicComponent().SetDamage_Physics(); LogicComponent().SetBlock(); } } }