Skip to content

Conversation

@rjcorwin
Copy link
Owner

Summary

  • add a Phaser-powered isometric multiplayer client with Electron shell and movement stream helpers
  • expose the new game APIs from the client package and adjust compiler options/dependencies for browser support
  • add an isometric-fleet space template and changelog entry covering the four-human/four-agent setup with ship decks

Testing

  • npm run build

https://chatgpt.com/codex/tasks/task_e_68ebba5604b08325a113d63b1e0b6a39

cursor[bot]

This comment was marked as outdated.

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting

Comment on lines +332 to +340
const players: PlayerState[] = Array.from(this.players.values()).map((entity) => ({
...entity.state,
tileX: entity.state.tileX,
tileY: entity.state.tileY
}));
const ships: ShipState[] = Array.from(this.ships.values()).map((ship) => ({
...ship.state,
passengers: new Set(ship.state.passengers)
}));

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Serialize ship passenger sets to JSON-safe data

Snapshots broadcast to other clients include ShipState.passengers as a Set. When sendSnapshot stringifies the snapshot, each Set serializes to {}. Receivers apply that payload back into ShipEntity, so ship.state.passengers becomes a plain object; the next time the local scene executes ship.state.passengers.add(...) (e.g. when a player boards a ship) a TypeError is thrown and passenger membership stops updating. Converting the set to an array before sending and rebuilding a Set when reading would keep snapshots round‑trippable and avoid runtime crashes whenever a snapshot arrives.

Useful? React with 👍 / 👎.

cursor[bot]

This comment was marked as outdated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants