-Class("TestSystem").inherits(Serpentity.System)({
- prototype : {
- added : function added(engine){
- this.nodeList = engine.getNodes(MovementNode);
- },
- removed : function removed(engine){
- this.nodeList = undefined;
+ let TestSystem = class TestSystem extends Serpentity.System {
+ added (engine){
+ this.nodeList = engine.getNodes(MovementNode);
+ },
+ removed (engine){
+ this.nodeList = undefined;
+ }
+ update (dt){
+ let node;
+ for (node of this.nodeList) {
+ console.log(`Current position is: ${node.position.x},${node.position.y}`);