Skip to content

chore: camera follow offset and complete README - #61

Merged
theghost1980 merged 1 commit into
mainfrom
codex/adjust-camera-follow-and-update-readme
Feb 8, 2026
Merged

theghost1980 merged 1 commit into
mainfrom
codex/adjust-camera-follow-and-update-readme

Conversation

@saturnoTest

Copy link
Copy Markdown
Member

Motivation

  • Make the main camera follow the player with smoothing and a slight vertical offset so the player sits below center and the area above is more visible.
  • Keep HUD, status and background art pinned to the viewport so UI doesn't move with the camera.
  • Provide a clear README that documents gameplay, tech stack, asset layout and repo governance for contributors.

Description

  • Added CAMERA_LERP and CAMERA_OFFSET_RATIO constants and enabled camera follow with smoothing via this.cameras.main.startFollow(this.player, true, CAMERA_LERP, CAMERA_LERP) and this.cameras.main.setFollowOffset(...).
  • Set world and camera bounds with this.physics.world.setBounds(...) and this.cameras.main.setBounds(...) to avoid showing empty areas.
  • Pinned background, HUD and status UI to the camera by calling setScrollFactor(0) on baseColor, desertBackground, cloudLayer, statusText and all HUD elements so they stay fixed while the camera follows.
  • Updated README.md with gameplay (desktop/mobile controls), features, tech stack, asset structure, real package.json scripts, and a governance section describing IA+human PR workflow and asset rules.

Testing

  • Ran npm run typecheck (tsc -p tsconfig.json --noEmit) which completed without TypeScript errors (npm showed an unrelated env warning).
  • Started the dev server and executed a headless Playwright smoke script that loaded the app, confirmed the game canvas appeared and produced a screenshot (artifacts/camera-offset.png) to validate camera follow at runtime.

Codex Task

@saturnoTest
saturnoTest requested a review from a team February 8, 2026 02:03
@theghost1980
theghost1980 merged commit ac59c24 into main Feb 8, 2026
1 check passed
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