How nekzisis/platformer works
This is a browser-based platform game: the browser starts a fixed-step game loop, which updates the player and camera and renders the scene to canvases. Keyboard input drives platforming movement and collision against a generated world; settings can pause and resume gameplay. The graph follows the sampled JavaScript and file tree. The README is empty, so capabilities beyond those visible in source are not inferred.
Main entry points: game.js Game coordinator · main.js Canvas setup · Player.js Player movement · settings-main.js Settings controls
Components 11
Game runtime
- Canvas setup
scripts/main.js - Game loop
scripts/main.js - Game coordinator
scripts/game.js
World and rendering
- World geometry
scripts/game.js - Player movement
scripts/Player.js - Background cache
scripts/Background.js - Camera and viewport
scripts/game.js
Controls and settings
- Keyboard input
scripts/InputHandler.js - Settings controls
scripts/settings-main.js
Other components
- Browser
- Game page
index.html
Connections 13
- Browser → Canvas setup: starts
scripts/main.js - Canvas setup → Game page: gets canvases
scripts/main.js - Canvas setup → Game coordinator: creates
scripts/main.js - Game loop → Game coordinator: updates
scripts/main.js - Game loop → Game coordinator: renders
scripts/main.js - Game coordinator → World geometry: creates geometry
scripts/game.js - Game coordinator → Player movement: updates and draws
scripts/game.js - Game coordinator → Background cache: creates and draws
scripts/game.js - Game coordinator → Camera and viewport: tracks player
scripts/game.js - Player movement → Keyboard input: reads controls
scripts/Player.js - Player movement → World geometry: checks collisions
scripts/Player.js - Settings controls → Game loop: dispatches pause events
scripts/settings-main.js - Browser → Settings controls: accepts settings input
scripts/settings-main.js