Enfusion Script API
Loading...
Searching...
No Matches
Public Member Functions | List of all members
InputManager Interface Reference
Inheritance diagram for InputManager:
[legend]

Public Member Functions

proto external void SetCursorPosition (int x, int y)
 Sets system cursor position.
 
proto external bool IsUsingMouseAndKeyboard ()
 Returns true when mouse/keyboard is preferred input method.
 
proto external EInputDeviceType GetLastUsedInputDevice ()
 Returns last dominant input device used by user.
 
proto external bool SetLastUsedInputDevice (EInputDeviceType type)
 
proto external void SetLoading (bool isLoading)
 Tells input manager, that is loading. IM than show hide cursor even without per frame updating.
 
proto external void SetGamepadRumble (int userIdx, float fLeftMotorSpeed, float fRightMotorSpeed, float fLeftTriggerSpeed, float fRightTriggerSpeed, int iDurationMs=-1, int iFadeInMs=0, int iFadeOutMs=0)
 Start to rumble a gamepad for specific user (if available).
 
proto external void StopRumble (int userIdx=-1)
 use userIdx = -1 to stop rubmle for all controllers
 
proto external void ResetAction (string actionName)
 Resets internal state of action.
 
proto external void ResetContext (string contextName)
 Resets internal state of all actions in context.
 
proto external bool RegisterActionManager (ActionManager pManager)
 
proto external bool UnregisterActionManager (ActionManager pManager)
 
proto external ref InputBinding CreateUserBinding ()
 
proto external BaseContainer GetKeyUIMapping (string keyName)
 
proto external bool GetActionKeybinding (string actionName, notnull array< string > keyStack, notnull array< BaseContainer > filterStack, EInputDeviceType deviceType=EInputDeviceType.INVALID, string preset=string.Empty, int keyBindIndex=-1)
 
- Public Member Functions inherited from ActionManager
proto external void SetDebug (int debugMode)
 Show debug info via DbgUI.
 
proto external bool ActivateContext (string contextName, int duration=0)
 
proto external bool IsContextActive (string contextName)
 
proto external void SetContextDebug (string contextName, bool bDebug)
 
proto external bool ActivateAction (string actionName, int duration=0)
 
proto external bool IsActionActive (string actionName)
 
proto external float GetActionValue (string actionName)
 Return normalized value of action.
 
proto external EActionValueType GetActionInputType (string actionName)
 Return type of last input contributing to this action.
 
proto external bool GetActionTriggered (string actionName)
 Return TRUE if value of action is above threshold(0.99) and is active.
 
proto external void SetActionValue (string actionName, float value)
 
proto external int GetActionCount ()
 
proto external string GetActionName (int actionIndex)
 
proto external void AddActionListener (string actionName, EActionTrigger trigger, ActionListenerCallback callback)
 
proto external bool RemoveActionListener (string actionName, EActionTrigger trigger, ActionListenerCallback callback)
 

Member Function Documentation

◆ CreateUserBinding()

proto external ref InputBinding InputManager.CreateUserBinding ( )

◆ GetActionKeybinding()

proto external bool InputManager.GetActionKeybinding ( string  actionName,
notnull array< string keyStack,
notnull array< BaseContainer filterStack,
EInputDeviceType  deviceType = EInputDeviceType.INVALID,
string  preset = string.Empty,
int  keyBindIndex = -1 
)

◆ GetKeyUIMapping()

proto external BaseContainer InputManager.GetKeyUIMapping ( string  keyName)

◆ GetLastUsedInputDevice()

proto external EInputDeviceType InputManager.GetLastUsedInputDevice ( )

Returns last dominant input device used by user.

EInputDeviceType.MOUSE for standard mouse & keyboard combination EInputDeviceType.KEYBOARD for keyboard only (activated when using keyboard navigation in UI) EInputDeviceType.* for other devices

◆ IsUsingMouseAndKeyboard()

proto external bool InputManager.IsUsingMouseAndKeyboard ( )

Returns true when mouse/keyboard is preferred input method.

◆ RegisterActionManager()

proto external bool InputManager.RegisterActionManager ( ActionManager  pManager)

◆ ResetAction()

proto external void InputManager.ResetAction ( string  actionName)

Resets internal state of action.

◆ ResetContext()

proto external void InputManager.ResetContext ( string  contextName)

Resets internal state of all actions in context.

◆ SetCursorPosition()

proto external void InputManager.SetCursorPosition ( int  x,
int  y 
)

Sets system cursor position.

◆ SetGamepadRumble()

proto external void InputManager.SetGamepadRumble ( int  userIdx,
float  fLeftMotorSpeed,
float  fRightMotorSpeed,
float  fLeftTriggerSpeed,
float  fRightTriggerSpeed,
int  iDurationMs = -1,
int  iFadeInMs = 0,
int  iFadeOutMs = 0 
)

Start to rumble a gamepad for specific user (if available).

Intensty for low/high frequency is in range from 0 to 1

◆ SetLastUsedInputDevice()

proto external bool InputManager.SetLastUsedInputDevice ( EInputDeviceType  type)

◆ SetLoading()

proto external void InputManager.SetLoading ( bool  isLoading)

Tells input manager, that is loading. IM than show hide cursor even without per frame updating.

◆ StopRumble()

proto external void InputManager.StopRumble ( int  userIdx = -1)

use userIdx = -1 to stop rubmle for all controllers

◆ UnregisterActionManager()

proto external bool InputManager.UnregisterActionManager ( ActionManager  pManager)

The documentation for this interface was generated from the following file: