API Docs for: 2.7.3
Show:

BaseComponent3D Class

Module: Component
Parent Module: Wanaplan

Base class for 3D components.

Constructor

BaseComponent3D

(
  • core
  • name
)

Parameters:

  • core wnp.Core

    Instance of the Core.

  • name String

    Name of the component.

Methods

compute

() private

Recompute of the component.

destroy

()

Destructor.

disable

()

Disables the component

enable

()

Enables the component

getFloor

(
  • [structure]
)
BABYLON.Mesh

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

Parameters:

Returns:

BABYLON.Mesh:

The floor mesh in 3D.

initialize

()

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

onContextChanged

(
  • context
)

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

Parameters:

  • context String

    The new context

startListening

()

Calls all the event listeners.

stopListening

()

Removes all the event listeners.

update

(
  • deltaTime
)

Updates the dynamic part of the component.

Parameters:

  • deltaTime Number

    The time interval.

Properties

keyboardManager

wnp.KeyboardManager

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

name

String

Name of the component.

structure

wnp.Structure

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