Pixeljs

A simple and flexible HTML5 and JavaScript powered game engine.

View Project on GitHub Download Pixel.js (v0.9b)

Entity.dispose Method

Removes all internal references to the entity allowing for it to be destroyed by the owning application and collected by the garbage collector.

Remarks

In addition to calling dispose, the entity will need to be set to null afterwards in order to be collected by most browsers.

Examples

Supported Platforms

Google Chrome, Mozilla FireFox, Internet Explorer 9+, Opera, Safari.