Free Look Feature Specification
From Code43 Urban Warefare Wiki wiki.code43.net
Contents |
Introduction
Purpose
In objective play, the main goal of the red and blue teams is to rush into such a position as to get the best defensive/offensive spots on the map. In order to get to some of such spots, a player may be required to expose his flank to the opposing team for a short time. The player then has two choices – either (a)turn toward the flank to watch it and strafe toward their final goal(which slows them down) or (b) to take a risk and keep running with the flank exposed. This is not necessarily bad in terms of gameplay, because it is just like any other tactical decision that must be made during a round. But in terms of realism, the avatar cannot do a very basic thing that any real person can: run forward while looking to the side.
The proposed feature would allow a player to control their view independently of the direction the avatar is moving, thus allowing a player to watch his flanks while keeping his speed at a maximum.
Conventions
Definitions
- Avatar
- the player entity in-game.
- Movement device
- the input device used to modify the avatar's forward direction. In current practice, this is the mouse.
- View device
- the input device used to modify the avatar's view direction.
- Bind target
- a command that can be bound to a key
- Linear input
- do not change the magnitude of input that is read from the device
- Similar to disabling “mouse acceleration”
- Only applies to devices that have absolute input(i.e. Mouse is not one of them)
- Exponential input
- change the magnitude of input so that movement near the center of the device is reduced, while movement near the edges is increased.
Reading Suggestions
For a more detailed explanation of exponential input you can take a look at the following forum post.
Note that the forum mainly deals with remote-controlled model airplanes, but the basic answer can be seen in the first response.
http://dslyecxi.com/bestoftactical.html#I – Article describing features of tactical FPS games.
http://video.google.com/videoplay?docid=4928428714571383685&hl=en – video of free-look being used in game.
Feature Scope
This feature will affect many parts of the game. It will require the UI to allow for the binding of new keys and the potential use of new input devices. It will require the input subsystem of the game to be able to handle the extra input.
Feature Description
New Use Cases
- If using an extra input device(either analog or digital)
- Allow the user to use the extra input device to modify his view direction
- If not using an extra input device
- Allow the user to switch to a mode where an existing input device will change his view direction
- When in the view modification mode, allow the user to press a button to modify his movement direction while keeping the view direction locked(relative to the world)
- Regardless of using new or existing input devices
- Allow the user to align his view direction with his movement direction
- Optional use cases (Need to code and test)
- Do not allow the user to fire when his view-direction is more than x degrees away from his aim direction. The aim direction might be the same as the movement direction(depending on how we implement aiming)
- Make the fire commands execute ExitFreeLookMode instead of firing if the user is in FreeLookMode.
- Do not allow the user to fire when his view-direction is more than x degrees away from his aim direction. The aim direction might be the same as the movement direction(depending on how we implement aiming)
Required Input Modifications
- Add ability to bind analog controls from any input device to view movement commands
- This should allow the user to be able to specify the type of input to be expected – absolute or relative
- Allow the user to set deadbands for the controls; multiple deadbands should be supported per analog input.
- Allow the user to specify linear as well as exponential input
- Add ability to bind digital controls from any input device to view movement commands
- Allow the user to set the sensitivity of the control
- Not required: Allow the user to use quick-look commands (e.g., press a key to turn view 90° to the left)
- Add the following bind targets
- EnterFreeLookMode – makes an already used axis or set of axes modify the view direction instead of doing previous function of the axes
- ExitFreeLookMode – leaves FreeLookMode and aligns the view direction with the movement direction
- FreeLookModeModifyMovement – while in FreeLookMode only – modifies the movement direction while leaving the view direction unchanged with respect to the world coordinate system.
- Allow the same key to be bound to multiple commands and determine which command to run based on the mode(FreeLookMode or regular)
Functional Requirements
This is mainly going to be things to think about. Once we flesh out how we will be doing our testing and how we will be benchmarking the changes we should update this
- Allow full use of free-look without requiring special input devices.
- Make sure that changing the view-direction does not affect the direction of bullets fired.
- When using free-look made the avatar rotate the head to reflect where the player is looking.
- Prevent the user from rotating their view more than a human can.
- Horizontal – -90° - 90°
- Vertical – -45° - 75°
- Note that it is still not possible to do the following H(90°)V(75°) so a complete model should be made to determine the maximum horizontal rotation given a vertical one and vice versa.
Non-Functional Requirements(Aesthetics)
- When leaving free-look mode and aligning the view direction to the movement direction make the transition smooth.
Limitations and Similar Features
This feature is not intended to be used constantly – it is to be used only for quickly checking ones flanks. Due to this and the limitations of just using a keyboard+mouse input system this feature might not be extremely comfortable to use. This feature is not meant to replace the 'free-aim' that is currently implemented in TC:E.
Engineering and/or Testing Considerations
Our QA process must still be discussed so for the moment I am leaving this empty.

