new Prefab3D(pos3D, prefabName)render3dLevel.js:580Create an instance of a prefab, made by its type: place one with a level or level3DSpawn
pos3DVector3 optionalprefabNamestring optionalA prefab added with level3DAddPrefab
An instance of a prefab, what a prefab's type makes: a handle with no shape of its own, and its parts, what the prefab's objects made
Extends EngineObject3D
new Prefab3D(pos3D, prefabName)render3dLevel.js:580Create an instance of a prefab, made by its type: place one with a level or level3DSpawn
pos3D Vector3 optionalprefabName string optionalA prefab added with level3DAddPrefab
attached : booleanrender3dLevel.js:591Are its parts its children, moving with it as one body
originOffset : Vector3render3dLevel.js:598From the prefab's origin to the handle, in the prefab's own space: nothing for separate parts, and for an attached prefab the middle of the box around its parts, where its handle is, as an object's place is the middle of its body
partObjects : Array<{id?: number, type: string, pos?: Array<number>, rotation?: Array<number>, scale?: Array<number>|number, properties?: Object}>render3dLevel.js:600parts : Array<EngineObject3D>render3dLevel.js:594What the prefab's objects made, in the prefab's order
prefabName : stringrender3dLevel.js:589The prefab it is an instance of
placeAt(pos3D)render3dLevel.js:608Put the instance with its prefab's origin at a place, turned and sized as the handle is: where a level's object or level3DSpawn says it goes; the handle of an attached prefab is then at the middle of its body
pos3D Vector3placeParts()render3dLevel.js:619Put the parts where the handle is now, making them the first time; called by the handle's update when it has moved, turned or changed size
render3D()render3dLevel.js:722A prefab's instance has nothing of its own to draw
update()render3dLevel.js:704Keep the parts with the handle, called automatically each frame