Examples of PlayerCard


Examples of com.threerings.parlor.card.data.PlayerCard

     *
     * @param trumpSuit the trump suit, or -1 for none
     */
    public static PlayerCard getHighestInLeadSuit (PlayerCard[] cardsPlayed, int trumpSuit)
    {
        PlayerCard highest = cardsPlayed[0];
        for (int ii = 1; ii < cardsPlayed.length; ii++) {
            PlayerCard other = cardsPlayed[ii];
            if ((other.card.getSuit() == highest.card.getSuit() &&
                    other.card.compareTo(highest.card) > 0) ||
                (other.card.getSuit() == trumpSuit && highest.card.getSuit() != trumpSuit)) {
                highest = other;
            }
View Full Code Here

Examples of com.threerings.parlor.card.data.PlayerCard

        try {
            // play the card by removing it from the hand and adding it
            // to the end of the cards played array
            _hands[pidx].remove(card);
            PlayerCard[] cards = ArrayUtil.append(
                _trickCardGame.getCardsPlayed(), new PlayerCard(pidx, card));
            _trickCardGame.setCardsPlayed(cards);

            // end the user's turn
            endTurn();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.