Crayta provides a Lua input API so that scripts can detect key/button presses, such as jump, crouch, sprint, and extra actions. However, the analog inputs (move and look around - WASD and mouse on keyboard/mouse, or left and right sticks on controller) currently only control the player’s character - these inputs can’t be detected in Lua.
This feature request suggests adding Lua functionality to detect the left and right analog inputs, probably as Vector2Ds. It needs to be considered that the Lua must detect both keyboard and mouse, and controller inputs, in the same way.
As well as detecting the left and right inputs, this request suggests being able to detect the pressure of the primary and secondary triggers, as a float value between 0 and 1. This would need to just return a binary 0 or 1 for keyboard and mouse users though, to represent whether the primary or secondary mouse button is held.
Detecting these analog inputs would allow creators to give players a lot more control within games - it could be the start of creating a vehicle system for an advanced creator, but would also allow for custom camera controls, or the ability to move any objects other than the player, such as sliding a block in a puzzle mini-game.
Votes on original board: 13