Open
Description
Basically using a paradigm of inheritance via:
function child_ctor(...) {
parent_constructor.call(this, ...);
// actual initiator
this.init = function() { ... };
//...
this.init();
}
The problems considering this option are:
- Breaks the getComponent related methods somehow
- Different sprites want to override update/render while retaining parent's update/render as seperate method.
- For point2d: inherits methods that don't really apply to points as a concept like dot product