The Input Manager component manages sending and receiving commands in a multiplayer game.
When you’re creating a new map using the RTS Engine menu editor, this component is attached to an object called “InputManager”.
- Snap Distance: When a player sends a command that moves a unit, the original unit position is sent as part of the input. If the distance between the sent original unit position and the current unit position on other clients is greater than this value, then the unit position will be reset to the one sent as part of the input. This allows to avoid de-synchronization issues.
- Update Spawnable Prefabs (button): Creates from all unit and building prefabs placed in a path like this: “*/Resources/Prefabs”. Therefore all unit and building prefabs must be placed in folders that have that path.
- Reset Spawnable Prefabs: Resets the spawnable prefabs list. Note that updating the spawnable prefabs (the above button) list resets it and then adds prefabs to it.