Commit graph

48 commits

Author SHA1 Message Date
Olivier Teulière
990f4c5212 Qt interface:
- Initialize the random numbers generator, and print the seed value
 - Handle properly Qt builds without STL support
 - Save the position of the main window
 - Got rid of the useless toolbar
 - Better size of the preferences dialog
 - Hopefully fixed translation issues on Windows
 - The Settings class throws an exception when asked for a non-existing setting
2008-09-05 21:31:30 +00:00
Olivier Teulière
75a67b28a5 Dic:
- Throw an exception if a regular expresison is invalid
 - Handle the exception in callers code

Game:
 - Fixed a bug in setRackRandom()

Qt interface:
 - Display the dictionary name in the status bar
 - Implemented printing
 - Translation of the interface into French. The menus have temporarily lost their accelerator keys in English.
2008-08-31 11:48:11 +00:00
Olivier Teulière
90badeca21 - Fixed a bug in the parser, preventing to parse correctly some regular expressions with wide chars. The regular expressions seem now to work fine with a dictionary using polish words.
- More C++ in the automaton code
 - Simplified the code in several places
2008-07-27 13:32:47 +00:00
Olivier Teulière
7ea51d2f23 Compilation fixes for some systems (missing headers) 2008-07-20 12:15:51 +00:00
Olivier Teulière
11adaba410 - Added several tests for the regular expressions engine
- New regexp parser using Boost.Spirit. Lex and yacc are now gone.
   The main advantage of this new parser, apart from being purely C++,
   is that it can handle wide characters.
   Currently, the new parser does the same as the previous one, but the
   code is not yet ready to use regular expressions with non-ASCII
   dictionaries.
2008-07-07 17:29:59 +00:00
Olivier Teulière
414baa8d7a - Use vectors instead of lists to store the results of dictionary searches
- New parameter to most search functions, allowing to limit the number of results.
   No interface uses it yet.
2008-03-02 18:45:10 +00:00
Olivier Teulière
52b7363888 Players are not created by the Game object anymore but by the user of the class.
This allows more flexibility, in particular to choose the type of player or its name.
2008-01-28 19:17:33 +00:00
Olivier Teulière
0a4b342f78 - Players can now have a name
- Use player names in the ncurses interface
 - In training mode, create the hidden player in the constructor, not in start()
 - When the AI has nothing to play, change the letters instead of simply passing
 - New Makefile to build the win32 dependencies automatically (INSTALL file updated)
2008-01-19 19:33:08 +00:00
Olivier Teulière
81e980104f - Board::GetLetterMultiplier() and Board::GetWordMultiplier() are now static
- Added 2 convenient getters: Dictionary::getName() and Bag::getDic()
2008-01-09 10:48:19 +00:00
Olivier Teulière
ba230eda60 - Bumped version number to 1.6
- Used the -Wall option of automake, and fixed the reported warnings
 - Updated french translation
2008-01-08 16:09:08 +00:00
Olivier Teulière
e7a8d01a8d Merged the "cppdic" branch back into HEAD.
There are too many change to list properly, here is an overview of the main changes:
 - the dictionary is now in C++
 - the dictionary has a new format, where it is possible to specify the letters,
   their points, their frequency, ... It is backwards compatible.
 - Eliot now supports non-ASCII characters everywhere
 - i18n of the compdic, listdic, regexpmain binaries
 - i18n of the wxWidgets interface (now in english by default)
2008-01-08 13:52:32 +00:00
Antoine Fraboulet
d86bd2af4a - 32/64 bits types
- unused function parameters
2007-08-04 20:01:27 +00:00
Olivier Teulière
831c578c3a Use Unix file fornat 2006-12-23 13:57:08 +00:00
Antoine Fraboulet
70041c80b3 - extra debug output command for board cross info 2006-11-05 13:27:49 +00:00
Antoine Fraboulet
6f00463fa1 - removed game loading commands in mode loops
- add game loading in main loop
- changed stderr to stdout for incorrect words during gameplay
2006-08-11 22:06:53 +00:00
Olivier Teulière
1e13d6bfad Release memory properly at exit, and fixed a new/free mismatch 2006-01-29 12:40:49 +00:00
Olivier Teulière
77be2e9219 Backport of the 'multibyte' branch on HEAD. 2006-01-22 12:23:52 +00:00
Antoine Fraboulet
30d6cc0687 - eliottxt.cpp
add "a P" command for standard format printout
    add regexp testing
    add performance testing
2006-01-01 19:32:44 +00:00
Olivier Teulière
3ecf740432 - do not use std:: everywhere, it justs makes the code harder to read
- history.h: use forward declarations to reduce dependencies
 - history.cpp: fixed a compilation warning
