SceneChanger

platypus.components. SceneChanger

new SceneChanger()

This component allows the entity to initiate a change from the current scene to another scene.

Source:
Listens to Events:

Extends

Methods

getAssetList(definition, properties, defaultProperties) → {Array}

This method can be overwritten to provide the list of assets this component requires. This method is invoked when the list of game scenes is created to determine assets for each scene.

Inherited From:
Source:
Parameters:
Name Type Description
definition Object

The definition for the component.

properties Object

The properties of the Entity.

defaultProperties Object

The default properties of the Entity.

Returns:
Type:
Array

A list of the necessary assets to load.

toJSON() → {Object}

Returns a JSON object describing the component.

Inherited From:
Source:
Returns:
Type:
Object

Returns a JSON definition that can be used to recreate the component.

toString() → {String}

Returns a string describing the component.

Inherited From:
Source:
Returns:
Type:
String

Returns the component type as a string of the form "[Component ComponentType]".