https://playcanvas.com/editor/scene/607211
I have the most simple script with touchevents.
If i remove a finger and put a finger on the screen at the same time, touchStart and touchEnd are not fired. It seems to asume that is the same finger that fires touchMove.
To be more clear.
- Put finger in screen: touchStart is called.
- Removed said finger and put another at the same time in another section of the screen: touchMove is called as if the first finger just moved really really fast. No touchEnd and no touchStart.
Maybe this is normal behavior or i m losing my mind. Either way, i m a loss.
Thanks in advance.
var TestTouch = pc.createScript('testTouch');
// initialize code called once per entity
TestTouch.prototype.initialize = function() {
this.entity.element.on('touchstart', this.OnTouchStarted, this);
this.entity.element.on('touchmove', this.OnTouchMoved, this);
this.entity.element.on('touchend', this.OnTouchEnded, this);
this.entity.element.on('touchcancel', this.OnTouchCanceled, this);
};
// update code called every frame
TestTouch.prototype.update = function(dt) {
};
TestTouch.prototype.OnTouchStarted = function(ev){
console.log("started");
};
TestTouch.prototype.OnTouchMoved = function(ev){
console.log("moved");
};
TestTouch.prototype.OnTouchEnded = function(ev){
console.log("ended");
};
TestTouch.prototype.OnTouchCanceled = function(ev){
console.log("canceled");
};