Commit graph

14 commits

Author SHA1 Message Date
Olivier Teulière
8437316c36 Topping: give a default empty move to the player.
This avoids a crash if the player uses hints at the first turn.
2013-04-03 21:56:46 +02:00
Olivier Teulière
30385abe30 Results: new MasterResults implementation, using the MoveSelector class.
This avoids calling MoveSelector everywhere in the code.
2013-01-19 00:36:07 +01:00
Olivier Teulière
664eec36ed New MoveSelector class, to help find the "best" move to play.
The best move has the highest possible score, but it is also the one
leading to the most interesting game. This is a subjective notion, but
some heuristics can help, such as:
 - a move sparing a blank is better than one using it
 - a move with many prefixes and suffixes is better than one without
   extensions
 - a move "opening" the game is better than one blocking it
 - a move leaving a nice rack is better than one leaving "bad" letters

At the moment, only the first heuristic is implemented.
2013-01-16 19:00:01 +01:00
Olivier Teulière
83baec368b Topping: give the score penalty directly with the player move.
This commit also adds a setting to disable the elapsed-time penalty.
2013-01-16 17:46:47 +01:00
Olivier Teulière
cdcb5c25b7 TurnData: remove the m_playerId member 2013-01-16 14:40:34 +01:00
Olivier Teulière
1e0de63ef8 Results: add a isEmpty() method, and use it where possible 2013-01-16 11:15:12 +01:00
Olivier Teulière
89b5f757ca Topping: do not assign an empty move to the player immediately.
It is now done only after a timeout, to avoid the need to replace
this empty move when the player finds a top move.
2013-01-15 11:43:30 +01:00
Olivier Teulière
ec0cfb47fa Topping: add a preference to set the penalty value in case of timeout 2013-01-14 17:13:48 +01:00
Olivier Teulière
7e9dab2e9b Topping: keep track of the player score 2013-01-14 17:13:48 +01:00
Olivier Teulière
7cd6313dac Topping: integrate hints 2013-01-08 16:04:24 +01:00
Olivier Teulière
b5d175fc5b Topping: use a different method to play the move.
This allows providing additional time information
2013-01-08 16:04:23 +01:00
Olivier Teulière
76fefdf71d New "master game" feature.
When a master game is defined, the racks and moves played from the
current game will be the same as in the master game. This can be
practical to replay a game in a different mode, or to replay at home a
duplicate game played in a club, for example.
2012-12-30 16:38:07 +01:00
Olivier Teulière
57a2c0690f Topping: keep track of all the moves played by the player.
The timing information is currently not used at all.
2012-12-29 17:51:52 +01:00
Olivier Teulière
681a7b28cb New topping mode (very beginning) 2012-12-29 17:51:16 +01:00