Skip to content

Fixed star movement when dragging - #2

Merged
bkmcoding merged 1 commit into
mainfrom
dev
Oct 13, 2026
Merged

bkmcoding merged 1 commit into
mainfrom
dev

Conversation

@bkmcoding

Copy link
Copy Markdown
Owner

fixes #1

Copilot AI lite review requested due to automatic review settings October 13, 2026 20:11
@bkmcoding bkmcoding added the bug Something isn't working label Oct 13, 2026
@bkmcoding
bkmcoding merged commit 49a5fc9 into main Oct 13, 2026
1 check passed
@bkmcoding
bkmcoding deleted the dev branch October 13, 2026 20:11

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

The star layers use the wrong rotation reference and move in the wrong direction during panning.

2 open findings
What changed in this PR

This PR adds background-star movement during galaxy navigation to address issue #1.

Changes:

  • Adds two star layers with different parallax rates.
  • Updates their transforms before each frame is rendered.
File Description
web/​script.js Adds and animates parallax transforms for the background stars.

🧠 Review effort: Lite


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread web/script.js
makeStarLayer(2500, 1.5, 0.3)

function updateStarLayers() {
starInverseQuat.copy(camQuat).invert()
Comment thread web/script.js
function updateStarLayers() {
starInverseQuat.copy(camQuat).invert()
starLayers.forEach(({ points, parallax }) => {
starOffset.copy(camTarget).multiplyScalar(parallax)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Distant stars are static

2 participants