Ejemplo n.º 1
0
 private void Update()
 {
     if (Input.GetKeyDown(startKey))
     {
         _testComponent?.StartTest();
     }
     else if (Input.GetKeyDown(stopKey))
     {
         _testComponent?.StopTest();
     }
 }
Ejemplo n.º 2
0
 private void Start()
 {
     _testComponent = GetComponent <ITester>();
     _inputActions.Player.Suck.started  += ctx => _testComponent?.StartTest();
     _inputActions.Player.Suck.canceled += ctx => _testComponent?.StopTest();
 }