How do I move sprite with touch in mulitplayer

0 favourites
  • 4 posts
From the Asset Store
This is a code so you can see the same skin on all screens (peers). Each peer gets a skin, in addition to 4 directions t
  • Seriously, I'm getting old. I actually had it working, then I did something and now I can figure what I did/haven't done.

    Here is a small test capx.

    [attachment=0:2fyav5th][/attachment:2fyav5th]

    I want each user (host and peer) to move his circle to point of touch - super simple, but it is evading me, lol

    Host no problem, but peer circle follows touch but reverts to upper corner (very irritating)

  • I guess that is, because when there is no touch touch.x and touch.y are both 0..

    adding instance variable that are set to touch.x and touch.y on touch end and/or only setting setting the x and y while touching should solve it..

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I guess that is, because when there is no touch touch.x and touch.y are both 0..

    adding instance variable that are set to touch.x and touch.y on touch end and/or only setting setting the x and y while touching should solve it..

    Thanks, I got it working, the issue is I actually had it working without instance var and only using client inputs.... boggles the mind.

    Anyways, its working now(created some x/y instance vars)... just wish i could figure out how i did it using only client inputs... and none of my backups managed to save the mystery work-around. Oh, well.

  • Should be possible by only setting the object while touch is touching, don't think multi-player should make any difference..

    But to be honest I've had these moments myself and using the above way to make sure, always helped..

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