M&B: Bannerlord 1.3.14
The horns sound, the ravens gather.
Loading...
Searching...
No Matches
TaleWorlds.InputSystem.Input Class Reference

Public Types

enum  ControllerTypes {
  None = 0x00 ,
  Xbox = 0x01 ,
  PlayStationDualShock = 0x02 ,
  PlayStationDualSense = 0x04
}

Static Public Member Functions

static bool IsPlaystation (this ControllerTypes controllerType)
static void Initialize (IInputManager inputManager, IInputContext debugInput)
static void UpdateKeyData (byte[] keyData)
static float GetMouseMoveX ()
static float GetMouseMoveY ()
static float GetNormalizedMouseMoveX ()
static float GetNormalizedMouseMoveY ()
static float GetGyroX ()
static float GetGyroY ()
static float GetGyroZ ()
static Vec2 GetKeyState (InputKey key)
static bool IsKeyPressed (InputKey key)
static bool IsKeyDown (InputKey key)
static bool IsKeyDownImmediate (InputKey key)
static bool IsKeyReleased (InputKey key)
static bool IsControlOrShiftNotDown ()
static ControllerTypes GetPrimaryControllerType ()
static int GetFirstKeyPressedInRange (int startKeyNo)
static int GetFirstKeyDownInRange (int startKeyNo)
static int GetFirstKeyReleasedInRange (int startKeyNo)
static void PressKey (InputKey key)
static void ClearKeys ()
static int GetVirtualKeyCode (InputKey key)
static bool IsDown (this InputKey key)
static bool IsPressed (this InputKey key)
static bool IsReleased (this InputKey key)
static void SetClipboardText (System.String text)
static string GetClipboardText ()
static void Update ()
static bool IsControllerKey (InputKey key)
static void SetMousePosition (int x, int y)
static void SetCursorFriction (float frictionValue)
static InputKey[] GetClickKeys ()
 Represents the click keys. In some regional builds the click key is different. Sometimes LOption is also click.
static void SetRumbleEffect (float[] lowFrequencyLevels, float[] lowFrequencyDurations, int numLowFrequencyElements, float[] highFrequencyLevels, float[] highFrequencyDurations, int numHighFrequencyElements)
static void SetTriggerFeedback (byte leftTriggerPosition, byte leftTriggerStrength, byte rightTriggerPosition, byte rightTriggerStrength)
static void SetTriggerWeaponEffect (byte leftStartPosition, byte leftEnd_position, byte leftStrength, byte rightStartPosition, byte rightEndPosition, byte rightStrength)
static void SetTriggerVibration (float[] leftTriggerAmplitudes, float[] leftTriggerFrequencies, float[] leftTriggerDurations, int numLeftTriggerElements, float[] rightTriggerAmplitudes, float[] rightTriggerFrequencies, float[] rightTriggerDurations, int numRightTriggerElements)
static void SetLightbarColor (float red, float green, float blue)

Static Public Attributes

const int NumberOfKeys = 256
static Action OnGamepadActiveStateChanged
static Action< ControllerTypesOnControllerTypeChanged

Properties

static InputState InputState [get]
static IInputContext DebugInput [get]
static IInputManager InputManager [get]
static Vec2 Resolution [get]
static Vec2 DesktopResolution [get]
static bool IsOnScreenKeyboardActive [get, set]
static bool IsMouseActive [get]
static bool IsControllerConnected [get]
static bool IsGamepadActive [get]
static bool IsAnyTouchActive [get]
static ControllerTypes ControllerType [get]
static float MouseMoveX [get]
static float MouseMoveY [get]
static float GyroX [get]
static float GyroY [get]
static float GyroZ [get]
static float MouseSensitivity [get]
static float DeltaMouseScroll [get]
static Vec2 MousePositionRanged [get]
static Vec2 MousePositionPixel [get]
static bool IsMousePositionUpdated [get]
static bool IsMouseScrollChanged [get]

Member Enumeration Documentation

◆ ControllerTypes

Enumerator
None 
Xbox 
PlayStationDualShock 
PlayStationDualSense 

Member Function Documentation

◆ IsPlaystation()

