Skip to content

[WIP] Add option for two players in the menu - #3

Draft
leereilly with Copilot wants to merge 2 commits into
mainfrom
copilot/add-two-player-option
Draft

[WIP] Add option for two players in the menu#3
leereilly with Copilot wants to merge 2 commits into
mainfrom
copilot/add-two-player-option

Conversation

Copilot AI commented Apr 25, 2026

Copy link
Copy Markdown
Contributor
  • Add twoPlayer flag and P2 state fields to resetGameState()
  • Update getCharOrder() to handle 2P mode (P2 is truck index 1, not AI)
  • Add "2 PLAYERS" menu item to MainMenuScene + update _select() + update controls panel
  • Update PlayerSelectScene to support simultaneous character selection for P2 (WASD/ZQSD + F to confirm)
  • Update RaceScene:
    • Mark truck[1] as isP2 in 2P mode
    • Set up P2 keyboard (W/Z, A/Q, S, D, F)
    • Add drivePlayer2() method using P2 keys
    • Camera follow midpoint of P1+P2 on big tracks
    • checkPks() updates P2 money/nitros
    • HUD shows P2 nitro
    • End race waits for both players
    • endRace() saves P2 prize and stats
  • Update ResultsScene to mark P1 and P2 in results
  • Update ShopScene for simultaneous 2P upgrade selection (P1: 1-5+ENTER, P2: 6-0+F)
Original prompt

Add an option for 2 players in the menu. Player two controls are WASD or ZQSD AZERTY keyboard folks. F is the Nitro button. At the end of the race, they can both choose their upgrades at the same time.

Created from Copilot CLI via the copilot delegate command.

Agent-Logs-Url: https://github.com/leereilly/micro-machines/sessions/a30e98be-1cd5-4a5c-bcb3-8c5574848dab

Co-authored-by: leereilly <121322+leereilly@users.noreply.github.com>
Copilot AI requested a review from leereilly April 26, 2026 00:07
Copilot stopped work on behalf of leereilly due to an error April 26, 2026 00:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants