User Tag List

Results 1 to 8 of 8

Thread: Help for touch movement

  1. #1
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export Module
    MEHRDAD's Avatar
    Join Date
    Jan 2009
    Location
    Iran
    Posts
    465
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Help for touch movement

    Hi

    I have an example for platformer left and right. Character have a little glide after stop with keyboard and it's Ok for me. But I couldn't handle it to two left and right sign for touch control . I haven't glide and major bugs in movement. Please open mfa file and try by keyboard and two blue left and right sign in scene.
    In events, please see Horizon touch and Horizontation grroups.
    I'm appreciate for any help
    Attached files Attached files

  2. #2
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export Module
    Fusion 2.5 (Steam)
    schrodinger's Avatar
    Join Date
    Nov 2014
    Posts
    3,155
    Mentioned
    27 Post(s)
    Tagged
    1 Thread(s)
    You want to add touch control to achieve the same movement right?

    You could try two ways:

    1) go to the event editor and click on the "Player1" icon to filter all events containing "Player 1 moved left/right" code
    2) copy-paste all those events in a new group,
    and substitute every "repeat while right/left key pressed"
    with
    "repeat while mouse pressed + mouse over right/left arrow"

    second way:

    using builtin joystick for exporters, but I guess you want a more customizable interface?


    To avoid this, it's probably better coding a movement from scratch with flags
    i.e.
    flag 1 on =would be= repeat while fire 1 pressed
    fire 5 on =would be= repeat while right key pressed

    and so on

    so you can activate/deactivate with flags
    assign flags to different input/keys
    and even make your own custom timings

    ____

    wishlist for CT :
    having chance to say

    on event
    >>> press key "right" of player 1

    would make this easier and quicker building custom keys configurations
    (something you can only do with extensions or with custom fire/move keys currently, afaik)

  3. #3
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export Module
    MEHRDAD's Avatar
    Join Date
    Jan 2009
    Location
    Iran
    Posts
    465
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks a lot. For method 1 : It doesn't play walking animation ...
    Actually I don't want Joystick .
    Don't try flag yet. But I think have same method 1 problem

  4. #4
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export Module
    Fusion 2.5 (Steam)
    schrodinger's Avatar
    Join Date
    Nov 2014
    Posts
    3,155
    Mentioned
    27 Post(s)
    Tagged
    1 Thread(s)
    For method 1 : It doesn't play walking animation ...
    Sure you replicated all events?
    At a quick glance they should be about 20 or so.
    It should behave exactly the same, if you substitute every key press with mousepress.
    You just have to make sure you recreated all the same conditions of the example that are currently using the "player1" joystick
    with the "mouse over button" + "repeat while mouse pressed" thing.

    Going with flags would be good if you started from scratch,
    but if you are working on an existing example,
    and you are sure the only input you want to add is this button press,
    I think you should have easier time with the "method 1" above.

    If you have replicated everything and still refuses to work,
    you can post again and someone can take a look

  5. #5
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export Module
    MEHRDAD's Avatar
    Join Date
    Jan 2009
    Location
    Iran
    Posts
    465
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    OK. Thanks a lot . I replaced all events and seems works now but not perfect .I'll try more .

  6. #6
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export Module
    MEHRDAD's Avatar
    Join Date
    Jan 2009
    Location
    Iran
    Posts
    465
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ok.I did it and Everything is fine except combine two keys . For ex ,I have this lines :

    repeat while fire 1 pressed
    repeat while left key pressed
    mouse over right arrow

    And I changed it to :

    mouse over fire sign
    repeat while left key pressed
    mouse over right arrow

    In runtime is seems OK but on touch device doesn't work . Where is my wrong?

  7. #7
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export Module
    Fusion 2.5 (Steam)
    schrodinger's Avatar
    Join Date
    Nov 2014
    Posts
    3,155
    Mentioned
    27 Post(s)
    Tagged
    1 Thread(s)
    mouse over fire sign
    repeat while left key pressed
    mouse over right arrow
    Can the mouse be over the "fire" button and "right arrow" at the same time?

    Shouldn't the left key be replaced with a "left button"?

    (seem a bit odd though: player would have to press both left, right, and fire?)

  8. #8
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export Module
    MEHRDAD's Avatar
    Join Date
    Jan 2009
    Location
    Iran
    Posts
    465
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    (seem a bit odd though: player would have to press both left, right, and fire?)
    No . left key mouse on right button + over fire button

    p.s : It works on runtime but on devices not.Anyway I put Fire 1 as default touch instead custom fire button and works now.

Similar Threads

  1. Problem with movement using touch...
    By KLiK-iT in forum Android Export Module 2.5
    Replies: 12
    Last Post: 12th August 2014, 12:49 PM
  2. Touch Movement Right/Left
    By Bree in forum Fusion 2.5
    Replies: 3
    Last Post: 25th July 2014, 04:53 AM
  3. Move player with touch calling lef/right movement from Predefined Movement
    By Matriax in forum Android Export Module Version 2.0
    Replies: 3
    Last Post: 13th February 2014, 04:51 PM
  4. Easy gesture movement for touch screens
    By Matriax in forum Android Export Module Version 2.0
    Replies: 1
    Last Post: 16th April 2013, 01:27 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
  •