![]() |
Murl Engine Lua Addon API
Version 1.0 beta
|
The game controller mapping interface.
The IGameControllerMapping interface can be accessed by the Logic::IDeviceHandler::GetGameControllerMapping() method or the Input::IGameControllerDevice::GetMapping() method.
The RawData is supplied directly from the controller device and can be used to create an interactive mapping setup.
Use GetRawData() to determine the raw data on the game controller, afterwards use SetRawMapping() to setup a corresponding mapping.
Use Logic::IDeviceHandler::GetGameControllerDeviceInfo() or Input::IGameControllerDevice::GetDeviceInfo() to identify the controller.
Murl.IGameControllerMapping.AxisMapping
Murl.IGameControllerMapping.AxisRawData
Murl.IGameControllerMapping.ButtonMapping
Murl.IGameControllerMapping.DeviceInfo
Murl.IGameControllerMapping.PovMapping
Murl.IGameControllerMapping.RawData
Murl.IGameControllerMapping.RawMapping
Definition of raw data axis types.
Murl.IGameControllerMapping.AXIS_X | The raw data's x-axis. |
Murl.IGameControllerMapping.AXIS_Y | The raw data's y-axis. |
Murl.IGameControllerMapping.AXIS_Z | The raw data's z-axis. |
Murl.IGameControllerMapping.AXIS_RX | The raw data's right x-axis. |
Murl.IGameControllerMapping.AXIS_RY | The raw data's right y-axis. |
Murl.IGameControllerMapping.AXIS_RZ | The raw data's right z-axis. |
Definition of axis events.
Murl.IGameControllerMapping.AXIS_EVENT_NONE | No axis. |
Murl.IGameControllerMapping.AXIS_EVENT_LEFT_STICK_X | Left stick x-axis. The range is [-1.0 left .. 1.0 right] |
Murl.IGameControllerMapping.AXIS_EVENT_LEFT_STICK_Y | Left stick y-axis. The range is [-1.0 bottom .. 1.0 top] |
Murl.IGameControllerMapping.AXIS_EVENT_RIGHT_STICK_X | Right stick x-axis. The range is [-1.0 left .. 1.0 right] |
Murl.IGameControllerMapping.AXIS_EVENT_RIGHT_STICK_Y | Right stick y-axis. The range is [-1.0 bottom .. 1.0 top] |
Murl.IGameControllerMapping.AXIS_EVENT_L1_BUTTON | Left shoulder button (1st row) value. The range is [0.0 not pressed .. 1.0 full pressed]. |
Murl.IGameControllerMapping.AXIS_EVENT_R1_BUTTON | Right shoulder button (1st row) value. The range is [0.0 not pressed .. 1.0 full pressed]. |
Murl.IGameControllerMapping.AXIS_EVENT_L2_BUTTON | Left shoulder button (2nd row) value. The range is [0.0 not pressed .. 1.0 full pressed]. |
Murl.IGameControllerMapping.AXIS_EVENT_R2_BUTTON | Right shoulder button (2nd row) value. The range is [0.0 not pressed .. 1.0 full pressed]. |
Murl.IGameControllerMapping.NUM_AXIS_EVENTS |
Definition of an array holding AxisRawData values.
Definition of an array holding AxisMapping values.
Definition of an array holding ButtonMapping values.
Definition of an array holding PovMapping values.
Get the current raw data.
Boolean, Murl.IGameControllerMapping.RawData GetRawData(Murl.IGameControllerMapping.RawData rawData)
rawData | The raw data return value. |
Set the current raw data. Automatically posts the game controller's events based on the raw data and mapping.
This is typically used by the device implementation only.
Boolean SetRawData(Murl.IGameControllerMapping.RawData rawData)
rawData | The raw data to set. |
Get the mapping data.
Boolean, Murl.IGameControllerMapping.RawMapping GetRawMapping(Murl.IGameControllerMapping.RawMapping rawMapping)
rawMapping | The mapping data return value. |
Set the mapping data. Automatically sets the game controller's available controls based on the raw mapping.
Boolean SetRawMapping(Murl.IGameControllerMapping.RawMapping rawMapping)
rawMapping | The mapping data to set. |