Commit graph

14 commits

Author SHA1 Message Date
Olivier Teulière
4200e33c17 Change the copyright years for all the files modified in 2012 2012-10-11 13:45:24 +02:00
Olivier Teulière
e51d2f9a23 Rename TurnCmd into Turn (step 3) 2012-10-06 17:49:36 +02:00
Olivier Teulière
ec571d64e4 Rename TurnCmd into Turn (step 2) 2012-10-06 17:49:36 +02:00
Olivier Teulière
3d724166b6 Allow inserting and dropping a single command in the history. 2012-03-26 07:49:24 +02:00
Olivier Teulière
435d3a2f42 New methods to replace a command in the current turn (even if it is not the last one) 2012-03-14 20:40:23 +01:00
Olivier Teulière
25a36ec9cd Arbitration mode: allow setting the rack randomly 2012-03-11 00:24:21 +01:00
Olivier Teulière
b1ed3215d9 Rewrote the navigation system, to make it more powerful and easier to understand.
Internally, commands are now stored a bit differently: some commands
which were at the end of a turn (like the players rack in duplicate
mode) are now at the beginning. But from a user point of view, there is
no visible difference, except some details in training mode (and the new
behaviour is arguably better :)).
Only (known) problem: after loading a game saved before this commit,
navigating in the game history may be less nice (in particular, racks
may not be fully restored).
2012-02-21 08:22:33 +01:00
Olivier Teulière
de2d2777e2 The TurnCmd class does not inherit from Command anymore 2012-02-21 08:22:33 +01:00
Olivier Teulière
0c76b9d781 Simplified the looging macros, and added logs in various key places. 2011-01-29 23:47:20 +00:00
Olivier Teulière
3c7a84d543 Support saving/loading games (any game type) in XML format.
Status:
It works well, but there are still a few details to improve/fix

More details about the changes:
 - New dependency on Arabica and Libxml2 to parse the XML
 - Loading the old format is still supported for this release, but won't be supported anymore in the next one
 - Games are now only saved in the new format
 - In training mode, the player is now created externally, like in the other modes
 - Avoid using GameIO (the one from game/) whenever possible
 - Do not use a FILE* argument anymore when loading a game
 - Throw and catch exceptions correctly when a game cannot be loaded or saved
 - The non-regression tests now use a new method to print the game history
2009-11-29 16:01:31 +00:00
Olivier Teulière
a79b71f028 When navigating in the history, display the current turn in the status bar 2008-11-30 20:51:05 +00:00
Olivier Teulière
fa225881c0 Do not allow navigating before the first turn, and do not count an empty turn as a real one when navigating.
The navigation in the history is now more natural.
2008-11-23 17:08:12 +00:00
Olivier Teulière
53cccd529e Added toString() methods to the commands to ease debugging 2008-11-23 17:02:33 +00:00
Olivier Teulière
675b534e77 - Fixed compilation in debug mode
- Centralized navigation in the game history in the Navigation class
 - The Qt interface now has (very) basic controls to navigate in the history.
2008-11-23 16:55:28 +00:00