Drag & Drop takes 2 objects at once on mobile

0 favourites
  • 3 posts
From the Asset Store
Hand-painted tiles, objects, animated objects, and background to build a colorful Mayan civilization environment.
  • Hi all!

    I'm stuck with a little problem.

    I've made some game with alot of drag and drop objects.

    On my PC this works just fine. Now since this is a Android project it has to work perfect for Android ofcourse.

    My problem is that if i have multiple pieces on each other it will sometimes just simply drag 2 objects instead of 1..

    Does any 1 know how to fix this? I simply have the Drag & Drop instance on it.

    And i got to say, the drag and drop not always work flawless. You really have to hold your finger on the object for like 0.5 sec to start dragging otherwise it will just stay at it's place. Any suggestions on this one? Or is this the fact that i now exported it with phonegap instead of cocoon?

    Oh and one more question.. I wish to set a object to another layer once i did a action but i can't find a option for that. Does this action exist or?

    Thanks in advance!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Well, you could probably add a check to see if 2 or more objects are overlapping and then only select the one on top... How to do this, however, is something that i am not sure how to do - perhaps there was a variable for the z-order or something available in C2 (since arranging it is possible in the layout editor)?

    As for the layers, you could probably just create a new object on the layer you need and delete the old one...

  • EDIT --

    I actually found out that Set to layer is just a action! Nice.

    So, problem about the layers is fixed, still stuck on the drags 2 objects problem! So on my phone when i want to drag 1 object laying ( even half ) on top of a other object will drag both..

    -----

    Stiivais, thanks for your awnsers! I will take a look at the first one, for the second one i will take a look if some more people know a fitting awnser. Your way will work indeed, but since its about 104 objects i hope there is a copy paste way ghehe ;-)

    Thanks!

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