kikemx78

Members
  • Content Count

    11
  • Joined

  • Last visited

About kikemx78

  • Rank
    Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Hello, I would like to know the number of live sprites I have on a game on a given time ? Is it possible? Thanx!
  2. I would recommend to try this tutorial. If you can understand it, you'll be able to build what you need. http://cwbuecheler.com/web/tutorials/2013/node-express-mongo/ Hope it helps...
  3. yes...function is not being called by hover event....
  4. Newbie_HelpMe I did that to detect display's resolution as I need to load a different set of assets depending on that: screen's resolution.
  5. megmut I've already tried that with no success... drhayes you're right, fullscreen needs a user event to work. Even thought, onInputOver (on Phaser & TypeScript) doesn't work as expected (like jQuery's hover) on no matter what kind of event. Look at this example: overS function is only triggered by click and not by mouseOver. The thing is, onInputOver works as jQuery's hover on PhaserJS but not on PhaserTScript. create() { this.butStar2 = this.game.add.button(this.game.width * 0.2555, this.game.height * 0.32, 'butStar2'); this.butStar2.onInputOver.add((e) => { this.overS(e); }); } overS(e) { if ( e.key === 'butStar2') { alert('yes'); } else { alert('wtf'); } }
  6. Don't know if this can help.... Go check out my code on www.e-sant.com/EA/fullScreen/ www.e-sant.com/EA/fullScreen/mobile/
  7. I still have no idea of why this isn't working as expected. I'm using Phaser 2.5 and TypeScript. What I'm expecting: Function being triggered by an onInputOver event (pointer passing over a sprite/button, just like hover on jQuery). What I'm getting: function being triggered by click. Any idea of what am I doing wrong? Is this a bug? create() { this.butStar2 = this.game.add.button(this.game.width * 0.2555, this.game.height * 0.32, 'butStar2'); this.butStar2.onInputOver.add((e) => { this.overS(e); }); } overS(e) { if ( e.key === 'butStar2') { alert('yes'); } else { alert('wtf'); } }
  8. I can't fin a way to make this code work: namespace DeucesPhaser { export class ButFullScreen extends Phaser.Button { game: Phaser.Game; constructor(game: Phaser.Game, x: number, y: number) { super(game, x, y, 'butFullScreen'); this.anchor.setTo(0.5); this.scale.setTo(0.8); this.game.add.existing(this); this.onInputOver.add(() => { this.goFullScreen(); }); } goFullScreen() { if (this.game.scale.isFullScreen) { this.game.scale.stopFullScreen(); } else { this.game.scale.startFullScreen(false); } } } } goFullScreen() should be triggered by mouseOver but it only gets triggered with a click. Normally, onInputOver works fine on JS. Have no idea why I can't make this work on TypeScript. Any help will be appreaciated..
  9. @cloakedninjas... It does works as expected...Thanx !
  10. So I'm trying to build a mobile 3 slot game with Phaser. You can take a look at http://www.e-sant.com/EA/phaser/ to see the animation sequence. You just have to click on the right hand button and let the animation run. What I need to do now is to enable the user to stop the animation when he wants to. If user stops it, tiles must be arranged at the same spot as they stop if animation sequence runs without being stopped. Also, I need to maintain the ease effect you get if you let the animation run without stopping it. Source code https://gitlab.com/kikemx78/deucesPhaser Any help will be appreciated.