mirror of
https://github.com/magefree/mage.git
synced 2026-01-10 04:42:07 -08:00
[LCI] Implement Get Lost
This commit is contained in:
parent
92a4f41b2b
commit
c6441b31a5
3 changed files with 52 additions and 4 deletions
|
|
@ -13,7 +13,7 @@ import mage.util.CardUtil;
|
|||
|
||||
/**
|
||||
* @author Susucr
|
||||
*
|
||||
* <p>
|
||||
* Have the Controller of target permanent (or LKI controller) create Tokens.
|
||||
*/
|
||||
public class CreateTokenControllerTargetPermanentEffect extends OneShotEffect {
|
||||
|
|
@ -51,9 +51,9 @@ public class CreateTokenControllerTargetPermanentEffect extends OneShotEffect {
|
|||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Permanent creature = getTargetPointer().getFirstTargetPermanentOrLKI(game, source);
|
||||
if (creature != null) {
|
||||
Player controllerOfTarget = game.getPlayer(creature.getControllerId());
|
||||
Permanent permanent = getTargetPointer().getFirstTargetPermanentOrLKI(game, source);
|
||||
if (permanent != null) {
|
||||
Player controllerOfTarget = game.getPlayer(permanent.getControllerId());
|
||||
if (controllerOfTarget != null) {
|
||||
int value = amount.calculate(game, source, this);
|
||||
return token.putOntoBattlefield(value, game, source, controllerOfTarget.getId(), tapped, false);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue