Repository navigation
Custom controls API, Minimap and RaycasterProvider - #58
Merged
Merged
Conversation
- `player` value changes move and rotate the player without resetting
the game, positions in walls or open areas are ignored with a warning
- `controls={false}` disables the built-in keyboard and mouse controls,
to use the component as a renderer only
- Document the renderer-only usage and `openDoor`
Closes #49
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Second example page where the parent component handles movements, collisions and inputs, with a clickable minimap to teleport - Share the tiles between both demo pages, link them together - Build both pages for GitHub Pages Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- move, turn, look, interact and getPlayer in the game context, the joystick methods are deprecated - onPlayerChange, with reported positions ignored when they come back through the player prop - RaycasterProvider and useRaycaster to use the game outside of the Raycaster children - Minimap component with clickable cells - lockPointer with raw mouse input, fixes camera jumps - isFormKey: keyboard controls ignore keys typed in form fields and Space/Enter on focused buttons, links and checkboxes - Render only demo becomes the custom controls demo Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The named exports made require("react-raycaster") return the module
object instead of the component. The named exports and default are now
properties of the component in the CommonJS build.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #49
Added
controls={false}to disable the built-in keyboard and mouse controlsmove,turn,look,interactandgetPlayerin the game context (joystickMove/joystickCameradeprecated)onPlayerChange, with reported positions ignored when they come back throughplayerRaycasterProvider+useRaycaster()to use the game outside of theRaycasterchildrenMinimapcomponent with clickable cellslockPointer(element)andisFormKey(event)helpers for custom controlsFixed
See the CHANGELOG for details.
🤖 Generated with Claude Code