mirror of
https://github.com/DeNNiiInc/Connect-5.git
synced 2026-05-01 07:33:57 +00:00
Merge turn indicator with player indicator at top
- Added ID to turn label for easier updates - Updated multiplayer.js to use turnLabel ID - Reset turn label when switching modes or resetting game - Improved UX by keeping player/turn info together
This commit is contained in:
@@ -372,8 +372,9 @@ class MultiplayerClient {
|
||||
|
||||
// Update current player display to show "YOU ARE X/O"
|
||||
const currentPlayerDisplay = document.getElementById('currentPlayer');
|
||||
const turnLabel = document.getElementById('turnLabel');
|
||||
currentPlayerDisplay.textContent = this.mySymbol;
|
||||
currentPlayerDisplay.parentElement.previousElementSibling.textContent = `You are:`;
|
||||
turnLabel.textContent = `You are:`;
|
||||
|
||||
// Update player display colors based on symbol
|
||||
const playerDisplay = document.querySelector('.player-display');
|
||||
|
||||
Reference in New Issue
Block a user