schteppe/p2.js — pull request #114 by Fishrock123 (2014-06-24 21:32:59+00:00)
Title: Material: allow custom id & do checks by id

This allows you do things were you may need to have separate material instances that should be treated as if they were identical.

When running in node.js, you don't have the same kind of globals, and so it is necessary for sanity to do something like having a `module.exports.material = new Material(300)` in, say, `Ship.js` that can be checked via id, because a new version is made each time it is imported.
(this is primarily so that you can sanely set up ContactMaterials between entities defined in different files)