Commit Graph

119 Commits

Author SHA1 Message Date
ed9fa79a79 fix bug where chessbloc had wrong colors 2024-05-19 21:44:05 +02:00
809a459c8c fix url 2024-05-19 21:21:55 +02:00
5f526aa5d3 bump version 2024-05-19 21:19:51 +02:00
6cede55d44 Simplify flow and allow site reloads 2024-05-19 21:18:47 +02:00
c802251c9d fix url 2024-05-19 14:46:18 +02:00
e4d4b81cba flutter pub upgrade 2024-05-19 14:44:06 +02:00
d924341742 Merge pull request 'rejoinable-game' (#11) from rejoinable-game into master
Reviewed-on: #11
2024-05-19 12:41:02 +00:00
2bed5409ef flutter pub upgrade 2024-05-15 21:15:20 +02:00
544e0b22c5 Make games rejoinable
1. Disconnect websocket connection before connecting
2. store playerInfo when hosting a game to reuse it when rejoining
2024-05-15 19:44:02 +02:00
618102dd67 Merge pull request 'Fix colors and make passphrase submittable via Enter' (#10) from fix-dialog-colors into master
Reviewed-on: #10
2024-05-11 18:01:25 +00:00
32caf86f7f Fix colors and make passphrase submittable via Enter
With this change, the lobby selector gets its dark background back.
Also, now the passphrase can be submitted by pressing Enter and not only
by clicking the 'check' icon.
2024-05-11 19:58:29 +02:00
67a4be17cd bump version 2024-05-09 22:48:15 +02:00
fb42a05f72 flutter upgrade & flutter pub upgrade 2024-05-09 22:45:20 +02:00
ebab1a4c46 upgrade dependencies 2024-03-11 02:05:32 +01:00
320dd247ff Bump version 2024-02-05 10:51:56 +01:00
fd51e582af Merge pull request 'Fix snackbar in host/join dialog' (#9) from fix-dialog-snackbar into master
Reviewed-on: #9
2024-02-05 10:48:30 +01:00
9f64959498 Revert erroneous refactor 2024-02-05 10:39:01 +01:00
ba478fedca Fix snackbar in host/join dialog 2024-02-05 10:35:28 +01:00
93a84d442e bump version 2024-02-01 11:43:49 +01:00
33e79a90c9 Merge pull request 'Fix tapping on opponent's piece' (#8) from fix-tap-on-drag into master
Reviewed-on: #8
2024-02-01 11:42:18 +01:00
200393ac76 Fix tapping on opponent's piece
With the previous change of starting a tap on a drag,
we removed the GestureDetector from all squares with any pieces.

This included the opponent's pieces. Tapping and taking an opponent's
piece was not possible anymore.

This was a bug, since we still want to detect a tap and take an opponent's piece.
2024-02-01 11:37:00 +01:00
e22dc213ac Bump version 2024-02-01 11:22:25 +01:00
ecca9f07c3 Merge pull request 'Start a tap with drag' (#7) from drag-starts-tap into master
Reviewed-on: #7
2024-02-01 11:19:57 +01:00
8fd01eed1e Remove conditional_wrap 2024-02-01 11:18:58 +01:00
6882505174 Start a tap with drag
Now, only the empty squares contain a GestureDetector.
The GestureDetector is not necessary anymore in squares with pieces
because the tap is started when the drag is started.
2024-02-01 11:11:11 +01:00
c9381aaa4c Merge pull request 'Introduce checkmate screen' (#6) from checkmate-screen into master
Reviewed-on: #6
2024-01-18 17:03:30 +01:00
13bcfb1131 Introduce checkmate screen
Show checkmate screen, once the server sends the 'gameEnded' message.

Additionally, show an icon that lets users copy the passphrase to the
clipboard.
2024-01-18 16:59:33 +01:00
7d55a0e123 Merge pull request 'Implement moves by tapping the squares' (#5) from move-by-tap into master
Reviewed-on: #5
2024-01-17 20:59:31 +01:00
212a54612c Implement moves by tapping the squares
This adds an option to dragging-and-dropping which is slightly hard on
smaller screens.

Fix promotions when tapping and fix handling of subsequently tapping two pieces of your color

Cancel tap if a drag is started (tapped square will not stay red in case a drag is started)

Change url strategy back to the hashtag thing

Change version

Fix bug that would not allow a piece move if you tried to take an opponents piece.

Fix the coloring of the last move after an invalid move was played.

Upgrading deps
2024-01-17 20:58:13 +01:00
dfd9f09ee6 Update pubspec 2024-01-05 22:58:05 +01:00
cb8e98ef81 Fix building of web and linux app at the same time 2023-12-27 15:57:01 +01:00
2fe77063d9 Merge pull request 'Fix routing again' (#4) from fix-routing-again into master
Reviewed-on: #4
2023-12-27 15:49:04 +01:00
cdc0144e39 Fix routing again 2023-12-27 15:46:15 +01:00
289ec6db26 Fix turnColor handling 2023-12-25 18:08:21 +01:00
ba947ae5e4 Fix routing and move handling 2023-12-25 17:50:58 +01:00
17ac437f5b Pop promotion dialog with context.pop() 2023-12-25 02:07:03 +01:00
abf322572d Merge pull request 'Make passphrase entry a dialog instead of a page.' (#3) from store-lobby-id-and-player-id into master
Reviewed-on: #3
2023-12-23 16:47:07 +01:00
7a51e71767 Make passphrase entry a dialog instead of a page.
Additionally, we set some groundwork for storing the game data (lobby
id, player id, passphrase) in permanent storage in order to reconnect
with it later.
2023-12-23 16:44:23 +01:00
4a9047fd67 Merge pull request 'Handle board status message' (#2) from handle-status-reconnects into master
Reviewed-on: #2
2023-12-09 20:51:15 +01:00
8f4cd2266f Handle board status message
This is another step to allow reconnecting after connection loss or
browser closing.

When the game is left with the X button on the bottom right, we will
close the websocket connection, to let the server know, that we are
gone.

The server still has issues that prevent this from working flawlessly.

Remove unused import
2023-12-09 20:48:36 +01:00
e441aaec1e pub ugrade 2023-11-27 00:20:02 +01:00
130a2dae79 Make ChessSquare a stateful widget. 2023-09-04 21:52:40 +02:00
01dcc74cfc Refactor chess square and prepare display of square in check. 2023-09-04 21:39:51 +02:00
102c0de20d Merge pull request 'Fix green flicker of squares on invalid move' (#1) from fix-green-square-flicker into master
Reviewed-on: #1
2023-08-25 10:39:08 +00:00
f45ec47285 Fix green flicker of squares on invalid move 2023-08-25 12:28:58 +02:00
b9d574f2ab Fix 1-pixel lines between squares
In window widths or heigths that are not divisible by 8, the chess board
would contain lines between the squares (since the contraints of the
chess board rows would contain non-integer constraints).

With this commit, we calculate margins manually, in order to constrict
the chess board to widths and heights that are divisible by 8.
2023-08-22 04:24:30 +02:00
7c5439a635 Display last played move.
We now color the squares of the last move. This makes the state of the
board clearer and shows whose turn it is.
2023-08-19 03:45:03 +02:00
80fe378241 Remove unused function. 2023-08-15 00:47:08 +02:00
43d8d77abc Fix the current position in ChessPositionManager, now that we rely on position instead of detecting en passant ourselves. 2023-08-15 00:39:10 +02:00
c213d9b1f3 Use position to build board
Now the client considers the position sent by the server to build the
position on the board.
2023-08-14 17:04:25 +02:00