aclap-dev / joclyboard

Multiplatform 3D/2D desktop application for playing board games
Other
44 stars 20 forks source link

[International Draughts] PDN support enhancements #11

Open IgorLeMasson opened 7 years ago

IgorLeMasson commented 7 years ago

Initial wishlist for PDN support enhancements:

New tags 1.1. Add support to others 'mandatory' tags: Event, Site, Round and Result. User should have a option to add Event, Site, Round tags .

1.2. Add support to GameType tag. Currently in PJN file, the game type is written in a non-PDN tag "JoclyGame": [JoclyGame "draughts"].

1.3. Add support to TimeControl tag, according default or user-defined time settings

File extension 2.1. Export to PDN file extension could be added or replace PJN file option.

PDN Export 3.1. The export button might be available on the board window bottom toolbar, instead of only on History window bottom toolbar. On the board window, the "Save" button has only JSON format

Read/Import PDN files 4.1. It is not yet fully supported, some PDN files cannot be readed

Add support to additional tags 5.1. EventDate, EventSponsor, Section, Stage, Board

mi-g commented 7 years ago

1.*, 5.1: those tags cannot be filled automatically by Jocly, this would require specific UI and action from the user to be specified. Given this, the strategy is that the user can as well use a text editor.

2.1: can't you edit the file extension from the SaveAs dialog ? (it might be OS dependent)

3.1: the actual problem is that there are already to many options in the toolbar at the bottom of the Play window. This is the reason why the export feature has been located to the history window. We should find a way to improve the UI to prevent the list of icons to split the icons over 2 lines.

4.1: can you share some non-working PDN ? Note that because the feature is supposed to be game-agnostic, some lexical errors in the PDN cannot be auto-corrected without breaking the parsing of other games.

IgorLeMasson commented 7 years ago

1.*, 5.1: those tags cannot be filled automatically by Jocly, this would require specific UI and action from the user to be specified. Given this, the strategy is that the user can as well use a text editor.

The tags mentioned on 1.1, most of draughts softwares that have a proper PDN support allows user-input fields for these tags. PDN knowledge should be transparent to the users. as you told a GUI form to user-input is the better way to deal it.

GameType and TimeControl tags could be automatically added based on played draughts variant and TimeControl (default and user-defined)

2.1: can't you edit the file extension from the SaveAs dialog ? (it might be OS dependent)

Of course it can be done. but now the PJN file is not PDN 3.0 compliant since it has a non-PDN tag: [JoclyGame "draughts"], if it haven't been used by Jocly framework, this tag could be removed and filename extension could be changed from PJN to PDN, then the exported file would be 100% compliant with PDN 3.0. Or both export options (PJN and PDN file extensions) need co-exist.

3.1: the actual problem is that there are already to many options in the toolbar at the bottom of the Play window. This is the reason why the export feature has been located to the history window. We should find a way to improve the UI to prevent the list of icons to split the icons over 2 lines.

It would be nice, try to join all available options in same place, preferentially the bottom toolbar. Maybe reducing the number of icons?!

4.1: can you share some non-working PDN ? Note that because the feature is supposed to be game-agnostic, some lexical errors in the PDN cannot be auto-corrected without breaking the parsing of other games.

Does JoclyBoard support to load/read/import any PDN compliant file? Which PDN 3.0 tags can be readed? For test sample, please check the babasy1.pdn file into book folder in MobyDam engine last release.

mi-g commented 7 years ago

We have to make compromises between some game-specific needs and keeping the UI simple. If we want a program that is purely for draughts, the best is to change/recompile with the specifics.

Maybe reducing the number of icons? We cannot do that, those icons are there for a reason: provide access to existing features.

I tried a few modydam PDNs and all of them loaded and played without a problem. Could it be that you were trying to open the PDN from the Load button ? Instead, you must open the Game window, then button Open book. Note that in those PDN examples, none of the tags you requested are present.

IgorLeMasson commented 7 years ago

Yes, on my previous tests I have used Load button. Where are located the 'Game window' and 'Open book'?

mi-g commented 7 years ago

In the main window (the one that lists all available games), if you click a game entry (not the white triangle inside a green disk that launches a match directly), this opens the game window. This is also where you start clocked matches from.

IgorLeMasson commented 7 years ago

Ok now I see it. Should be a better way to access this option, keeps it in another window is not useful rather than board or even history window. The "Open book" name can be replaced to "Open game". The term book can mislead refering to "Opening book" concept instead of 'saved game' or 'game database'.

mi-g commented 7 years ago

I agree Open book is not good, but i believe Open game is worse. Open archive maybe ?

IgorLeMasson commented 7 years ago

Maybe 'Open saved game' ?!

mi-g commented 7 years ago

We should somehow have this notion that a PDN/PGN/PJN is a collection of games not a single one. Book might be the right word, but Open is confusing because it can be misunderstood with game opening, the first moves of a game. What about Load book ?

IgorLeMasson commented 7 years ago

Hi Michel, I guess just "Open game(s) file" is enough.

Backing to the original issue, regarding 4.1, that maybe deserves a separated issue, please check the PDN files into PDN_files_to_test.zip.

Later to enrich test coverage, I will test others PDN files to try found unexpected results.