Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question Input System Thouch Performed only one time

Discussion in 'Input System' started by Eloreden, Sep 20, 2023.

  1. Eloreden

    Eloreden

    Joined:
    Sep 16, 2020
    Posts:
    1
    I'm trying to implement an input system, but I'm facing a problem. I need to know the coordinates when I touch the screen with my finger, so I've implemented a new action as follows:



    I've tried different configurations; this is just the latest of my tests.



    The issue is that with any configuration I use, the 'press' event is only invoked the first time I touch the screen; for subsequent clicks, the 'perform' action doesn't occur. I've noticed that the only case where 'perform' is always executed is with the Action Type 'Button', but it doesn't return the position, rather a float value, whereas I need the position. Am I doing something wrong in the configuration?

    Update: I'm working with the simulator and using the mouse. It seems that if I click on another window to shift the focus and then click back on the game, the action is always executed, but only after clicking somewhere else on the screen.
     
    Last edited: Sep 20, 2023