Download

0 Total Downloads

6 Total Views

Asset Type Custom Scripts

File Type Unity Package

Description


This is "Boby's Planet Movement" — a custom gravity / planetary walking system for Unity + VRChat (UdonSharp).
It lets players (and rigidbodies) walk on spheres, cylinders, tubes, arbitrary colliders, etc., with the correct local “down” direction, instead of always falling toward world -Y.
Core Concept
Instead of Unity’s default Physics.gravity, every frame the system calculates a custom “up” vector based on all nearby gravity fields, then applies force in the opposite direction.
Main Scripts

PlanetMove_Gravbody.cs (attached to the player / moving object)
Requires a Rigidbody (with useGravity = false).
Every Update it:
Collects active PlanetMove_GravityField components that overlap its trigger.
Picks the highest-priority field(s).
Computes the net upDir.
Applies rb.AddForce(...) to simulate gravity toward that upDir.

Has a pool of gravity fields (default 32) for performance.

PlanetMove_GravityField (on every gravity zone)
Defines the shape and strength of gravity.
Four main types:
TypeWhat it doesTypical UseSphereGravity toward/away from a pointPlanets, spheresAxisGravity toward an infinite or capped lineTubes, cylinders, corridorsDirectionConstant direction (like normal gravity)Flat areas, directional pullColliderGravity toward the surface of any collider(s)Irregular terrainExtra options:
onlyInTrig → only affects you when inside the trigger collider.
priority → higher priority fields override lower ones.
strength (positive = pull toward center, negative = push away).
localOffset / worldOffset.

PlanetMove_GravityFieldGroup
Lets you combine multiple fields with different combine modes (not fully shown in the dump, but it’s there for advanced setups).


How You Use It (in the sample scene)

Enter the system → Interact with the big “Enter” button. This attaches the gravbody logic to the player.
Gravity Fields are placed around the map (you can see several in the hierarchy: Sphere, Axis Tube, Axis Capsule, Collider, etc.).
UI Toggles let you turn on/off:
Normal gravity fallback
Ground snapping
Comfort turning
Comments
Log in to leave a comment.

No comments yet... start a discussion to get things started... or join our discord to get help from the community.

File Tree (148 files inside Unity Package)

Recommended Items

Based on this asset

Tutorials

Join 27,000+ creators

Become a Part of the Leading VR Modeling & VRChat Network

Ready to immerse yourself in the exciting world of VRChat and 3D assets? At VRCMods, we're not just a community, we're a vibrant network of creators, innovators, and enthusiasts. Connect with fellow VRChat enthusiasts, access top-tier avatar commission services, comprehensive tutorials, and enjoy a wealth of free downloads — all with regular updates to keep you on the cutting edge.

Create a free account to skip ad checks, leave comments, heart your favorites, follow uploaders, and get notified about new uploads.