X-Git-Url: https://git.r.bdr.sh/rbdr/sumo/blobdiff_plain/6768cd461ec1a8ea87c0f64e1b3c29e36b0b02ed..refs/heads/rbdr-bouncy-walls:/lib/systems/render.js?ds=sidebyside diff --git a/lib/systems/render.js b/lib/systems/render.js index 83c740d..a0b4659 100644 --- a/lib/systems/render.js +++ b/lib/systems/render.js @@ -55,11 +55,11 @@ export default class RenderSystem extends System { added(engine) { this.renderables = engine.getNodes(RenderableNode); - this.renderables.on('nodeAdded', (event) => { + this.renderables.addEventListener('nodeAdded', (event) => { this.application.stage.addChild(event.node.container.container); }); - this.renderables.on('nodeRemoved', (event) => { + this.renderables.addEventListener('nodeRemoved', (event) => { this.application.stage.removeChild(event.node.container.container); }); @@ -92,4 +92,4 @@ export default class RenderSystem extends System { this.application.render(); } -}; +}