User Tag List

Results 1 to 7 of 7

Thread: Drag & Drop movement + Gravity?

  1. #1
    Clicker Fusion 2.5

    Join Date
    Jun 2015
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question Drag & Drop movement + Gravity?

    I'm making a game where you collect falling objects, and it needs to be able to be used on an android device. The thing is that I am able to catch the items from falling, but they don't keep falling when I release them. I want them to keep falling if the player is to release or drop them.

    First I was assigning the item that is touch to the X and Y of the touch, so it follows. This solution works, but it's too easy to drop the items and too hard to move them fast without dropping them, which the player will be frustrated by.

    I recently found out that the "Drag and Drop"-movement is brilliant, the item which is being dragged, really hangs on to the touch or mouse - no matter how fast(for what I know).


    The items that are collectibles, that the player are to drag and drop, are being launched by a spawner. This gives the item another movement by default it would seem, as I am not able to move the launched items even though they are set to the dragNdrop-movement.
    I believe that they are set with a static-movement or similar by default when launched?

    I have now been testing to add a movement to swap between depending on if a touch is on it or not, but this is only working on PC(both touch and mouse), and not on android..

    Does anyone know a better solution or how to tackle this issue?

  2. #2
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)
    Wodjanoi's Avatar
    Join Date
    Jun 2015
    Location
    Germany
    Posts
    650
    Mentioned
    5 Post(s)
    Tagged
    0 Thread(s)
    If you are not comfortable with the Drag and Drop movement
    on Android, you can run a simple check using Alterable Values.
    Here is a basic test example with Physics engine gravity:
    Attached files Attached files

  3. #3
    Clicker Fusion 2.5

    Join Date
    Jun 2015
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Thumbs up

    Thank you soo much! This helped heaps! Now it works very fine!

    I am using 3 different collectibles though, but it seems to be working fine for each of them at the moment!
    Have to test if any issues arise when using several fingers trying to collect many things or whatnot.

    I don't completely grasp how the method you gave me works though, I simply wrote mine by following your event list, but would you mind explaining how you are using the values in this example? The names say a lot, but it would clarify a lot in my mind if each event was described briefly ^^

    Either way, this was very helpful! Thank you!

  4. #4
    Clicker Fusion 2.5

    Join Date
    Jun 2015
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I have tried it now, using more than one touch to collect the collectibles, and an interesting problem arise when using two fingers to touch two different items:
    if one it being held, another touch can then stop the movement of any other incoming collectible, which all follow the first touch's movement. I will tinker to see if I can work around this, but if anyone knows a way around this, I'd welcome that!

  5. #5
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)
    Wodjanoi's Avatar
    Join Date
    Jun 2015
    Location
    Germany
    Posts
    650
    Mentioned
    5 Post(s)
    Tagged
    0 Thread(s)
    If you need help with a specific multi-touch behaviour it would be useful to see how
    your current system is working exactly. Do you want the ability to move several objects
    at the same time independently from each other with multiple fingers or do you only
    allow dragging of one object at the same time and you're looking for a method to ignore
    any other touches on objects?
    Can you provide a mfa example to better demonstrate what behaviour you want in your game?
    I also don't mind if you contact me directly in a private message, if you think this could speed things up.
    If your idea could be useful for other people as well, I will provide an example for this thread in any case.

  6. #6
    Clicker Fusion 2.5

    Join Date
    Jun 2015
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Much obliged for the help!

    Yeh as you mention, the problem for me is that I want to restrict the player from grabbing more than one item at a time. I used the code you gave me and applied it to each of the 3 collectible items. This still works beautifully, and it doesn't really allow the player to cheat either as eventually they'll have to release it and then all the collected items will come crashing down, which will be overwhelming and most likely end the game :P But if I can restrict this it would be better.
    Here's an example MFA:
    DragDropCollectionExample.mfa

    Try in the example to touch one, keep the touch and tap the others - You should be able to control them all :d

  7. #7
    Clicker Fusion 2.5

    Join Date
    Jun 2015
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Another thing I have encountered, is that when any of the collectibles are thrown out on the sides, they either disappear or get stuck, giving the same result as the other problem, but so that each other item I touch gets frozen too. I want it to almost be impossible to move it further out than the actual border, so it can't get stuck..

Similar Threads

  1. Drag and drop movement- force drop action
    By qenio in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 7th April 2013, 09:53 PM
  2. Drag & Drop Movement
    By Sloxone in forum iOS Export Module Version 2.0
    Replies: 4
    Last Post: 28th July 2012, 09:43 AM
  3. Drag And Drop movement bug
    By cfullerNY in forum Multimedia Fusion 2 - Technical Support
    Replies: 1
    Last Post: 20th February 2012, 04:21 PM
  4. [BUG?] Drag + Drop Movement
    By Bipolar_Games in forum Android Export Module Version 2.0
    Replies: 1
    Last Post: 17th February 2012, 06:41 PM
  5. Drag And Drop Movement (Bug)
    By Atom in forum SWF/Flash Export Module Version 2.0
    Replies: 3
    Last Post: 28th November 2010, 02:18 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •