• Content Count

  • Joined

  • Last visited

About GNUton

  • Rank

Contact Methods

  • Twitter
  1. GNUton

    Space Roll

    SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data it doesn't load.. it stops to 41%
  2. I use phaserJS for my games. have a look at You can create your sprites and animate them in few mins.
  3. Hi have a look at the example in the update function you wanna set a second argument for the collide(emitter, array_of_objs_or_group). function update() { game.physics.arcade.collide(emitter); }
  4. You can use inkscape to create your vector graphics or modify some graphics made by others. You can also sketch on paper and then use beizer curves to create the outlines of your characters and so on. There should be quite a lot of tutorials on inkskape (free tool). In the end u can convert svg to PNG with transparency. If you want use pixel art, than u can opt for gimp. (Free software too). Tons of tutorials here too. To pack your PNGs in order to have animations and more.. you can use this For the writings I use bitmap fonts. There are online tools such create bitmap fonts from .ttfs.. You can use this I think you have all the tools in order to create your game. Create a nice graphics is far from being easy. But it s fun. Good luck
  5. In order to keep the sprite in the same position you may want set the anchor into the middle of your sprite before flipping. Mysprite.anchor.x = 0.5 //50% of its width
  6. You will always get sparse points, depending on the input device resolution you use and how quick is the HW/SW you use to draw your lines. My suggested solution would be: Option 1 - Draw a line between two consecutive points. In this case, the thickness of the brush could help a lot to smooth the line Option 2 - Curve fitting??? Interpolate a curve which pass by N consecutive points to achieve a smooth curve.
  7. To me this looks like a bug which should be fixed in the framework. Thanks for your kind answers, guys!
  8. Hi, I would like to know what's the best way to trigger my function with chained tweens. The following code doesn't really work. The function which contains the "alert" is triggered when the first tween completes. var jumpTween = game.add.tween(playState.player);{ y: 70 }, 200); ju{ y: 150}, 400); jumpTween.onComplete.add(function(){console.log("CIAO");}, this); <--- This is triggered when y=70. jumpTween.start(); Is there any elegant solution which doesn't involves combined tweens? ( Cheers, Antonio
  9. What about blocking the orientation to Landscape or portrait? I dunno how to fix it, but there were other threads about this problem.
  10. Hi, I played a little bit with the console in your game and I think I found this solution: To remove a tile from the Ninja physics world you have to perform these steps: 1. Remove the body - with something like map.layers[1].bodies[0].destroy() Note: when you do this. this will generate an Error in Phaser.Physics.Ninja.Circle.collideCircleVsTile But you should be able to work it around! 2. Remove the tile itself from the map - map.removeTileWorldXY(416, 416, 64, 64, layerObjs) This will remove your first "enemy" from your game. x and y = 416. w and h are 64. That's the solution I found. Antonio
  11. IIRC there should be a destroy() somewhere... Not 100% sure BTW!
  12. mins is a Phaser.Physics.Ninja.Body object. Not really sure you can scale it! If you use chrome 1. go to 2. press F12 3. type "tiles" (it's the name of the variable in that code) 4. click the first object and you can see the properties of the object. you can set in real-time the properties of the object. Good luck!
  13. Hi! IIRC I have used your same code. But yesss it worked for me! I had two layers in my game. I have created them with "tiled" (a free Qt-based application). Here is the way how I detect the collision in the update() function: for (var i = 0; i < this.obstacleTiles.length; i++) { var mTile = this.obstacleTiles.tile var isColliding = ( !== undefined; if (isColliding) console.log("collision detected!"); } I have created obstacleTiles in the create function as follow obstacleTiles =, layerObstacles, obstacleMap);
  14. Hi, I have used a similar approach in my code and it worked like a charm! I used the latest phaser version now available. Please note that: returns false - if the objects collide undefined - if the objects do not collide I don't know if that was made on purpose of it's a bug.
  15. I have amended the source code and you can download the DLL which exports the map to JSON Array. If you like to use it, copy the file and select JSONA as extension type when you save the image map. Enjoy!