Implement GraniteDefense
This commit is contained in:
parent
ef9ec43c8a
commit
dd9b360bfc
5 changed files with 39 additions and 2 deletions
21
Assets/Battle/CardsMonsters/GraniteDefenseMCard.cs
Normal file
21
Assets/Battle/CardsMonsters/GraniteDefenseMCard.cs
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class GraniteDefenseMCard : MonsterCard
|
||||
{
|
||||
public GraniteDefenseMCard(BattleParticipant owner)
|
||||
: base(owner, MCardId.GolemBerserk, "Granite Defense", 3, CardType.Skill,
|
||||
"Block 5 damage on other allies.") {
|
||||
}
|
||||
|
||||
public override IEnumerator Use(IBattleEffectApplier effectApplier, MonsterViewpoint monsterViewpoint) {
|
||||
yield return new WaitForSeconds(1f);
|
||||
foreach (BattleMonster monster in monsterViewpoint.Monsters) {
|
||||
if (monster != this.owner) {
|
||||
effectApplier.Apply(new BlockEffect(monster, 5));
|
||||
yield return new WaitForSeconds(1f);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
11
Assets/Battle/CardsMonsters/GraniteDefenseMCard.cs.meta
Normal file
11
Assets/Battle/CardsMonsters/GraniteDefenseMCard.cs.meta
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
fileFormatVersion: 2
|
||||
guid: f39c6f5691c165540b6ea0ee1c2bde57
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Loading…
Add table
Add a link
Reference in a new issue