PlatformObjectsManager

PlatformObjectsManager

Manages the common objects shared by objects having a platform behavior: in particular, the platforms behaviors are required to declare themselves (see PlatformObjectsManager.addPlatform) to the manager of their associated scene (see PlatformRuntimeBehavior.getManager).

Constructor

new PlatformObjectsManager(object)

Parameters:
Name Type Description
object

The object

Source:

Methods

(static) getManager()

Get the platforms manager of a scene.

Source:

addPlatform()

Add a platform to the list of existing platforms.

Source:

getAllPlatformsAround(maxMovementLength)

Returns all the platforms around the specified object.

Parameters:
Name Type Description
maxMovementLength

The maximum distance, in pixels, the object is going to do.

Returns:
Type Description

An array with all platforms near the object.

Source:

removePlatform()

Remove a platform from the list of existing platforms. Be sure that the platform was added before.

Source: