Jump to content

[Touch] drag event on holdDown


Gregory
 Share

Recommended Posts

Hi,

 

I need to track the pointer position when someone is holding and moving his finger.

I tried a combination of things but none work.

 

Here is 2 that does not work:

 

Listening to events:

    this.drawing = this.game.add.sprite(0, 0, this.bmd);    this.drawing.inputEnabled = true;    this.drawing.events.onInputUp.add(this.onInputUp, this);    this.drawing.events.onInputDown.add(this.onInputDown, this);

onInputDown is not trigger while the finger is moving

 

Checking bool on update:

http://www.html5gamedevs.com/topic/1764-how-to-capture-a-touch-event-on-mobile-device/?p=24440

update: function(){    for (var i = 1; i <= 10; i++) {      if (this.game.input["pointer" + i])        console.log( this.game.input["pointer" + i].isDown );    };

This is always false.

 

 

I am out of ideas, does anymore knows how to do what I need?

Thanks,

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...