Bug 12342 - Miniature can't play chess
: Miniature can't play chess
Status: CLOSED FIXED
Product: Miniature
General
: master
: other other
: High blocker (vote)
: 0.4
Assigned To: Michael Hasselmann
: general
:
:
: 12344 12357 12364 12365 12382
:
  Show dependency tree
 
Reported: 2011-08-25 00:46 UTC by Quim Gil
Modified: 2011-09-18 07:54 UTC (History)
1 user (show)

See Also:


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description Quim Gil (reporter) 2011-08-25 00:46:49 UTC
SOFTWARE VERSION: 
0.3 in N9

Obvious bug: Miniature should play online games at FICS and it doesn't.

Let's also use this report as metabug for related issues e.g. lack of pawn
promotion UI.
Comment 1 Quim Gil (reporter) 2011-08-25 00:47:52 UTC
Assigning
Comment 2 Michael Hasselmann 2011-08-26 04:57:47 UTC
Played my first match on FICS, using Miniature. Admittedly, it was against
myself, but still!
Comment 3 Michael Hasselmann 2011-08-27 03:05:46 UTC
Playing on FICS requires user to disable test mode in main screen (test mode
enabled by default). Going to list what I noticed so far, from the top of my
head (using a summary here instead of reporting bug for each issue, for now).

WHAT WORKS:
- Login to FICS as guest.
- Respond to game ads.
- Chessboard orientation.
- Seeing moves from FICS.
- Making simple moves with Miniature.
- Only pieces of own side can be selected and moved, and only when it is the
user's turn.

WHAT NEEDS FIXING:
- Sending out game ads. Otherwise, it will not be possible to pair two
Miniature clients.
- Move validation, or at least: handle FICS response when invalid move was
submitted. Currently, Miniature will get stuck when confirming invalid move.
- Logout when returning to main screen.
- Chat. Important when playing to strangers and no other way of communication
is possible but via FICS.
- Handling game offers, at least resign, abort.
- Give visual feedback on selected piece, selected target. Currently, move is
executed immediately, but perhaps it is really better to just highlight target
square instead, and only move on confirmation. Could simplify code even.
Comment 4 Quim Gil (reporter) 2011-08-27 03:22:06 UTC
There is a separate bug for chat and it's not scheduled for 0.4. Let's continue
the discussion about chatting there.

About visual feedback I'm expecting the same behavior as in 0.3, which was
clear and has been praised by whoever I got to play that version.

Creating a new seek could be a separate bug and we can discuss there whether it
belongs to 0.4 or not. The UI is in place, for what I'm aware of.
Comment 5 Michael Hasselmann 2011-08-27 21:24:44 UTC
Fixed "Give visual feedback on selected piece." - it is now as in v0.3, only
with the backend handling the state. The frontend only needs a simple
miniature.selectSquare(index) and evaluate the returned boolean for the red
flash. This opens the door for backend move validation.
Comment 6 Michael Hasselmann 2011-08-28 04:20:10 UTC
Fixed "Sending out game ads."
Comment 7 Quim Gil (reporter) 2011-08-28 11:26:36 UTC
(In reply to comment #6)
> Fixed "Sending out game ads."

Great! Looking at the code it seems that is a real seek what it's sent
regardless of whether Miniature is in test mode or not, right?

Ok, I'll get the UI to show your open seek(s? I guess you can send as many?).
After fixing the colors in OnlineBoard. I guess we have a way to cancel open
seeks, right?
Comment 8 Quim Gil (reporter) 2011-08-28 11:59:38 UTC
Black/white colors fixed in OnlineBoard
https://gitorious.org/miniature/miniature/commit/b565df6d1d61997334eda51a08cf95bdc0b37384
Comment 9 Quim Gil (reporter) 2011-08-29 17:29:46 UTC
v0.3 UI had the rating of the remote and local sides at the left of their IDs,
like this: 

$rating + " " + $id

I have tried to fix this myself but looking at game/frontend/sideelement.cc &
.h it's not clear to me whether this variable already exists somewhere else and
how can I pull it to OnlineBoard.qml. "Real" Qt is still hard to me, sorry.
Comment 10 Michael Hasselmann 2011-08-29 17:35:05 UTC
Rating property not exported yet. There's some cleanup work required.
Comment 11 Quim Gil (reporter) 2011-08-30 00:42:26 UTC
(In reply to comment #3)
> WHAT NEEDS FIXING:
> - Sending out game ads. Otherwise, it will not be possible to pair two
> Miniature clients.

This belongs now to Bug 12358 and is not a blocker for 0.4.
Comment 12 Michael Hasselmann 2011-09-05 23:54:34 UTC
Logout and move validation is done, leaves us with chat and game offers such as
resign and abort.
Comment 13 Quim Gil (reporter) 2011-09-06 01:52:07 UTC
(In reply to comment #12)
> Logout and move validation is done, leaves us with chat and game offers such as
> resign and abort.

And Bug 12365 - Promotion does not work
Comment 14 Michael Hasselmann 2011-09-13 21:14:02 UTC
All dependencies closed, thus resolving metabug.
Comment 15 Quim Gil (reporter) 2011-09-13 21:48:10 UTC
Verifying. Miniature does play chess properly.

We are still having some problems announcing the end of the game to the user,
but this doesn't affect the ability to play or the result of the game. End
games related issues are discussed further on Bug 12382 - Miniature doesn't
handle end games - and related bugs.