private static void putResolve(final AbilityFactory af, final SpellAbility sa) {
        HashMap<String, String> params = af.getMapParams();

        Card card = af.getHostCard();
        String type = params.get("CounterType");
        int counterAmount = AbilityFactory.calculateAmount(af.getHostCard(), params.get("CounterNum"), sa);

        ArrayList<Card> tgtCards;

        Target tgt = af.getAbTgt();
        if (tgt != null)
            tgtCards = tgt.getTargetCards();
        else {
            tgtCards = AbilityFactory.getDefinedCards(card, params.get("Defined"), sa);
        }

        for (Card tgtCard : tgtCards) {
            if (tgt == null || CardFactoryUtil.canTarget(card, tgtCard)) {
                if (AllZone.getZone(tgtCard).is(Constant.Zone.Battlefield))
                    tgtCard.addCounter(Counters.valueOf(type), counterAmount);
                else    // adding counters to something like re-suspend cards
                    tgtCard.addCounterFromNonEffect(Counters.valueOf(type), counterAmount);
            }
        }
    }