API Docs for: 2.7.3
Show:

StairwayComponent3D Class

Extends BaseComponent3D
Module: Component
Parent Module: Wanaplan

Stairway component 3D.

Constructor

StairwayComponent3D

(
  • core
)

Parameters:

  • core wnp.Core

    Wanaplan.

Methods

compute

() private

Inherited from BaseComponent3D:

Recompute of the component.

createScene

()

Creates all the stairways of the scene.

createStairway

(
  • stairway
  • sceneF
  • scene
)

Creates the mesh of a stairway.

Parameters:

  • stairway StairwayStructure

    The structure of the stairway.

  • sceneF BABYLON.Mesh

    The mesh of the floor.

  • scene BABYLON.Scene

    The global scene.

destroy

()

Inherited from BaseComponent3D:

Destructor.

disable

()

Inherited from BaseComponent3D:

Disables the component

enable

()

Inherited from BaseComponent3D:

Enables the component

getFloor

(
  • [structure]
)
BABYLON.Mesh

Inherited from BaseComponent3D:

Gets the 3D mesh of the floor structure in parameter (by default current floor).

Parameters:

Returns:

BABYLON.Mesh:

The floor mesh in 3D.

initialize

()

Inherited from BaseComponent3D:

Method called when Wanaplan is initialized. You don't need to call this method manually.

initMaterials

(
  • object3d
  • materials
)
private

Puts the material on the good mesh.

Parameters:

  • object3d BABYLON.Mesh

    The mesh of the stairway.

  • materials wnp.standardMaterial

    The materials of the stairway.

onContextChanged

(
  • context
)

Inherited from BaseComponent3D:

Method called when the context is switched (2D -> 3D or 3D -> 2D)

Parameters:

  • context String

    The new context

onFloorReady

(
  • event
)
private

When the floor is ready, we can create all the floor of the stage.

Parameters:

  • event Event

    The event with the important informations (The scene and the current structure).

startListening

()

Inherited from BaseComponent3D:

Calls all the event listeners.

stopListening

()

Inherited from BaseComponent3D:

Removes all the event listeners.

update

(
  • deltaTime
)

Inherited from BaseComponent3D:

Updates the dynamic part of the component.

Parameters:

  • deltaTime Number
    The time interval.

Properties

keyboardManager

wnp.KeyboardManager

Inherited from BaseComponent3D:

Instance of the Keyboard Manager (shortcut to wanaplan.keyboardManager).

name

String

Inherited from BaseComponent3D:

Name of the component.

structure

wnp.Structure

Inherited from BaseComponent3D:

Instance of the structure (shortcut to wanaplan.structure).