Plane
A 100 × 100 double-sided THREE.PlaneGeometry. By default it is rotated -π/2 on the X-axis so it lies flat (XZ ground plane).
ts
import { Behaviour } from "@relu-interactives/spatial-ecs";
export default class SpawnFloor extends Behaviour {
init() {
const objects = this.world.getObjectManagementSystem();
objects?.requestCreate("plane", { name: "Floor" });
}
}Payload
| Field | Type | Default | Description |
|---|---|---|---|
name | string | "Plane" | Display name. |
transform.position | { x, y, z } | (0, 0, 0) | Position. |
transform.rotation | { x, y, z } | (-π/2, 0, 0) | Default lies the plane flat. Pass your own to override. |
transform.scale | { x, y, z } | (1, 1, 1) | Per-axis scale. |
parentId | EntityId | null | null | Optional parent entity. |
TIP
Pass transform.rotation explicitly to make a wall: { x: 0, y: 0, z: 0 } keeps it vertical.
Components attached
Transform, Object3DRef, Name, EntityType, ParentId, Selectable, Mesh, Material, MeshGeometry.

