Third-person orbit camera with collision pull-in
In your harnessGodot componentMIT
Orbit a Camera3D around a target with yaw, pitch and zoom limits, smooth distance changes and a ray that pulls the camera in front of walls so the target stays visible.
ATTRIBUTION.mdLICENSEREADME.mdbaltor_test.gdcomponent.jsoninspect_gdscript.pyorbit_camera_3d.gdrun_tests.gdtest_package.pytests/test_orbit_camera_3d.gdverification/native.json
Full files in your harness.
What it takes and gives
- Class
- BaltorOrbitCamera3D, extends Camera3D
- Methods
- orbit_offset(yaw: float, pitch: float, length: float) -> Vector3; orbit(delta_yaw_degrees: float, delta_pitch_degrees: float) -> void; zoom(amount: float) -> void; get_target() -> Node3D; get_pivot() -> Vector3; get_current_distance() -> float; update_camera(delta: float) -> void
- Exports
- target_path, target_offset, yaw_degrees, pitch_degrees, distance, min_distance, max_distance, min_pitch_degrees and 8 more
- Placement
- res://baltor/godot_components/orbit_camera_3d/
Limits. One ray from the pivot; thin gaps can still let the near plane clip into walls, so keep collision_margin above the camera's near distance. No auto-rotation behind the target and no lock-on. Verified with Godot 4.7.2 headless; written against the Godot 4.3 API.
Details
- Kind
- Godot component
- Engine
- Godot 4.3 or later
- Files
- 11 files, 79.3 KB
- Licence
- MIT
- Declared effects
- reads files, runs commands
- Checked with
- Godot 4.7.2, headless
- Checks
- godot parse check only, godot gdscript tests, godot tests reject gutted component, godot editor import, godot contract reflection, godot readme usage compiles
- Techniques
- spherical orbit coordinates, exponential smoothing, raycast camera collision
- Tags
- camera, third person, orbit, camera3d, collision, zoom
- Identity
library.supply.creative_originals.01de4ce77899e452944584bc.17c36c78892f6a06- Version
17c36c78892f6a06872ef451b42a0b131393cd9554331c8134a886e63b7b5693
The version is the SHA-256 of the item your harness downloads; every file in it names its own checksum.
Something wrong with this item, its rights or its safety? Report it on the support page, or from your harness after a download.