bool TaleWorlds.InputSystem.Input.IsPlaystation ( this ControllerTypes controllerType)
static

◆ Initialize()

void TaleWorlds.InputSystem.Input.Initialize ( IInputManager inputManager,
IInputContext debugInput )
static

◆ UpdateKeyData()

void TaleWorlds.InputSystem.Input.UpdateKeyData ( byte[] keyData)
static

◆ GetMouseMoveX()

float TaleWorlds.InputSystem.Input.GetMouseMoveX ( )
static

◆ GetMouseMoveY()

float TaleWorlds.InputSystem.Input.GetMouseMoveY ( )
static

◆ GetNormalizedMouseMoveX()

float TaleWorlds.InputSystem.Input.GetNormalizedMouseMoveX ( )
static

◆ GetNormalizedMouseMoveY()

float TaleWorlds.InputSystem.Input.GetNormalizedMouseMoveY ( )
static

◆ GetGyroX()

float TaleWorlds.InputSystem.Input.GetGyroX ( )
static

◆ GetGyroY()

float TaleWorlds.InputSystem.Input.GetGyroY ( )
static

◆ GetGyroZ()

float TaleWorlds.InputSystem.Input.GetGyroZ ( )
static

◆ GetKeyState()

Vec2 TaleWorlds.InputSystem.Input.GetKeyState ( InputKey key)
static

◆ IsKeyPressed()

bool TaleWorlds.InputSystem.Input.IsKeyPressed ( InputKey key)
static

◆ IsKeyDown()

bool TaleWorlds.InputSystem.Input.IsKeyDown ( InputKey key)
static

◆ IsKeyDownImmediate()

bool TaleWorlds.InputSystem.Input.IsKeyDownImmediate ( InputKey key)
static

◆ IsKeyReleased()

bool TaleWorlds.InputSystem.Input.IsKeyReleased ( InputKey key)
static

◆ IsControlOrShiftNotDown()

bool TaleWorlds.InputSystem.Input.IsControlOrShiftNotDown ( )
static

◆ GetPrimaryControllerType()

ControllerTypes TaleWorlds.InputSystem.Input.GetPrimaryControllerType ( )
static

◆ GetFirstKeyPressedInRange()

int TaleWorlds.InputSystem.Input.GetFirstKeyPressedInRange ( int startKeyNo)
static

◆ GetFirstKeyDownInRange()

int TaleWorlds.InputSystem.Input.GetFirstKeyDownInRange ( int startKeyNo)
static

◆ GetFirstKeyReleasedInRange()

int TaleWorlds.InputSystem.Input.GetFirstKeyReleasedInRange ( int startKeyNo)
static

◆ PressKey()

void TaleWorlds.InputSystem.Input.PressKey ( InputKey key)
static

◆ ClearKeys()

void TaleWorlds.InputSystem.Input.ClearKeys ( )
static

◆ GetVirtualKeyCode()

int TaleWorlds.InputSystem.Input.GetVirtualKeyCode ( InputKey key)
static

◆ IsDown()

bool TaleWorlds.InputSystem.Input.IsDown ( this InputKey key)
static

◆ IsPressed()

bool TaleWorlds.InputSystem.Input.IsPressed ( this InputKey key)
static

◆ IsReleased()

bool TaleWorlds.InputSystem.Input.IsReleased ( this InputKey key)
static

◆ SetClipboardText()

void TaleWorlds.InputSystem.Input.SetClipboardText ( System.String text)
static

◆ GetClipboardText()

string TaleWorlds.InputSystem.Input.GetClipboardText ( )
static

◆ Update()

void TaleWorlds.InputSystem.Input.Update ( )
static

◆ IsControllerKey()

bool TaleWorlds.InputSystem.Input.IsControllerKey ( InputKey key)
static

◆ SetMousePosition()

void TaleWorlds.InputSystem.Input.SetMousePosition ( int x,
int y )
static

◆ SetCursorFriction()

void TaleWorlds.InputSystem.Input.SetCursorFriction ( float frictionValue)
static

◆ GetClickKeys()

InputKey[] TaleWorlds.InputSystem.Input.GetClickKeys ( )
static

◆ SetRumbleEffect()

