Files
UnityExplorer_Fix/src/Core/Input/NoInput.cs

24 lines
688 B
C#
Raw Normal View History

using UnityEngine;
using UnityEngine.EventSystems;
2020-10-07 16:20:34 +11:00
namespace UnityExplorer.Core.Input
2020-10-07 16:20:34 +11:00
{
// Just a stub for games where no Input module was able to load at all.
public class NoInput : IHandleInput
2020-10-07 16:20:34 +11:00
{
public Vector2 MousePosition => Vector2.zero;
2020-10-07 16:20:34 +11:00
public bool GetKey(KeyCode key) => false;
public bool GetKeyDown(KeyCode key) => false;
2020-10-07 16:20:34 +11:00
public bool GetMouseButton(int btn) => false;
public bool GetMouseButtonDown(int btn) => false;
public BaseInputModule UIModule => null;
public PointerEventData InputPointerEvent => null;
public void ActivateModule() { }
public void AddUIInputModule() { }
2020-10-07 16:20:34 +11:00
}
}