We need to be able to veto the rematch.

git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3492 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
Michael Bayne
2005-04-15 02:50:49 +00:00
parent b221524071
commit 12d1d00e4b
@@ -74,8 +74,21 @@ public class CardGameManager extends GameManager
*/ */
public void rematchGame () public void rematchGame ()
{ {
if (gameWillRematch()) {
startGame(); startGame();
} }
}
/**
* Derived classes can override this method and take any action needed
* prior to a game rematch. If the rematch needs to be vetoed for any
* reason, they can return false from this method and the rematch will
* be aborted.
*/
protected boolean gameWillRematch ()
{
return true;
}
/** /**
* Deals a hand of cards to the player at the specified index from * Deals a hand of cards to the player at the specified index from