Touch.X, Touch.Y

0 favourites
  • 4 posts
From the Asset Store
Surena Touch
$2.50 USD
A wrap from official Touch plugin to export touch/mouse input to other plugins.
  • i am having some trouble converting this:

    mouse -> on button release --> set angle toward (Mouse.X, Mouse.Y)

    into a serviceable mobile touch element

    touch -> on touch end (or any of the touch commands) --> set angle toward (Touch.X, Touch.Y)**

    ** when i run this on my mobile device the sprite would go off to the left at a 45 degree angle (r61) and goes straight up screen (r62) no matter where the touch occurs on the screen

    any suggestions??

  • Hmm, might be a bug - I'll see if I can fix this for the next build.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Thanx

  • Ashley

    i did a test to see if the values for Touch.X, Touch.Y are at least being registered

    the set up:

    global variable = someTouchedX

    global variable = someTouchedY

    touch -> on touch start --> someTouchedX (Touch.X)

                                someTouchedY (Touch.Y)

                                textX = someTouchedX

                                textY = someTouchedY

    ** the touch values from Touch.X and Touch.Y do register however the values do not translate (immediately)

    what i've noticed is that the Touch.X and Touch.Y do not register until there is a second touch

    (i.e. 1st touch sprite moves in this case upward toward the top of the screen a 2nd touch is entered and the Touch.x and Touch.Y coordinates register and the sprite moves according to -> set angle to (Touch.X, Touch.Y) )

    + not sure if this is a bug in r62 or a matter of "programming"

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)