Skip to content

@modoki/engine / index / Renderable3DPrimitive

Variable: Renderable3DPrimitive

const Renderable3DPrimitive: Trait<{ color: number; isVisible: boolean; material: string; mesh: string; size: number; }>

Renderable3DPrimitive — built-in primitive meshes with color. Use for simple geometry (cube, sphere, etc.) that doesn't need a GLB asset. Optionally accepts a .mat.json material path — when set, the resolved material replaces the default MeshStandardMaterial created by createPrimitiveMesh.

Built with Modoki.