2005-12-27 16:54:38 +00:00
Olivier Teulière
9aeeafa61b Removed the useless Game::getPlayerRack() method 2005-12-27 15:01:07 +00:00
Antoine Fraboulet
240d106a9d - correct comment, removing loading game from training mode 2005-12-27 09:23:08 +00:00
Antoine Fraboulet
1a69bd0fa9 - correct help message for training mode 2005-12-27 00:30:56 +00:00
Antoine Fraboulet
41e90acadc - use of History class 2005-12-26 23:35:03 +00:00
Olivier Teulière
03e8a80128 Use a vector of Turn objects instead of several history vectors 2005-11-05 23:22:41 +00:00
Olivier Teulière
5b682ef9b8 - Removed Game::format*
- Added Game::getPlayer
2005-11-05 15:48:59 +00:00
Olivier Teulière
50fc82f60c First backports from the branch (Game::getBoard and Game::getBag, mainly) 2005-11-04 23:26:03 +00:00
Olivier Teulière
fe13a5e627 Removed the $Id:$ lines on HEAD 2005-11-04 20:00:05 +00:00
Olivier Teulière
e3bc46b114 Updated licence text with FSF's new address. 2005-10-23 14:53:42 +00:00
Olivier Teulière
b4e66f273e Use the readline library in the text interface. In particular, it provides
a history of commands
2005-04-27 17:55:32 +00:00
Olivier Teulière
48d111adca Ability to specify the random seed on command-line. 2005-04-10 12:15:40 +00:00
Olivier Teulière
6b025b9541 - Several fixes in the build system
- Added a bootstrap script to reduce manual work
 - Added a --enable-debug configure switch to define the DEBUG variable
2005-04-03 21:12:03 +00:00
Olivier Teulière
855a6ad7e6 The title bar now indicates when it is a joker game 2005-04-02 21:18:24 +00:00
Olivier Teulière
4a71c13990 Initialize the random numbers generator before setting the first racks... 2005-04-02 18:22:53 +00:00
Olivier Teulière
5f63f46635 Display the "search complete" message only when the search is complete... 2005-03-27 22:21:29 +00:00
Olivier Teulière
5784cec146 Added/updated comments in many headers 2005-03-27 17:30:48 +00:00
Olivier Teulière
f45fd22c16 The game mode and the players are nod hardcoded anymore in the ncurses
interface: they can be entered with the command-line (parsed using getopt).
The text interface does not benefit from this facility yet.
2005-03-03 22:14:41 +00:00
Olivier Teulière
7db671ad31 Isolated the print* methods in a dedicated class, outside of the Game library 2005-02-26 22:57:34 +00:00
Olivier Teulière
6ca09c9ac9 Added a GameFactory class to centralize the allocation and deallocation of
Game objects.
2005-02-24 08:06:24 +00:00
Olivier Teulière
85debd4343 Support for loading a game in the ncurses interface 2005-02-22 23:12:57 +00:00
Olivier Teulière
bbae15d9ad Added support for saving a game from the ncurses interface 2005-02-21 22:42:06 +00:00
Olivier Teulière
82547c5f66 - Better handling of the players with inheritance and with a clean interface
for the AI players
 - Moved the search results accessors from Game to Training
2005-02-17 20:01:59 +00:00
Olivier Teulière
104335e6aa - Completed i18n of the ncurses interface
- Updated french translation
2005-02-07 22:20:32 +00:00
Olivier Teulière
91048b8dbe Link correctly with libintl in all cases 2005-02-06 22:38:10 +00:00
Olivier Teulière
0032104189 - i18n system is in place (requires gettext 0.11.5).
Very few strings are marked as translatable yet...
 - ncurses.cpp: fixed a memory leak
2005-02-06 22:18:11 +00:00
Olivier Teulière
b7032e2d78 - The Game library is now in C++.
This simplifies the code in many places, and allows inheritance of the
   game mode classes (Training, Duplicate and FreeGame).
 - A Tile is no more an unsigned char, but a class: it should help supporting
   i18n of the game. The Dic library still uses unsigned chars though.
 - Improved the configure script, to enable/disable the compilation of some
   interfaces.
 - Added a ncurses interface, much nicer than the text one. The game mode and
   the number of players are currently hardcoded, it is not possible to change
   them interactively (yet).
 - Repaired the save/load functions.

NOTE: The wxWindows interface compiles, but is completely broken. I'm afraid it
needs a full rewrite (to support the various game modes in particular).
2005-02-05 11:14:56 +00:00
Olivier Teulière
b102aafbcd Support for 3 different game modes:
- 'Training' mode: same behaviour as before
  - 'Duplicate' mode: all the players (who can be human players or AI
    players) have the same rack, and the best word is played on the
    board
  - 'Free game' mode: the players (human or AI) have different racks,
    and they play one after another

Status:
  - Core: the main functions are written, but the API could be more
    homogeneous between the different modes.
  - Interfaces: the text interface is almost up-to-date, but the
    wxwindows one only supports Training mode.
  - AI: Currently, AI players always play the best word, which is
    optimal in Duplicate mode but not in FreeGame mode. Other strategies
    will be written in the future.
  - Handling of saved games is broken: a game can be saved and loaded,
    but no information about the mode and the players is stored, so it
    crashes whatever you do after loading the game.
2004-08-07 18:10:42 +00:00
Olivier Teulière
acd1aa0f1b Added .cvsignore files 2004-07-08 18:17:31 +00:00
Antoine Fraboulet
90b1affcef *** empty log message *** 2004-04-08 09:43:06 +00:00