Constructs a new Cube.
The Babylon.js scene.
The size of the cube.
Disposes all resources associated with the cube, including faces, meshes, materials, and observers.
Returns all faces of the cube.
Returns the main mesh of the cube.
Returns the size of the cube.
Removes physics bodies from all cube faces.
Serializes the cube's position and size for saving or exporting.
An object containing the cube's position and size.
Sets the collision observer for the cube.
The observer to notify on bottom face collisions.
Sets up the cube for multiplayer mode by adding separator platforms and portal effects. Adds physics and materials to the separators.
Static
createStatic factory to create and initialize a Cube in the scene.
The Babylon.js scene.
The position of the cube.
The size of the cube.
The created Cube instance.
Cube represents the main cubic structure in Nocturna, serving as the central environment for gameplay.
Responsibilities: