示例#1
0
 private void FindLevelInputHandler()
 {
     InputHandler[] inputHandlers = FindObjectsOfType<InputHandler>();
     for (int i = 0; i < inputHandlers.Length; i++) {
         if (i > 0)
             Destroy(inputHandlers[i].gameObject);
         else {
             _inputHandler = inputHandlers[i];
             _inputHandler.Activate();
         }
     }
 }
示例#2
0
 public void Activate(bool isActive)
 {
     _isActive = isActive;
     _inputHandler.Activate(isActive);
 }