Search Unity

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

Resolved (with 1.1.0-preview.2) `TapInteraction` is cancelled immediately

Discussion in 'Input System' started by zledas, Jan 8, 2021.

  1. zledas

    zledas

    Joined:
    Nov 3, 2010
    Posts:
    23
    Hi all,

    am I doing something wrong, or with 1.1.0 (versus 1.0.1) `TapInteraction` does not work properly any more?

    From the debug I see that `Process()` is called right after `context.Started();` is called and in that `Process()` call `context.timerHasExpired` is true, so it gets cancelled here:

    Code (CSharp):
    1.  
    2.         public void Process(ref InputInteractionContext context)
    3.         {
    4.             if (context.timerHasExpired)
    5.             {
    6.                 context.Canceled();
    7.                 return;
    8.             }
    9.  
    Is this only me, or something is broken in this preview version?
     
  2. zledas

    zledas

    Joined:
    Nov 3, 2010
    Posts:
    23
    Restarting Unity editor solved the problem...