diff options
Diffstat (limited to 'go/game/cardImplementations.go')
| -rw-r--r-- | go/game/cardImplementations.go | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/go/game/cardImplementations.go b/go/game/cardImplementations.go index 80865c1c..f304ee1c 100644 --- a/go/game/cardImplementations.go +++ b/go/game/cardImplementations.go @@ -464,15 +464,23 @@ func (*dolphinImpl) fullActions(u *Unit) []*FullAction { return []*FullAction{a} } -type drownedSailorImpl struct { sailorImpl } +type drownedSailorImpl struct{ sailorImpl } func (*drownedSailorImpl) onDrop(sailor Permanent) { sailor.Controller().gameState.destroyPermanent(sailor) } -// TODO: implement death trigger -// TODO: implement hook for the containing permanent on pile -type flyingDutchmenImpl struct{ cardImplementation } +// TODO: implement hook for the containing permanent on pile to change AI +type flyingDutchmenImpl struct{ cardImplementationBase } + +func (*flyingDutchmenImpl) onETB(s *State, p Permanent) { + s.addTrigger(newEnemyDeathTrigger(p, func(s *State) { + sailor := NewCard("kraken/drowned_sailor") + if p.Tile().IsAvailableForCard(sailor) { + addPermanentToPile(p, NewUnit(sailor, nil, p.Controller())) + } + }, p.Card().getEffects()[1])) +} type frostPylonAoE struct{} |
