Checkers-Drafts Game: Publish Game to Azure plus additional features
March 07, 2026 00:20
David Jones MVP
ai
drafts
checkers
blazor
07 Mar 2026 00:20:37
David Jones MVP
ai drafts checkers blazor
ai drafts checkers blazor
Publish the game to Azure and add further features included timeout, highlight last move, end game features and Chat and Lobby.
Goal
- Continue UI polish and diagnostics for the Drafts Blazor app:
- Tidy UI (button styling, piece rendering).
- Fix input/event diagnostics so board clicks register.
- Improve multiplayer join workflow and diagnostics for LAN testing.
- Provide guidance for Git and Copilot history troubleshooting.
- Publish to Azure
Commits
- V1.2.0 Added Chat and Admin sets who goes first
- V1.4.0 Game times out after a period and is killed. Player can see name of iniator when selecting
- An Update
- First deployment to Azure, V1.4.0 checkers (To be deleted)
- End of Game features added. Also Admin mode game play.
- V2.0.0 End of Game Features to
- V2.1.0 Some end game bug fixes. All good.
- Moved piece is highlighted and Admin can set the highlight color
- Ignore the db in the repository. Is recreated on a new site V2.3.0s
- V2.4.1: Added Lobby Chat, not in game
- New deployment to Azure, V2.4.1 to djscheckersappsvc
Summary of Work Completed
- Created a readable session notes template and populated it with the day’s outcomes.
- Implemented non‑intrusive UI changes (CSS guidance) to make global buttons static and accessible.
- Changed piece rendering approach to filled circular pieces sized to 75% of a cell (36px for a 48px cell), with white pieces having a dark border and kings showing a crown symbol.
- Added “Copy join link” and “Open in new window” helpers to the drafts page for easier join flow.
- Fixed double-join race by ensuring navigation triggers the join in the newly loaded component instance only.
- Made click handling robust: attached handlers to both
tdand inner wrapper and added client‑side console logging (temporary diagnostic script) to confirm clicks reach the browser. - Added server‑side logging in
DraftsServiceto trace CreateGame / TryJoinGame / MakeMove operations. - Documented how to run git commands from Visual Studio Terminal and produced
commits_to_edefb18.txt(initial commit summary). - Provided instructions for testing LAN connectivity and Kestrel binding changes for listening on non‑localhost addresses.
Files Changed / Added (high level)
Components/DraftsGame.razor— improved click handling, join helpers, piece visuals, and diagnostics.Services/DraftsService.cs— added logging, made event invoker internal, improved move logic and promotions.wwwroot/css/site.css(suggested) — global button styles (static/rainbow‑like, accessible).- Diagnostics script snippet added to
DraftsGame.razortemporarily to log client clicks to browser console. commits_to_edefb18.txt— produced with a compact commit list through Git.
Key Implementation Notes
UI / Styling
- Buttons: static multi‑stop gradient matched to board palette with a purple bold label for contrast. CSS uses custom properties to allow inline overrides.
- Pieces: rendered as circular elements sized to 75% of a board cell. White pieces are filled white with a dark border; kings display a crown glyph.
- Avoided animations for global “rainbow” styling to satisfy accessibility/consistency requests.
Input & Events
- Previously clicks on the piece did not invoke the server handler; resolved by:
- Ensuring event handler attached to clickable container elements (both
tdand inner wrapper). - Changing handlers to async
Tasksignatures (recommended in Blazor). - Adding temporary client console logging so you can confirm browser-side click delivery before blaming SignalR.
- Ensuring event handler attached to clickable container elements (both
Networking / Multiplayer
- Prevented the same browser/process from occupying both player slots by not calling
BeginJoinbefore navigation finishes. - Guidance provided to run Kestrel listening on any IP for LAN testing:
- Quick test:
dotnet run --urls "http://0.0.0.0:5000"and openhttp://<host-ip>:5000. - Firewall: add an inbound rule for port 5000 on Windows during testing.
- HTTPS over LAN requires certificate binding and is more complex — recommended to test over HTTP for local development.
- Quick test:
Diagnostics & Logging
DraftsServiceusesILoggerto record CreateGame, GetGame, TryJoinGame and MakeMove events — useful for debugging join failures and move rejections.- Added transient client script logging to verify clicks reach the browser (remove after debugging).
Testing Checklist
- Clicks on board squares log to browser console.
- Selecting a piece shows “Selected r,c” message on UI.
- Valid move paths accepted; invalid moves show rejection reason.
- Creating a game in Window A and opening the join link in a second window results in Player 2 joining (use incognito/private window to avoid session reuse).
- Server logs show
TryJoinGameassignment for Player1 and Player2. - LAN test: access
http://<host-ip>:5000from another device after starting Kestrel with--urls "http://0.0.0.0:5000"and opening firewall rule.
Next Steps
- Remove temporary client-side click-logging script once events are verified.
- Replace crown glyphs with SVG icons for sharper scaling if desired.
- Add visual selection highlight to the selected square and simple move animation.
- Enhance rules: implement forced multi-jump chaining and full king movement if required.
- Add persistent storage for game state or option to export/import games.
- Produce a concise
CHANGELOG.mdentry and tagedefb18asv1.0.0if you want to formalize the release.
Notes / References
- Midpoint color between
#7B5E3Band#EEE8D5calculated RGB ≈ (181,163,136), hex#B5A388. - To list commits up to
edefb18from the repo root:- PowerShell (inside VS Terminal):
git rev-list --reverse edefb18 | ForEach-Object { git show -s --format='%h %ad %an %s' --date=short $_ } > commits_to_edefb18.txt
- PowerShell (inside VS Terminal):
- To view history inside Visual Studio:
View > Git Repository→ select branch → History view.
Comments
| Topic | Subtopic | |
| This Category Links | ||
| Category: | Artificial Intelligence Index: | Artificial Intelligence |
| Next: > | Checkers-Drafts Game | Entrapment Game End and Multi-Jumps |
| < Prev: | Checkers-Drafts Game | Creation of Drafts-Checkers Game in Blazor with LAN multiplayer suppor |