物理组件
下面每个字段都由引擎自身的组件注册表推导而来——就是编辑器 Details 面板读的那一份——
所以这里的类型和默认值就是你添加组件时真正拿到的值,且不可能与代码脱节。讲怎么用的正文在
每条目所链接的指南里。字段说明取自 C++ ES_PROPERTY 处的原文,因此为英文。
BoxCollider2D
A rectangular collision shape. Sizes are in **metres**, not pixels.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
halfExtents | Vec2 | (0.5, 0.5) | |
offset | Vec2 | (0, 0) | |
radius | number | 0.05 | |
density | number | 1 | |
friction | number | 0.3 | |
restitution | number | 0 | |
isSensor | boolean | false | |
enabled | boolean | true | |
categoryBits | number | 1 | |
maskBits | number | 65535 |
BoxCollider3D
A box collision shape in 3D. Half-extents are in world units.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
halfExtents | Vec3 | (50, 50, 50) | |
center | Vec3 | (0, 0, 0) | |
friction | number | 0.3 | Range ≥ 0. |
restitution | number | 0 | Range 0–1. |
isSensor | boolean | false | |
enabled | boolean | true |
Breakable
A thing that breaks: drawn whole until `broken` is raised, then its pieces, cut beforehand, are put where it stood and thrown out from where it was struck.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
pieces | Asset<prefab> | none | The prefab of its pieces: a model with a fracture step writes one beside its mesh. |
broken | boolean | false | Raise to break it, lower to make it whole again. |
burst | number | 300 | How fast the pieces leave, in world units a second, out from Origin. 0 lets them fall where they are. Range ≥ 0, step 10. |
origin | Vec3 | (0, 0, 0) | Where it is struck, from its own origin: the pieces fly away from here. |
lifetime | number | 0 | Seconds the pieces last before they are taken away. 0 keeps them. Range ≥ 0, step 0.5. |
breakImpulse | number | 0 | A hit at least this hard breaks it: speed times mass, kg by world units a second (1 kg at 10 m/s is 1000 at 100 units to the metre). It needs a collider to be hit. 0 breaks it only when Broken is raised. Range ≥ 0, step 50. |
enabled | boolean | true |
CapsuleCollider2D
A capsule collision shape — the usual choice for a character body.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
radius | number | 0.25 | |
halfHeight | number | 0.5 | |
offset | Vec2 | (0, 0) | |
density | number | 1 | |
friction | number | 0.3 | |
restitution | number | 0 | |
isSensor | boolean | false | |
enabled | boolean | true | |
categoryBits | number | 1 | |
maskBits | number | 65535 |
CapsuleCollider3D
An upright capsule — what a 3D character is. Total height is 2*(halfHeight + radius).
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
radius | number | 30 | Range ≥ 0. |
halfHeight | number | 50 | Range ≥ 0. |
center | Vec3 | (0, 0, 0) | |
friction | number | 0.3 | Range ≥ 0. |
restitution | number | 0 | Range 0–1. |
isSensor | boolean | false | |
enabled | boolean | true |
ChainCollider2D
A polyline of edges — open or looped — for static terrain.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
points | Vec2[] | [{"x":-1,"y":0},{"x":0,"y":0.5},{"x":1,"y":0},{"x":0,"y":-0.5}] | |
isLoop | boolean | true | |
friction | number | 0.6 | |
restitution | number | 0 | |
categoryBits | number | 1 | |
maskBits | number | 65535 | |
enabled | boolean | true |
CharacterController2D
Kinematic character movement that slides along walls, climbs slopes and reports ground contact.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
velocity | Vec2 | (0, 0) | |
up | Vec2 | (0, 1) | |
floorMaxAngle | number | 0.7854 | Max walkable slope from up (radians) Range 0–1.5708, step 0.01. |
maxSlides | number | 4 | Range 1–8, step 1. |
skinWidth | number | 1 | Range ≥ 0, step 0.25. |
snapLength | number | 0 | Floor-snap probe length; 0 disables stair/slope stick Range ≥ 0, step 0.5. |
slideOnCeiling | boolean | true | |
maskBits | number | 65535 | |
stepHeight | number | 0 | The highest ledge it walks up without jumping; 0 = only what its rounded foot rides over Range ≥ 0, step 1. |
stopOnSlope | boolean | true | Stand still on a walkable slope, and walk it without gravity slowing or speeding it |
constantSlopeSpeed | boolean | false | Keep the speed asked for along a slope, rather than the speed across the ground |
blockSteepSlopes | boolean | true | A slope past the walkable angle is a wall to walk into. Off, it walks straight up |
followPlatform | boolean | true | Move with what it stands on |
dynamicBodies | enum | Block | How it meets dynamic bodies One of Block, Push, Ignore. |
pushForce | number | 40 | The most force it pushes with Range ≥ 0. |
dropThrough | boolean | false | Pass through one-way platforms while on |
isOnFloor | boolean | false | |
isOnWall | boolean | false | |
isOnCeiling | boolean | false | |
floorNormal | Vec2 | (0, 0) | |
realVelocity | Vec2 | (0, 0) | |
floorEntity | Entity | none | |
floorVelocity | Vec2 | (0, 0) |
CharacterController3D
A kinematic 3D mover: swept against the world, climbs steps, stays glued to slopes, and reports the ground it is on.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
velocity | Vec3 | (0, 0, 0) | |
radius | number | 30 | Range ≥ 0. |
halfHeight | number | 50 | Range ≥ 0. |
maxSlope | number | 0.87 | Steepest ground it can stand on Range 0–1.5708, step 0.01. |
layer | number | 0 | Range 0–15, step 1. |
stepHeight | number | 40 | Range ≥ 0, step 0.05. |
snapDown | number | 50 | Range ≥ 0, step 0.05. |
mass | number | 70 | Range ≥ 0. |
pushForce | number | 5000 | How hard it can shove what it walks into Range ≥ 0. |
enabled | boolean | true | |
isOnFloor | boolean | false | |
floorNormal | Vec3 | (0, 0, 0) | |
realVelocity | Vec3 | (0, 0, 0) |
CircleCollider2D
A circular collision shape. Radius is in **metres**.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
radius | number | 0.5 | |
offset | Vec2 | (0, 0) | |
density | number | 1 | |
friction | number | 0.3 | |
restitution | number | 0 | |
isSensor | boolean | false | |
enabled | boolean | true | |
categoryBits | number | 1 | |
maskBits | number | 65535 |
CompoundCollider3D
Boxes, spheres and capsules with local positions and rotations, combined into one native rigid body using the model placement scale.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
parts | array | empty | |
friction | number | 0.3 | |
restitution | number | 0 | |
isSensor | boolean | false | |
mass | number | 1 | |
enabled | boolean | true |
ConvexCollider3D
Collides against the convex hull of an imported mesh — the shape a solver can push, unlike a mesh collider.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
mesh | Asset<mesh> | none | Geometry (.esmesh) whose convex hull collides. |
friction | number | 0.3 | Range ≥ 0. |
restitution | number | 0 | Range 0–1. |
isSensor | boolean | false | |
enabled | boolean | true |
DistanceJoint2D
Holds two bodies a fixed (or spring-limited) distance apart.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchorA | Vec2 | (0, 0) | Where the joint attaches on the connected body, in that body's frame (pixels). |
anchorB | Vec2 | (0, 0) | Where it attaches on this entity, in its own frame (pixels). |
length | number | 1 | |
enableSpring | boolean | false | |
hertz | number | 1 | |
dampingRatio | number | 0.5 | |
enableLimit | boolean | false | |
minLength | number | 0.5 | |
maxLength | number | 2 | |
enableMotor | boolean | false | |
maxMotorForce | number | 0 | |
motorSpeed | number | 0 | |
collideConnected | boolean | false | |
enabled | boolean | true |
DistanceJoint3D
Keeps two 3D bodies a distance apart: a rope, a rod, or a spring when a frequency is given.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchor | Vec3 | (0, 0, 0) | |
connectedAnchor | Vec3 | (0, 0, 0) | |
minLength | number | 0 | |
maxLength | number | 100 | |
frequency | number | 0 | |
damping | number | 0.5 | |
collideConnected | boolean | false | |
enabled | boolean | true | |
breakForce | number | 0 | |
breakTorque | number | 0 |
FirstPersonController
Looks, walks, jumps and crouches in a CharacterController3D from the keyboard, the pointer and the touch screen, through a camera on a child.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
moveSpeed | number | 320 | Range ≥ 0. |
sprintMultiplier | number | 1.6 | Range ≥ 1, step 0.05. |
crouchMultiplier | number | 0.5 | Range 0–1, step 0.05. |
acceleration | number | 2400 | Range ≥ 0. |
deceleration | number | 3200 | Range ≥ 0. |
airControl | number | 0.3 | Range 0–1, step 0.05. |
jumpSpeed | number | 420 | Upward speed a jump starts with. 0 = cannot jump. Range ≥ 0. |
gravityScale | number | 1 | The player's gravity as a share of the world's. Above 1 falls faster and jumps feel snappier. Range ≥ 0, step 0.05. |
coyoteTime | number | 0.1 | How long after walking off an edge a jump still works. Range ≥ 0, step 0.01. |
jumpBuffer | number | 0.12 | How long a jump pressed just before landing is kept. Range ≥ 0, step 0.01. |
lookSensitivity | number | 0.12 | Range ≥ 0, step 0.01. |
touchSensitivity | number | 0.2 | Range ≥ 0, step 0.01. |
pitchMin | number | -85 | Range -90–0. |
pitchMax | number | 85 | Range 0–90. |
eyeHeight | number | 70 | Where the eye is above the character's centre when standing. |
crouchEyeHeight | number | 28 | |
crouchHalfHeight | number | 45 | The capsule's half height when crouched. The standing one is the character controller's own. Range ≥ 1. |
eyeSpeed | number | 400 | Range ≥ 0. |
camera | Entity | none | The camera that looks, under this entity. Empty is the first child that carries one. |
pointerLock | boolean | true | Take the pointer for looking once the player clicks, instead of looking while a button is held. |
touchLook | boolean | true | Look by dragging a finger on the right of the screen. |
touchLookFrom | number | 480 | How far across the screen, in pixels, a finger must start to look. The left is left for a stick. Range ≥ 0. |
enabled | boolean | true | |
yaw | number | 0 | |
pitch | number | 0 | |
crouching | boolean | false | Read-only — the engine computes it. |
standHalfHeight | number | 0 | Read-only — the engine computes it. |
eye | number | -1 | Read-only — the engine computes it. |
rebuild | number | 0 | Read-only — the engine computes it. |
airTime | number | 0 | Read-only — the engine computes it. |
jumpHeld | number | 0 | Read-only — the engine computes it. |
jumped | boolean | false | Read-only — the engine computes it. |
FirstPersonViewModel
On the player's camera: draws what is held with a second camera over the world's, with its own field of view and near plane, so it does not go through walls.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
layer | number | 20 | The sorting layer the held thing is on: put it on its renderers, under this camera. Range 0–31. |
fov | number | 60 | The held thing's own field of view, so it does not stretch with a wide view of the world. Range 1–170. |
nearPlane | number | 1 | How close it may come before it is cut, so it can be held against a wall without going through it. Range ≥ 0.01. |
farPlane | number | 1000 | Range ≥ 1. |
FixedJoint2D
Locks two bodies rigidly together, with optional spring give.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchorA | Vec2 | (0, 0) | Where the joint attaches on the connected body, in that body's frame (pixels). |
anchorB | Vec2 | (0, 0) | Where it attaches on this entity, in its own frame (pixels). |
linearHertz | number | 0 | |
angularHertz | number | 0 | |
linearDampingRatio | number | 1 | |
angularDampingRatio | number | 1 | |
collideConnected | boolean | false | |
enabled | boolean | true |
FixedJoint3D
Locks two 3D bodies together in the pose they were placed in — no freedom at all.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
collideConnected | boolean | false | |
enabled | boolean | true | |
breakForce | number | 0 | |
breakTorque | number | 0 |
FoliageContact
Something plants feel: grass parts around it, shrubs lean away, and placed plants near it become entities with colliders.
Explained in graphics/foliage.
| Field | Type | Default | Notes |
|---|---|---|---|
radius | number | 40 | How far from this entity plants lean away. Range ≥ 0.01. |
strength | number | 1 | How hard they lean: 1 is a full lean, 0 none. Range 0–2, step 0.01. |
recovery | number | 0.6 | How long grass takes to stand up again behind it. Range ≥ 0, step 0.05. |
enabled | boolean | true |
Health
What something has left, and what makes it damageable at all — written only by the system that answers the Damage bus.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
current | number | 100 | Range ≥ 0. |
max | number | 100 | Range ≥ 0. |
HingeJoint2D
Pins two bodies at a point and lets them rotate — a hinge, with optional limits and a motor.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchorA | Vec2 | (0, 0) | Where the joint attaches on the connected body, in that body's frame (pixels). |
anchorB | Vec2 | (0, 0) | Where it attaches on this entity, in its own frame (pixels). |
enableMotor | boolean | false | |
motorSpeed | number | 0 | |
maxMotorTorque | number | 0 | |
enableLimit | boolean | false | |
lowerAngle | number | 0 | |
upperAngle | number | 0 | |
collideConnected | boolean | false | |
enabled | boolean | true |
HingeJoint3D
One axis of rotation between two 3D bodies — a door or a driven wheel, with optional limits and a motor.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchor | Vec3 | (0, 0, 0) | Where the joint attaches, in THIS entity's frame (world units). |
axis | Vec3 | (0, 1, 0) | |
enableLimit | boolean | false | |
lowerAngle | number | -1.5708 | |
upperAngle | number | 1.5708 | |
enableMotor | boolean | false | |
motorSpeed | number | 0 | |
maxMotorTorque | number | 0 | |
collideConnected | boolean | false | |
enabled | boolean | true | |
breakForce | number | 0 | |
breakTorque | number | 0 | |
angle | number | 0 |
Hitboxes
A box on each bone of a skinned character that follows the animation: a kinematic sensor a ray meets and names, so a shot can tell a head from a boot.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
skin | Entity | none | |
thickness | number | 0.25 | A box's thickness as a fraction of its bone's length. Range 0.01–2. |
minBoneLength | number | 5 | A bone shorter than this gets no box of its own, in world units. Range ≥ 0. |
layer | number | 0 | The collision layer the boxes are in, for a shot to ask for. Range 0–15, step 1. |
enabled | boolean | true |
Hunter
A character that hunts what it perceives: it asks navigation for a route, the character controller for the movement, and the animator for a swing — the concrete twin of ThirdPersonController.
Explained in gameplay/ai/overview.
| Field | Type | Default | Notes |
|---|---|---|---|
attackRange | number | 110 | How close it gets before it swings. Range ≥ 0. |
attackInterval | number | 1.6 | Range ≥ 0. |
rotationSpeed | number | 540 | Range ≥ 0. |
idleThreshold | number | 8 | Range ≥ 0, step 0.05. |
enabled | boolean | true | |
state | string | "idle" | Read-only — the engine computes it. |
cooldown | number | 0 | Read-only — the engine computes it. |
MeleeAttack
A swing whose timing is the animation’s and whose reach is the physics world’s: a `hit` beat asks what is around an animated anchor, and gameplay decides who may be hurt.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
radius | number | 60 | Range ≥ 0. |
damage | number | 25 | Range ≥ 0. |
layers | number | 0 | Range 0–15, step 1. |
anchor | Entity | none | The animated socket the swing reaches from. |
enabled | boolean | true | |
attackId | number | 0 | Read-only — the engine computes it. |
hitCount | number | 0 | Read-only — the engine computes it. |
MeshCollider3D
Collides against an imported mesh’s own triangles — terrain, stairs, a room. Always static, and one-sided.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
mesh | Asset<mesh> | none | Geometry (.esmesh) to collide against. |
layer | number | 0 | Range 0–15. |
friction | number | 0.3 | Range ≥ 0. |
restitution | number | 0 | Range 0–1. |
enabled | boolean | true |
MotorJoint2D
Drives one body toward a target offset and angle — moving platforms and conveyors.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
linearVelocity | Vec2 | (0, 0) | |
maxVelocityForce | number | 0 | |
angularVelocity | number | 0 | |
maxVelocityTorque | number | 0 | |
linearHertz | number | 0 | |
linearDampingRatio | number | 0 | |
maxSpringForce | number | 0 | |
angularHertz | number | 0 | |
angularDampingRatio | number | 0 | |
maxSpringTorque | number | 0 | |
collideConnected | boolean | false | |
enabled | boolean | true |
OneWayPlatform2D
Makes a collider solid from one side only, so a body passes up through it and lands on top.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
normal | Vec2 | (0, 1) | |
localSpace | boolean | false | |
enabled | boolean | true |
PlantProxy
The entity standing in for a placed plant while something is near it, which a ray or a collision finds.
Explained in graphics/foliage.
| Field | Type | Default | Notes |
|---|---|---|---|
source | string | empty | |
key | string | empty |
PlatformerController2D
Runs and jumps a CharacterController2D from the keyboard or a game, with coyote time, a jump buffer and dropping through one-way platforms.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
moveSpeed | number | 260 | Range ≥ 0. |
groundAcceleration | number | 2400 | Range ≥ 0. |
airAcceleration | number | 1500 | Range ≥ 0. |
groundDeceleration | number | 3000 | Range ≥ 0. |
airDeceleration | number | 900 | Range ≥ 0. |
gravity | number | 1600 | Range ≥ 0. |
fallGravityScale | number | 1.25 | Gravity multiplier while falling. Above 1 lands faster than it rose. Range ≥ 0, step 0.05. |
maxFallSpeed | number | 1000 | Range ≥ 0. |
jumpSpeed | number | 620 | Upward speed a jump starts with. 0 = cannot jump. Range ≥ 0. |
jumpCut | number | 0.5 | How much of a rising speed survives letting go of jump. 1 makes every jump full height. Range 0–1, step 0.05. |
coyoteTime | number | 0.1 | After leaving the ground, how long a jump still counts as from the ground. Range ≥ 0, step 0.01. |
jumpBuffer | number | 0.12 | How long a jump pressed too early is remembered, to happen on landing. Range ≥ 0, step 0.01. |
airJumps | number | 0 | Extra jumps before landing again. Range ≥ 0, step 1. |
dropTime | number | 0.2 | How long a drop through a one-way platform lasts. Range ≥ 0, step 0.01. |
keepPlatformVelocity | boolean | true | |
readKeyboard | boolean | true | Move with A/D or the arrows, jump with Space, W or Up, drop with Down or S and jump. Off, a game writes the inputs itself. |
moveInput | number | 0 | Range -1–1, step 0.1. |
jumpHeld | boolean | false | |
jumpPressed | boolean | false | |
dropPressed | boolean | false | |
enabled | boolean | true |
PointJoint3D
Holds two 3D bodies at a shared point, free to turn on all three axes — a chain link, a ragdoll limb.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchor | Vec3 | (0, 0, 0) | Where the joint attaches, in THIS entity's frame (world units). |
collideConnected | boolean | false | |
enabled | boolean | true | |
breakForce | number | 0 | |
breakTorque | number | 0 |
PolygonCollider2D
A convex polygon collision shape from your own points.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
vertices | Vec2[] | [{"x":-0.5,"y":-0.5},{"x":0.5,"y":-0.5},{"x":0.5,"y":0.5},{"x":-0.5,"y":0.5}] | |
radius | number | 0 | |
density | number | 1 | |
friction | number | 0.3 | |
restitution | number | 0 | |
isSensor | boolean | false | |
enabled | boolean | true | |
categoryBits | number | 1 | |
maskBits | number | 65535 |
Ragdoll
Turns a skinned character's bones into jointed bodies while active, with limits by part of the body and one-way knees and elbows, and blends back to the animation when it is switched off.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
active | boolean | false | Whether the character is limp. Turn it on when it is knocked down, off to stand it up. |
skin | Entity | none | The entity that holds the skinned mesh, whose joints are the skeleton. Empty looks on this entity and then below it. |
profile | enum | Humanoid | Uniform gives every joint the same limits. Humanoid gives each the share of them its part of a body has, read from the bone's name: a spine stiff, a shoulder loose, a shin almost a hinge. One of Uniform, Humanoid. |
swing | number | 100 | How far a limb may swing from its bone's line, in degrees. With the humanoid profile, the most a loose joint (a shoulder, a hip) is given. Range 0–175. |
twist | number | 60 | How far a limb may twist about its own line, in degrees. With the humanoid profile, the most a loose joint is given. Range 0–175. |
bend | number | 130 | How far a knee or an elbow may bend, in degrees, and only one way: a shin folds back, a forearm folds forward. 0 leaves them swinging like any other joint. Humanoid profile only. Range 0–175. |
facing | enum | +Z | Which of its own axes the character looks along. It is what tells a knee from a hyperextended one. One of +Z, -Z, +X, -X. |
thickness | number | 0.25 | A limb's thickness as a fraction of its length. Range 0.01–2. |
minBoneLength | number | 0.05 | A bone shorter than this gets no body of its own (a finger, a toe): its parent carries it. Range ≥ 0. |
friction | number | 0.5 | Range ≥ 0. |
recoverTime | number | 0.4 | Seconds to blend from the limp pose back to the animation once the ragdoll is turned off. Range ≥ 0. |
RagdollJoint
What the author says of one bone of a ragdoll: no body of its own, or limits (and a one-way bend) of its own.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
body | boolean | true | Whether this bone gets a body of its own. Off, the bone above carries it. |
custom | boolean | false | Use the limits below instead of the ones the ragdoll's profile gives this joint. |
swing | number | 70 | How far the limb may swing from its bone's line, in degrees, either way. Range 0–175. |
twist | number | 40 | How far the limb may twist about its own line, in degrees, either way. Range 0–175. |
bend | number | 0 | How far it may bend, in degrees, one way only (a knee, an elbow). 0 is an ordinary swing and twist joint. Range 0–175. |
fold | enum | As its name says | Which way a bend goes where the bone's name does not say. One of As its name says, Toward the facing, Away from the facing. |
RigidBody2D
Puts the entity under the flat solver: static, kinematic or dynamic, with damping, gravity scale and sleep.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
bodyType | enum | Dynamic | One of Static, Kinematic, Dynamic. |
gravityScale | number | 1 | |
linearDamping | number | 0 | Range ≥ 0. |
angularDamping | number | 0 | Range ≥ 0. |
fixedRotation | boolean | false | |
bullet | boolean | false | |
enabled | boolean | true |
RigidBody3D
Puts the entity under the 3D solver — its own component set, so a 2D scene keeps the world it already has.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
bodyType | enum | Dynamic | One of Static, Kinematic, Dynamic. |
layer | number | 0 | Range 0–15. |
gravityScale | number | 1 | Range ≥ 0. |
linearDamping | number | 0.05 | Range ≥ 0. |
angularDamping | number | 0.05 | Range ≥ 0. |
fixedRotation | boolean | false | |
continuousCollision | boolean | false | Check the whole path a step covers — what a bullet needs |
enabled | boolean | true | |
mass | number | 0 | Kilograms. 0 = from its shape at the density of water (a ball of 10 cm radius is 4.2 kg). Range ≥ 0. |
SegmentCollider2D
A single line segment — a one-sided wall or edge.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
point1 | Vec2 | (-0.5, 0) | |
point2 | Vec2 | (0.5, 0) | |
density | number | 1 | |
friction | number | 0.3 | |
restitution | number | 0 | |
isSensor | boolean | false | |
enabled | boolean | true | |
categoryBits | number | 1 | |
maskBits | number | 65535 |
SixDOFJoint3D
Locks, limits or frees each translation and rotation axis independently, with optional velocity motors.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchor | Vec3 | (0, 0, 0) | Attachment in this entity’s local frame, in world units. |
axis | Vec3 | (1, 0, 0) | Local X/twist direction. Must be nonzero. |
normalAxis | Vec3 | (0, 1, 0) | Local Y reference. Must not be parallel to the X/twist axis. |
enableMotor | boolean | false | |
angularVelocity | Vec3 | (0, 0, 0) | Body B relative to A, in constraint axes (rad/s). |
maxMotorTorque | number | 10 | Maximum torque per motor axis (N m). Range ≥ 0. |
collideConnected | boolean | false | |
enabled | boolean | true | |
breakForce | number | 0 | Newtons it gives way at; 0 never. Range ≥ 0. |
breakTorque | number | 0 | Newton metres of twist it gives way at; 0 never. Range ≥ 0. |
translationMotion | Vec3 | (0, 0, 0) | Each axis: 0 locked, 1 limited, 2 free. |
rotationMotion | Vec3 | (0, 0, 0) | Each axis: 0 locked, 1 limited, 2 free. |
translationLower | Vec3 | (-100, -100, -100) | |
translationUpper | Vec3 | (100, 100, 100) | |
rotationLower | Vec3 | (-0.5236, -0.5236, -0.5236) | |
rotationUpper | Vec3 | (0.5236, 0.5236, 0.5236) | |
linearVelocity | Vec3 | (0, 0, 0) | Body B relative to A, in constraint axes (world units/s). |
maxMotorForce | number | 100 | Maximum force per translation axis (N). Range ≥ 0. |
SliderJoint2D
Constrains two bodies to slide along one axis — a piston or lift.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchorA | Vec2 | (0, 0) | Where the joint attaches on the connected body, in that body's frame (pixels). |
anchorB | Vec2 | (0, 0) | Where it attaches on this entity, in its own frame (pixels). |
axis | Vec2 | (1, 0) | Direction of travel, in the connected body's frame. |
enableSpring | boolean | false | |
hertz | number | 1 | |
dampingRatio | number | 0.5 | |
enableLimit | boolean | false | |
lowerTranslation | number | 0 | |
upperTranslation | number | 0 | |
enableMotor | boolean | false | |
maxMotorForce | number | 0 | |
motorSpeed | number | 0 | |
collideConnected | boolean | false | |
enabled | boolean | true |
SliderJoint3D
One axis of travel between two 3D bodies — a lift or a piston, with optional limits and a motor.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchor | Vec3 | (0, 0, 0) | Where the joint attaches, in THIS entity's frame (world units). |
axis | Vec3 | (0, 1, 0) | |
enableLimit | boolean | false | |
lowerTranslation | number | -100 | |
upperTranslation | number | 100 | |
enableMotor | boolean | false | |
motorSpeed | number | 0 | |
maxMotorForce | number | 0 | |
collideConnected | boolean | false | |
enabled | boolean | true | |
breakForce | number | 0 | |
breakTorque | number | 0 | |
translation | number | 0 |
SphereCollider3D
A sphere collision shape in 3D.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
radius | number | 50 | Range ≥ 0. |
center | Vec3 | (0, 0, 0) | |
friction | number | 0.3 | Range ≥ 0. |
restitution | number | 0 | Range 0–1. |
isSensor | boolean | false | |
enabled | boolean | true |
SwingTwistJoint3D
A ball joint with independent twist limits, an elliptical swing cone and optional angular velocity motors.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchor | Vec3 | (0, 0, 0) | Attachment in this entity’s local frame, in world units. |
axis | Vec3 | (0, 1, 0) | Local X/twist direction. Must be nonzero. |
normalAxis | Vec3 | (1, 0, 0) | Local Y reference. Must not be parallel to the X/twist axis. |
enableMotor | boolean | false | |
angularVelocity | Vec3 | (0, 0, 0) | Body B relative to A, in constraint axes (rad/s). |
maxMotorTorque | number | 10 | Maximum torque per motor axis (N m). Range ≥ 0. |
collideConnected | boolean | false | |
enabled | boolean | true | |
breakForce | number | 0 | Newtons it gives way at; 0 never. Range ≥ 0. |
breakTorque | number | 0 | Newton metres of twist it gives way at; 0 never. Range ≥ 0. |
normalHalfConeAngle | number | 0.7854 | Range 0–3.1416. |
planeHalfConeAngle | number | 0.7854 | Range 0–3.1416. |
twistMinAngle | number | -0.5236 | Range -3.1416–3.1416. |
twistMaxAngle | number | 0.5236 | Range -3.1416–3.1416. |
ThirdPersonCamera
An eye that orbits a target under pointer control and pulls in when something solid stands between.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
target | Entity | none | The transform this camera orbits. |
distance | number | 420 | |
yaw | number | 0 | |
pitch | number | 15 | |
minPitch | number | -30 | |
maxPitch | number | 70 | |
sensitivity | number | 0.2 | |
followDamping | number | 12 | Range ≥ 0. |
targetOffset | Vec3 | (0, 90, 0) | |
obstruction | boolean | true | |
obstructionRadius | number | 15 | Range ≥ 0. |
obstructionLayers | number | 0 | Range 0–15, step 1. |
enabled | boolean | true |
ThirdPersonController
Turns input into a movement request for a CharacterController3D, and reports what the character actually did to its Animator.
Explained in gameplay/physics-3d.
| Field | Type | Default | Notes |
|---|---|---|---|
moveSpeed | number | 320 | |
acceleration | number | 2400 | |
deceleration | number | 3200 | |
rotationSpeed | number | 720 | |
jumpSpeed | number | 0 | Upward speed a jump starts with. 0 = cannot jump. Range ≥ 0. |
airControl | number | 0.3 | Range 0–1, step 0.05. |
cameraRelative | boolean | true | |
camera | Entity | none | Whose forward the stick is read against. |
idleThreshold | number | 8 | Range ≥ 0, step 0.05. |
enabled | boolean | true |
WheelJoint2D
A suspension axis plus a spinning axle — the wheel half of a vehicle.
Explained in gameplay/physics.
| Field | Type | Default | Notes |
|---|---|---|---|
connectedEntity | Entity | -1 | |
anchorA | Vec2 | (0, 0) | Where the joint attaches on the connected body, in that body's frame (pixels). |
anchorB | Vec2 | (0, 0) | Where it attaches on this entity, in its own frame (pixels). |
axis | Vec2 | (0, 1) | Direction of travel, in the connected body's frame. |
enableSpring | boolean | true | |
hertz | number | 5 | |
dampingRatio | number | 0.7 | |
enableLimit | boolean | false | |
lowerTranslation | number | 0 | |
upperTranslation | number | 0 | |
enableMotor | boolean | false | |
maxMotorTorque | number | 0 | |
motorSpeed | number | 0 | |
collideConnected | boolean | false | |
enabled | boolean | true |