I need function like this, but for Phaser.
wade.addSceneObject(new SceneObject(dotSprite, 0, dotPosition.x, dotPosition.y));
I need function like this, but for Phaser.
wade.addSceneObject(new SceneObject(dotSprite, 0, dotPosition.x, dotPosition.y));
Based upon how I understand your question, I'd highly recommend looking at a Phaser tutorial before you go too much further. The official tutorials are really quite good.
Based upon the documentation for WADE I see that
addSceneObject
adds an object andSceneObject
creates one. So, you want to know how to add a sprite to a game.In Phaser this would be something like:
The Add a Sprite demo shows how to load the image into the cache so it can be included on the page.