NeoFPS Input System
Overview
NeoFPS is built from the ground up to facilitate developing first person shooters for PC and console. One of the most important aspects of this is a strong input setup that allows rebinding keys and supporting various devices. In Unity there are 2 main options for input: the Unity input system and the legacy input manager.
As of NeoFPS 1.1.36, the NeoFPS demos are setup for URP and the input system in Unity 6 and above. In Unity versions below Unity 6, the demos are set up to use the built-in render pipeline and the legacy input manager.
The Unity Input System
The input system allows you to define input "actions" and then assign them one or more bindings. NeoFPS provides an actions asset that is set up for the demos, but which can be extended with your own custom actions as required by your game.
The input system is much more flexible than the older input manager, and supports a wide range of devices such as gamepads and touchscreens. However it is also much more complicated, and that can sometimes require complex workarounds to achieve specific features, and makes it more error prone than the simpler manager.
The Legacy Input Manager
The legacy input manager is a much lower level system than the input system. For keyboard input it works with key codes, and for everything else it requires axes to be set up in the project settings.
The input manager's simplicity is its greatest strength, however its support for gamepads is abysmal. Axis mappings to different gamepad buttons are highly inconsistent across devices (eg playstation vs xbox controllers) and platforms (eg the same controller has different mappings on windows and mac). Gamepads are also only identified by name on connection, making supporting third party controllers very difficult and sometimes even official controllers (eg the XBox series controller has a range of names such as Japanese kanji symbols when connected wirelessly).
In order for NeoFPS' demos to work with the legacy input manager, it requires a number of custom project settings to be applied. For more information see the Input Settings page.
NeoFPS extends the legacy input manager to add features such as:
- Runtime bindable keys
- Consistent gamepad profiles
- Mouse smoothing and accleration
- Input contexts (character, menu, etc).
Input Contexts
In order to categorise inputs and control which inputs are active at any time, NeoFPS makes use of input contexts. These contexts are defined in the FpsInputContext generated constant through the [NeoFpsInputManager][6] asset. Each input handler defines its input context in script and its inputs will only be processed if its context is either None or if no higher priority context is active. Context priority is simply based on the constant value, with higher numbers being higher priority. A context becomes active when one or more input handlers with that context are active. For example, if a UI element has a InputMenu handler attached to it, then when the UI element is active all character input will be blocked.
Keyboard
NeoFPS is preset with a full WASD control scheme, but any keys can be remapped from the in-game menu. The available buttons and their default key bindings can be specified in the [NeoFpsInputManager][6] asset.

At the top of the input bindings menu is a drop down to reset to defaults. This also allows you to select a keyboard layout. Resetting to a different keyboard layout will map the keys so that the hand positions match a Qwerty keyboard. Available keyboard layouts currently include:
- Qwerty
- Azerty
- Qwertz
- Dvorak
- Colemak
To request more keyboard layouts, please contact support via the discord, or using support@neofps.com
Mouse
NeoFPS features detailed mouse support with inverse look, smoothing and acceleration.

Smoothing
Mouse smoothing is performed with a weighted average system. You can customise the number of frames to look back as well as the weighting to apply in the MouseAndGamepadAimController behaviour.
Acceleration
Acceleration can be customised via the MouseAndGamepadAimController behaviour, including setting limits and whether the acceleration is linear or quadratic.
Gamepads
Gamepad support is much stronger in the Unity input system than the legacy input manager. For more information on axis mappings for the legacy input manager see the Unity Wiki
NeoFPS provides a number of preset gamepad profiles, but you are free to extend those from the [NeoFpsInputManager][6] in the NeoFPS Hub.
