Create components for a mesh entity. Returns an object suitable for spreading into spawn().
Optional
const player = ecs.spawn({ ...createMeshComponents(myMesh, { x: 10, y: 0, z: -5 }), velocity: { x: 0, y: 0, z: 0 },}); Copy
const player = ecs.spawn({ ...createMeshComponents(myMesh, { x: 10, y: 0, z: -5 }), velocity: { x: 0, y: 0, z: 0 },});
Create components for a mesh entity. Returns an object suitable for spreading into spawn().