A better swipe screen is needed

0 favourites
From the Asset Store
All popular touch mechanics - scrolling, zooming, swiping
  • hi there,

    I found this helpful tutorial https://www.scirra.com/tutorials/560/sw ... th-inertia which works great on pc, but when I tested it on mobile I found it to respond pretty poorly. I tried with graphics and without..

    I like having the momentum effect rather than having it stop dead in it's tracks, but this is probably where the performance / accuracy is an issue, but it seems hard to believe this is asking a lot of C2.

    http://part12studios.com/temp/ManualTest/ (with graphics)

    http://part12studios.com/temp/ManualTest2 (without graphics)

    the graphics did bog it down some when testing on iPhone, without graphics seemed a bit better, but on android and WP8, it really felt generally very jerky.

    Is there a smarter/efficient way to do a proper swipe scroll with C2? it seems hard to believe that as great as C2 manages web this would not be a demanding act

    It seems like the "every tick" approach might be the issue? I'm not sure how else to approach this but ultimately what would be great is simply having a nice smooth 60fps feeling experience that isn't struggling when flicked up and down..

    Any advise / tips would be welcome.

    Thanks!

    Caleb

  • This is my demo....

    my lovely demo

    http://www.mediafire.com/download/9cvdt ... /test.capx

    Using drapdrop&touch&bullet

  • It does work very nicely other than going to high up causes the crosshair to leave the scene but it works well going down on PC.

    Still seems to be a little jerky on mobile, but I think I'm realizing that 60fps scrolling even with other sites is not really happening on mobile devices in general so I guess I'm just expecting too much from mobile devices.

    I haven't had a chance to analyze how your system works, but it does seem to be a good one. Thanks for sharing!

  • Ok so I put some simple constraints on that demo, but i'm noticing something undesirable that occurs on this demo.. if you drag and pull (not swipe) it does a kind of jerky dance till you let go.. so it seems like ther emight need to be some other method or approach to how the scroll happens while finger is touching and then on release the bullet effect works nicely...

    http://part12studios.com/temp/ScrollTest1/ original..

    http://part12studios.com/temp/ScrollTest4/ this one was optimized for web (just made the images small so they would load faster and i put some constraints on it to keep the crosshair from leaving the screen..

    unfortunately both suffer from the jerking effect.. here is the optimized version I made https://www.dropbox.com/s/320zqfihyvb8b ... Test3.capx

  • [attachment=0:3ecl64kr][/attachment:3ecl64kr]

  • If you ready to make the game for mobile

    The key point is which planform tools you use

    eg: phonegap=lag lag lag lag|intelXDK.crosswalkdhe@adnroid=very fast

    don't try to use mobile browser play the game

    =======

    about pc&mobile

    just make two Controller

    if user.planform=PC then

    touch UI.invisable

    and enable user to use the mouse ball

  • newt the jiggle is gone, but i also see we can do any kind of drag/scroll with this.. so it's better, but not perfect

    fongka2 its not about making a game for browser, but really getting the logic to work right. the performance issues i site were only part of the issue.. the bigger problem is the swiping logic (even on PC) not being reliable..

    in general all of the techniques I've tried all resulted in something being less than stellar compared to a mobile browser..

    the first one had issues where when you "grab" the screen to flick it, sometimes you'd get dud flicks..

    the bullet method was nice but it lacks any drag-ability

    So even if I did wrap it with crosswalk or some other wrapper, it doesn't matter if it runs faster on mobile if it doesn't perform consistently.

    I'm still excited to find a solution eventually. i think maybe there is some way to blend the two.. i just haven't figured out how.. in my head the way i see it is to use the drag / snap effect used in the bullet method.. notice how it always returns to the middle so no matter what you do you grab it..

    then using the flick / comparison information of that object, pass it on to the camera like in the first example.. but i'm not sure if that would support drag/scrolling.. flick only is not acceptable.. i just want to find an air tight 1 to 1 comparison to how mobile browsers scroll

  • hey part12studios - just curious if you've delved deeper into this / have come up with any solutions. Im about to get heavy with this tomorrow probably and would love to share my results, but even better if we're halfway to a solution that hasnt already been posted.

  • Yo my C2 homies.

    So here's what I got from tonight's work... i think it's close but needs some tweaks for sure. The main thing missing at this point is a 1:1 'drag' scroll.

    You'll notice Im actually setting the bullet and drag action on the BUTTONS themselves. Personally I think this is far superior and less resource intensive as you can have the rest of your UI / background / etc static without worrying about scrolling through everything. PLUS it has the added benefit of doing things like wrapping etc with a little more effort.

    So here's my rough work so far... Let me know if you can help me get it a little further along...

    http://d.pr/f/19RgU/2vWIaYL5

  • Well here we go, i think i got it..

    Basically i pinned the buttons to a "Board" and then Im applying the movement to the board itself, not the buttons, so because the buttons are pinned to the board, they go along for the ride... Give it a try, I've also added mad comments to the capx so you can see how it's all setup. The buttons are placed dynamically so you can generate them on the fly / with a function / etc, and even just pick out their sprite by setting the animation frame to the loopindex.

    Hope this helps someone out there, god knows ive got enough knowledge from these forums, it's only right i give back.

    CAPX: http://d.pr/f/1e1HG/1dCxNTsV

    Demo: http://3030.ca/swipe6/

    Hugs,

    Nate

  • hey man that's nice! thanks for sharing. It definitely seems to be nice and responsive to up and downs even in mid move. the past stuff people were trying just didn't cut it. I had abandoned the swipe thing when the project I was working on fell through, so I'm glad to see you kept at it!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thank you so much 80bit.

    Your capx helped me greatly. Sure I'm not the only one, but better to let you know!

    Cheers

  • very nice! thanks for sharing this capx and yea that's super very good performance

  • Anyone has this capx? Links are not working T_T

  • Well here we go, i think i got it..

    Basically i pinned the buttons to a "Board" and then Im applying the movement to the board itself, not the buttons, so because the buttons are pinned to the board, they go along for the ride... Give it a try, I've also added mad comments to the capx so you can see how it's all setup. The buttons are placed dynamically so you can generate them on the fly / with a function / etc, and even just pick out their sprite by setting the animation frame to the loopindex.

    Hope this helps someone out there, god knows ive got enough knowledge from these forums, it's only right i give back.

    CAPX: http://d.pr/f/1e1HG/1dCxNTsV

    Demo: http://3030.ca/swipe6/

    Hugs,

    Nate

    Hey man, the link is not working anymore. Can you or someone who got it upload it again?

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