Skip to main content
Inspiring
March 14, 2017
Question

Adobe Air - tvOS cursor issue

  • March 14, 2017
  • 1 reply
  • 955 views

Hi,

​I have met a problem while using Adobe Air to port my game for tvOS that mouse coordinates don't go out to the stage. Therefore when I swipe 3 or more times at the same direction, it doesn't calculate mouse's coordinate difference at this direction. In this case, it returns zero.

​I have tried to mouseLock and reaching movementX/movementY of the MouseEvent, but tvOS doesn't allow me to lock mouse.

Is there any solution for this? Thank you for your help.

​Best.

This topic has been closed for replies.

1 reply

Community Manager
March 14, 2017

Hi,

For tvOS Swipe events, you will always get default values for localX and localY properties and thus it is not possible to calculate the mouse's coordinates. Use the offsetX, offsetY to determine the swipe direction.

Creating a pointer like application is not recommended on tvOS and can lead to app rejections but you can still get coordinates by subscribing to the Touch Events.

For this, you would first need to set Multitouch.inputMode = MultitouchInputMode.TOUCH_POINT;

Thanks,

Krati | Adobe AIR Engineering

junousAuthor
Inspiring
March 14, 2017

Hi Krati,

offsetX and offsetY gives me total 4 results; 1_0 , -1_0 , 0_1 , 0_-1... However, I need also 1_1 , -1_-1 , 1_-1 , -1_1 directions.

Therefore, I use touch events. I'm not creating a pointer, I'm just reading current mouse's stageX and stageY values to calculate extra offset directions.

Any idea?

Participating Frequently
September 27, 2017

Using the remote as a gamepad could help for detecting swipes, but it would max out at 1 in each direction.

You also can't detect where the user is placing their thumb, which would allow me to use the remote like a d-pad.

Could we just get the absolute coordinates or the touch on the remote?  This would solve theses and any other limitations.