Announcement

Collapse
No announcement yet.

InputTouch Problem Need Help!

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    InputTouch Problem Need Help!

    I'm having a problem with InputTouch, its not working like its supossed to work, I realize what the problem is but I cant find a way around it
    Basically InputTouch node should give me the finger index, and it does, if I touch with one finger, it returns "Touch 01", BUT if I touch with
    two fingers it returns "Touch 01 AND Touch 02" basically the whole enum, so two action are executed at the same time, the one for touch 01
    and the one for touch 02.

    I need a way to filter the index fingers on the screen, I tried everything from a switch to an if but it still fires the two actions for one and
    two fingers togheter.

    Any help would be appreciated I'm in a deadline and this has becoming a big problem that should have an easy solution.

    I'm leaving some screenshots of the things I have tried, thanks!


    Click image for larger version

Name:	Touch_Problem.jpg
Views:	1
Size:	212.6 KB
ID:	1211819
    Click image for larger version

Name:	fingers.PNG
Views:	2
Size:	160.0 KB
ID:	1211820

    #2
    Try doing AND for Touch 1 & 2 and then Branch.

    Comment


      #3
      Still happens the same, since two fingers launch "touch 01" and "Touch 02" in sequence it first triggers actions for one finger, then for two fingers, I cant believe it works like this, there is no way to isolate "touch 02" Click image for larger version

Name:	AND.jpg
Views:	1
Size:	109.2 KB
ID:	1123809

      Comment


        #4
        Why don't you just use Touch 1, Touch 2 separately:

        Click image for larger version

Name:	Untitled.png
Views:	1
Size:	48.7 KB
ID:	1123816

        Also, you can set any crazy combination for the Action Bindings in the Project Settings >> Input.

        Comment


          #5
          Already tried "touch" node and modifiying inputs, and I have the same result, I will try to make it work on another phone today, if it works I might have found a bug, if it doesnt work means that there is another way to do it that I dont know.

          Comment


            #6
            Ok I tried it on another phone but the same happens, so its no a bug, wich is the correct way to handle this events? Anyone has any clue? I really need to solve this, I might have to stop using unreal for this simple thing wich would be too bad because I liked it, but I need to meet a deadline and I still havent been able to get only touch 2 alone without trigering touch 1. Any help would be aprecciated, thanks!

            Comment


              #7
              So what exactly happens when you use Touch 2? I have no way of testing this. This should react to two fingers and two fingers only, no?

              I'm firing blanks here as I've never worked with mobile so apologies in advance if I misguide you; perhaps you could use a switch:

              Click image for larger version

Name:	Untitled.png
Views:	1
Size:	36.1 KB
ID:	1123885
              Last edited by Everynone; 02-24-2017, 03:36 AM.

              Comment


                #8
                I appreciate that you are taking the time to help me, already tried with switch too, I realized that the finger index comes out as an enum, so if I press with one finger I get "touch one" in finger index, if use two fingers I get "touch one and touch two" if I use three fingers I get "touch one, touch two and touch three" so its imposible to isolate for example touch 3 because all the others values comes out like in a list fiering all the conditions, is there any way to get the last item in an enum? I think this would fix the whole thing, again, thanks for your time!

                Comment


                  #9
                  have you set the input in the project settings, if you want an input being monitored you need to set that input. usually you want inputs like W, A, S and D to be monitored as well for movement. and SPACE for jumping. i guess this will have an equal setting

                  Comment


                    #10
                    Originally posted by Onvitro View Post
                    I appreciate that you are taking the time to help me, already tried with switch too, I realized that the finger index comes out as an enum, so if I press with one finger I get "touch one" in finger index, if use two fingers I get "touch one and touch two" if I use three fingers I get "touch one, touch two and touch three" so its imposible to isolate for example touch 3 because all the others values comes out like in a list fiering all the conditions, is there any way to get the last item in an enum? I think this would fix the whole thing, again, thanks for your time!
                    I did not realise they all fire simultaneously but it does make perfect sense, tbh. I thought there'd be a neat trick to pull it off... but you know, you can always isolate it manually, this may or may not work, worth a try if you're desperate:

                    Click image for larger version

Name:	Untitled.png
Views:	1
Size:	185.7 KB
ID:	1123945

                    You can skip the sequence and cascade the branches, of course.

                    The thing is that one of the fingers will always land first, not sure how the device handles that. You can also try fiddling with the input with tick:

                    Click image for larger version

Name:	Untitled2.png
Views:	1
Size:	82.8 KB
ID:	1123946

                    Again, these are ideas rather than solutions.

                    Comment


                      #11
                      Originally posted by Everynone View Post

                      I did not realise they all fire simultaneously but it does make perfect sense, tbh. I thought there'd be a neat trick to pull it off... but you know, you can always isolate it manually, this may or may not work, worth a try if you're desperate:

                      [ATTACH=CONFIG]130888[/ATTACH]

                      You can skip the sequence and cascade the branches, of course.

                      The thing is that one of the fingers will always land first, not sure how the device handles that. You can also try fiddling with the input with tick:

                      [ATTACH=CONFIG]130889[/ATTACH]

                      Again, these are ideas rather than solutions.
                      The Tick option worked for me, so I added it to a timeline like that If anyone is interested, thank you very much

                      Attached Files
                      Check Hack n Slash Online Template on UMarketplace

                      Follow my Twitter

                      Comment

                      Working...
                      X