Package mage.game.command

Examples of mage.game.command.Emblem


        addEmblem(emblem, source, null);
    }

    @Override
    public void addEmblem(Emblem emblem, Ability source, UUID toPlayerId) {
        Emblem newEmblem = emblem.copy();
        newEmblem.setSourceId(source.getSourceId());
        if (toPlayerId == null) {
            newEmblem.setControllerId(source.getControllerId());
        } else {
            newEmblem.setControllerId(toPlayerId);
        }
        newEmblem.assignNewId();
        newEmblem.getAbilities().newId();
        for (Ability ability : newEmblem.getAbilities()) {
            ability.setSourceId(newEmblem.getId());
        }
        state.addCommandObject(newEmblem);
    }
View Full Code Here


            this.expansionSetCode = permanentToken.getExpansionSetCode();
            this.rules = permanentToken.getRules();
            this.type = permanentToken.getToken().getTokenType();
        } else if (object instanceof Emblem) {
            this.mageObjectType = MageObjectType.EMBLEM;
            Emblem emblem = (Emblem) object;
            this.rarity = Rarity.SPECIAL;
            this.rules = emblem.getAbilities().getRules(emblem.getName());
        }
        if (this.rarity == null && object instanceof StackAbility) {
            StackAbility stackAbility = (StackAbility)object;
            this.rarity = Rarity.NA;
            this.rules = new ArrayList<>();
View Full Code Here

            this.userDataView = new UserDataView(0, false, null);
        }
       
        for (CommandObject commandObject : game.getState().getCommand()) {
            if (commandObject instanceof Emblem) {
                Emblem emblem = (Emblem) commandObject;
                if (emblem.getControllerId().equals(this.playerId)) {
                    Card sourceCard = game.getCard(((CommandObject)emblem).getSourceId());
                    if (sourceCard != null) {
                        commandList.add(new EmblemView(emblem, sourceCard));
                    }
                }
View Full Code Here

TOP

Related Classes of mage.game.command.Emblem

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.