public void useMana(String cost) {
        if (contains(cost)) {
            int startIndexColored = 0;
            try {
                manaColorless -= parseInt(Character.toString(cost.charAt(0)));
                startIndexColored = 1;
            } catch (NumberFormatException nfe) {
            }
            for (int x = startIndexColored; x < cost.length(); x++) {
                switch (valueOf(valueOf(cost.charAt(x)))) {
                    case B:
                        manaBlack--;
                        break;
                    case G:
                        manaGreen--;
                        break;
                    case R:
                        manaRed--;
                        break;
                    case W:
                        manaWhite--;
                        break;
                    case U:
                        manaBlue--;
                        break;
                    default:
                        break;
                }
            }
        }
    }