Atavism3rdPersonInput Class

Namespace
Atavism
Base Types
graph BT Type-->Base0["AtavismInputController"] click Base0 "/docs/client_api_10.4.0/api/Atavism/AtavismInputController" Base0-->Base1["MonoBehaviour"] Type["Atavism3rdPersonInput"] class Type type-node

Syntax

public class Atavism3rdPersonInput : AtavismInputController

Fields

Name Constant Value Summary
cameraDist
cameraFirstPerson
cameraGrabbed
Inherited from AtavismInputController
cameraMaxDist
cameraMinDist
cameraTargetOffset
groundLayers
headHeightAbovePlayerOrigin
idealPitch
inputControllerActive
Inherited from AtavismInputController
maxPitch
minPitch
mouseLookLocked
This variable allows me to lock the interface to mouse look mode. Essentially, this treats the interface as though the right mouse button is down all the time for purposes of the camera updates. The movement still follows
MouseVelocity
mouseWheelDisabled
Inherited from AtavismInputController
MouseWheelVelocity
movement
obstacleLayers
rotateCameraSpeed
rotateSpeed
sdeTarget
target
Inherited from AtavismInputController
walk

Properties

Name Value Summary
CameraGrabbed bool
Inherited from AtavismInputController
CameraPitch float
CameraYaw float
InputControllerActive bool
Inherited from AtavismInputController
IsControllable bool
IsMovingBack bool
MouseWheelDisabled bool
Inherited from AtavismInputController
PlayerYaw float
Target Transform
Inherited from AtavismInputController

Methods

Name Value Summary
ApplyMouseToCamera(float, float) void
Use the information from the mouse movement to update the camera.
FindAcceptableCameraPosition(Camera, Vector3, Vector3, Vector3) float
GetPlayerMovement() Vector3
HandleImmediateKeys(float, float) void
Handle the keyboard and mouse input for movement of the player and camera. This method name says immediate, but really it is acting on a keyboard state that may have been filled in by buffered or immediate input.
IsMouseLook() bool
MoveBackward(bool) void
MoveDown(bool) void
MoveForward(bool) void
MoveUp(bool) void
NoMove(bool) void
OnEvent(AtavismEventData) void
RunCameraUpdate() void
Shake(Vector3) void
StrafeLeft(bool) void
StrafeRight(bool) void
ToggleAutorun() void
TurnLeft(bool) void
TurnRight(bool) void
UpdateCamera() void
This is called from the MouseMoved handler. It updates the cameraPitch, cameraYaw and cameraDist variables (which are later used to modify the camera). It may also update the PlayerYaw.
UpdateCamera(Vector3, Quaternion) void
Move the camera based on the new position of the camera target (player)
UpdateCursorVisibility(bool) void