JSGame
JSGame copied to clipboard
JavaScript + Canvas 2D game engine
The engine should be rewritten in ES6 (ES2015). Then we don't have to implement our own extend and clone methods
It looks weird. It animates for a few frames, and then resets
ParticleSystem should have a loop variable, that makes it looping, or single shot.
Each GameObject should have a _gc method, that returns true/false if the object should be garbage collected. If true, JSGame should clear it from it's children object
GameObject should have a Physics prototype, that implements a crude physics engine. This engine should also take into consideration each GameObjects rotation, if possible, and implement methods such as addForce()....
This way, we might be able to get each individual Particle, to have individual rotation from their parent (ParticleSystem)
It would be better to have the transform and vector2 methods apply to the object itself, instead of returning a new instance. Example: ``` //This is how it is today,...