Exemplo n.º 1
0
 public GesturePlatformMouse(GesturePlatformMouseConfig config, KeyActionBindingsSo keys, GestureState state, Camera camera, EventSystem eventSystem)
 {
     this.config      = config;
     this.state       = state;
     this.camera      = camera;
     this.eventSystem = eventSystem;
     this.keys        = keys;
     keys.OnDown     += OnActionDown;
     keys.OnUp       += OnActionUp;
 }
Exemplo n.º 2
0
 public InputStack(KeyActionBindingsSo bindings)
 {
     bindings.OnDown += HandleActionDown;
     bindings.OnUp   += HandleActionUp;
     foreach (var value in Enum.GetValues(typeof(KeyAction)))
     {
         var asAction = (KeyAction)value;
         var keyEvent = new InputPressEvent(asAction);
         events.Add(keyEvent);
         eventMap[asAction] = keyEvent;
     }
 }