I am wondering exactly how these are related. For instance running on a device, you would get touch events. How are mouse events generated from these? Does Gideros simply check if the touch event id is "1" and if so pass it through as a mouse event? (ignoring other touch events).
If running on windows you get mouse events. Are these converted to touch events with id 1?
Is there any problem having both MOUSE_DOWN (etc) and TOUCHES_BEGIN (etc) listeners in the same scene?
Comments
Mouse events are the first touch event
And touch events are mous event simply with id 1
There should be no problem using both, as for example, using mouse events on buttons and touch on game elements, but you must understand that in this case, no button will be pressed until touched elements won't be released
So, just to make sure, is this right (running on device)?
TOUCHES_BEGIN (id=1) --> MOUSE_DOWN
TOUCHES_BEGIN (id=2) (ignored)
TOUCHES_END (id=2) (ignored)
TOUCHES_END (id=1) --> MOUSE_UP
I'm going to correct your English here :-)
"you must understand that in this case, no button will be pressed until touched elements won't be are released"
I intend to use TOUCHES for game controls and MOUSE for pause button etc so its fine. The user needs to remove his fingers from the controls anyway to press the pause button.
Also going to support Xperia PLAY! (which I happen to own)
https://github.com/gideros/gideros
https://www.youtube.com/c/JohnBlackburn1975