author | llornkcor <llornkcor> | 2004-04-26 10:24:35 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2004-04-26 10:24:35 (UTC) |
commit | f6a98984fcb0dfc7e176636560b7cc1adacf38f2 (patch) (unidiff) | |
tree | f358b16531551035a54c1dac95e16a36f86f8dc9 /noncore/games/solitaire/patiencecardgame.cpp | |
parent | 57d7f3faf053786925d2315e43ab6ba8d892f51a (diff) | |
download | opie-f6a98984fcb0dfc7e176636560b7cc1adacf38f2.zip opie-f6a98984fcb0dfc7e176636560b7cc1adacf38f2.tar.gz opie-f6a98984fcb0dfc7e176636560b7cc1adacf38f2.tar.bz2 |
turn off silly casino rules solitare
Diffstat (limited to 'noncore/games/solitaire/patiencecardgame.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/games/solitaire/patiencecardgame.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/noncore/games/solitaire/patiencecardgame.cpp b/noncore/games/solitaire/patiencecardgame.cpp index 756577a..a1e4968 100644 --- a/noncore/games/solitaire/patiencecardgame.cpp +++ b/noncore/games/solitaire/patiencecardgame.cpp | |||
@@ -114,15 +114,15 @@ void PatienceCardGame::deal(void) | |||
114 | 114 | ||
115 | 115 | ||
116 | void PatienceCardGame::readConfig( Config& cfg ) | 116 | void PatienceCardGame::readConfig( Config& cfg ) |
117 | { | 117 | { |
118 | cfg.setGroup("GameState"); | 118 | cfg.setGroup("GameState"); |
119 | 119 | ||
120 | deckTurns = cfg.readNumEntry("DeckTurns", 2500); | ||
120 | // Do we have a config file to read in? | 121 | // Do we have a config file to read in? |
121 | if ( !cfg.hasKey("numberOfTimesThroughDeck") ) | 122 | if ( !cfg.hasKey("numberOfTimesThroughDeck") ) { |
122 | { | ||
123 | // if not, create a new game | 123 | // if not, create a new game |
124 | newGame(); | 124 | newGame(); |
125 | return; | 125 | return; |
126 | } | 126 | } |
127 | // We have a config file, lets read it in and use it | 127 | // We have a config file, lets read it in and use it |
128 | 128 | ||
@@ -274,6 +274,15 @@ void PatienceCardGame::mousePress(QPoint p) | |||
274 | 274 | ||
275 | moved = TRUE; | 275 | moved = TRUE; |
276 | } | 276 | } |
277 | } | 277 | } |
278 | 278 | ||
279 | 279 | ||
280 | bool PatienceCardGame::canTurnOverDeck() { | ||
281 | return (numberOfTimesThroughDeck != deckTurns); | ||
282 | } | ||
283 | |||
284 | void PatienceCardGame::throughDeck() { | ||
285 | numberOfTimesThroughDeck++; | ||
286 | if (numberOfTimesThroughDeck == deckTurns) | ||
287 | circleCross->setCross(); | ||
288 | } | ||