public abstract class CardGameController extends GameController implements TurnGameController, CardCodes, CardGameReceiver
DISPATCHER| Constructor and Description |
|---|
CardGameController() |
| Modifier and Type | Method and Description |
|---|---|
void |
cardsTransferredBetweenPlayers(int fromidx,
int toidx,
int cards)
Dispatched to the client when a set of cards is transferred between two other players in
the game.
|
void |
didLeavePlace(com.threerings.crowd.data.PlaceObject plobj)
Removes our listener registration from the game object and cleans house.
|
void |
receivedCardsFromPlayer(int plidx,
Card[] cards)
Dispatched to the client when it has received a set of cards from another player.
|
void |
receivedHand(Hand hand)
Called when the server deals the client a new hand of cards.
|
void |
receivedHand(int oid,
Hand hand)
Called by our sender to notify us of a received hand.
|
void |
sentCardsToPlayer(int plidx,
Card[] cards)
Dispatched to the client when the server has forced it to send a set of cards to another
player.
|
void |
turnDidChange(com.threerings.util.Name turnHolder)
Called when the turn changed.
|
void |
willEnterPlace(com.threerings.crowd.data.PlaceObject plobj)
Adds this controller as a listener to the game object (thus derived classes need not do so)
and lets the game manager know that we are now ready to go.
|
attributeChanged, getMatchType, getSessionId, handleAction, init, isGameOver, resetGame, setGameOver, systemMessagegetPlaceConfig, getPlaceView, mayLeavePlaceactionPerformed, configureAction, createActionButton, handleAction, handleAction, handleAction, postAction, postAction, postAction, setControlledPanel, wasAdded, wasRemovedpublic void willEnterPlace(com.threerings.crowd.data.PlaceObject plobj)
GameControllerwillEnterPlace in class GameControllerpublic void didLeavePlace(com.threerings.crowd.data.PlaceObject plobj)
GameControllerdidLeavePlace in class GameControllerpublic void turnDidChange(com.threerings.util.Name turnHolder)
TurnGameControllerturnDidChange in interface TurnGameControllerturnHolder - the username of the new holder of the turn.public final void receivedHand(int oid,
Hand hand)
receivedHand in interface CardGameReceiveroid - the oid of the game for which this hand applieshand - the received handpublic void receivedHand(Hand hand)
hand - the hand dealt to the userpublic void receivedCardsFromPlayer(int plidx,
Card[] cards)
receivedCardsFromPlayer in interface CardGameReceiverplidx - the index of the player providing the cardscards - the cards receivedpublic void sentCardsToPlayer(int plidx,
Card[] cards)
sentCardsToPlayer in interface CardGameReceiverplidx - the index of the player to which the cards were sentcards - the cards sentpublic void cardsTransferredBetweenPlayers(int fromidx,
int toidx,
int cards)
cardsTransferredBetweenPlayers in interface CardGameReceiverfromidx - the index of the player sending the cardstoidx - the index of the player receiving the cardscards - the number of cards transferredCopyright © 2015. All rights reserved.