void TaleWorlds.InputSystem.Input.SetRumbleEffect ( float[] lowFrequencyLevels,
float[] lowFrequencyDurations,
int numLowFrequencyElements,
float[] highFrequencyLevels,
float[] highFrequencyDurations,
int numHighFrequencyElements )
static

◆ SetTriggerFeedback()

void TaleWorlds.InputSystem.Input.SetTriggerFeedback ( byte leftTriggerPosition,
byte leftTriggerStrength,
byte rightTriggerPosition,
byte rightTriggerStrength )
static

◆ SetTriggerWeaponEffect()

void TaleWorlds.InputSystem.Input.SetTriggerWeaponEffect ( byte leftStartPosition,
byte leftEnd_position,
byte leftStrength,
byte rightStartPosition,
byte rightEndPosition,
byte rightStrength )
static

◆ SetTriggerVibration()

void TaleWorlds.InputSystem.Input.SetTriggerVibration ( float[] leftTriggerAmplitudes,
float[] leftTriggerFrequencies,
float[] leftTriggerDurations,
int numLeftTriggerElements,
float[] rightTriggerAmplitudes,
float[] rightTriggerFrequencies,
float[] rightTriggerDurations,
int numRightTriggerElements )
static

◆ SetLightbarColor()

void TaleWorlds.InputSystem.Input.SetLightbarColor ( float red,
float green,
float blue )
static

Member Data Documentation

◆ NumberOfKeys

const int TaleWorlds.InputSystem.Input.NumberOfKeys = 256
static

◆ OnGamepadActiveStateChanged

Action TaleWorlds.InputSystem.Input.OnGamepadActiveStateChanged
static

◆ OnControllerTypeChanged

Action<ControllerTypes> TaleWorlds.InputSystem.Input.OnControllerTypeChanged
static

Property Documentation

◆ InputState

InputState TaleWorlds.InputSystem.Input.InputState
staticget

◆ DebugInput

IInputContext TaleWorlds.InputSystem.Input.DebugInput
staticget

◆ InputManager

IInputManager TaleWorlds.InputSystem.Input.InputManager
staticget

◆ Resolution

Vec2 TaleWorlds.InputSystem.Input.Resolution
staticget

◆ DesktopResolution

Vec2 TaleWorlds.InputSystem.Input.DesktopResolution
staticget

◆ IsOnScreenKeyboardActive

bool TaleWorlds.InputSystem.Input.IsOnScreenKeyboardActive
staticgetset

◆ IsMouseActive

bool TaleWorlds.InputSystem.Input.IsMouseActive
staticget

◆ IsControllerConnected

bool TaleWorlds.InputSystem.Input.IsControllerConnected
staticget

◆ IsGamepadActive

bool TaleWorlds.InputSystem.Input.IsGamepadActive
staticget

◆ IsAnyTouchActive

bool TaleWorlds.InputSystem.Input.IsAnyTouchActive
staticget

◆ ControllerType

ControllerTypes TaleWorlds.InputSystem.Input.ControllerType
staticget

◆ MouseMoveX

float TaleWorlds.InputSystem.Input.MouseMoveX
staticget

◆ MouseMoveY

float TaleWorlds.InputSystem.Input.MouseMoveY
staticget

◆ GyroX

float TaleWorlds.InputSystem.Input.GyroX
staticget

◆ GyroY

float TaleWorlds.InputSystem.Input.GyroY
staticget

◆ GyroZ

float TaleWorlds.InputSystem.Input.GyroZ
staticget

◆ MouseSensitivity

float TaleWorlds.InputSystem.Input.MouseSensitivity
staticget

◆ DeltaMouseScroll

float TaleWorlds.InputSystem.Input.DeltaMouseScroll
staticget

◆ MousePositionRanged

Vec2 TaleWorlds.InputSystem.Input.MousePositionRanged
staticget

◆ MousePositionPixel

Vec2 TaleWorlds.InputSystem.Input.MousePositionPixel
staticget

◆ IsMousePositionUpdated

bool TaleWorlds.InputSystem.Input.IsMousePositionUpdated
staticget

◆ IsMouseScrollChanged

bool TaleWorlds.InputSystem.Input.IsMouseScrollChanged
staticget