Highroad Engine v1.3
Public Types | Public Member Functions | Public Attributes | Protected Attributes | Properties | List of all members
MoreMountains.Tools.MMAim Class Reference

Public Types

enum  AimControls {
  Off , PrimaryMovement , SecondaryMovement , Mouse ,
  Script
}
 the list of possible control modes . More...
 
enum  RotationModes { Free , Strict4Directions , Strict8Directions }
 the list of possible rotation modes More...
 

Public Member Functions

virtual void Initialization ()
 Grabs the weapon component, initializes the angle values More...
 
virtual Vector2 GetCurrentAim ()
 Computes the current aim direction More...
 
virtual void SetAim (Vector2 newAim)
 Use this method to set the aim when in AimControl mode : Script More...
 

Public Attributes

AimControls AimControl = AimControls.SecondaryMovement
 the aim control mode More...
 
RotationModes RotationMode = RotationModes.Free
 the rotation mode More...
 
float MinimumAngle = -180f
 the minimum angle at which the weapon's rotation will be clamped More...
 
float MaximumAngle = 180f
 the maximum angle at which the weapon's rotation will be clamped More...
 
float CurrentAngle
 the current angle the weapon is aiming at More...
 

Protected Attributes

float[] _possibleAngleValues
 
Vector3 _currentAim = Vector3.zero
 
Vector3 _direction
 
Vector3 _mousePosition
 
Camera _mainCamera
 

Properties

Vector3 CurrentPosition [getset]
 
Vector2 PrimaryMovement [getset]
 
Vector2 SecondaryMovement [getset]
 

Member Enumeration Documentation

◆ AimControls

the list of possible control modes .

Enumerator
Off 
PrimaryMovement 
SecondaryMovement 
Mouse 
Script 

◆ RotationModes

the list of possible rotation modes

Enumerator
Free 
Strict4Directions 
Strict8Directions 

Member Function Documentation

◆ GetCurrentAim()

virtual Vector2 MoreMountains.Tools.MMAim.GetCurrentAim ( )
virtual

Computes the current aim direction

◆ Initialization()

virtual void MoreMountains.Tools.MMAim.Initialization ( )
virtual

Grabs the weapon component, initializes the angle values

◆ SetAim()

virtual void MoreMountains.Tools.MMAim.SetAim ( Vector2  newAim)
virtual

Use this method to set the aim when in AimControl mode : Script

Parameters
newAim

Member Data Documentation

◆ _currentAim

Vector3 MoreMountains.Tools.MMAim._currentAim = Vector3.zero
protected

◆ _direction

Vector3 MoreMountains.Tools.MMAim._direction
protected

◆ _mainCamera

Camera MoreMountains.Tools.MMAim._mainCamera
protected

◆ _mousePosition

Vector3 MoreMountains.Tools.MMAim._mousePosition
protected

◆ _possibleAngleValues

float [] MoreMountains.Tools.MMAim._possibleAngleValues
protected

◆ AimControl

AimControls MoreMountains.Tools.MMAim.AimControl = AimControls.SecondaryMovement

the aim control mode

◆ CurrentAngle

float MoreMountains.Tools.MMAim.CurrentAngle

the current angle the weapon is aiming at

◆ MaximumAngle

float MoreMountains.Tools.MMAim.MaximumAngle = 180f

the maximum angle at which the weapon's rotation will be clamped

◆ MinimumAngle

float MoreMountains.Tools.MMAim.MinimumAngle = -180f

the minimum angle at which the weapon's rotation will be clamped

◆ RotationMode

RotationModes MoreMountains.Tools.MMAim.RotationMode = RotationModes.Free

the rotation mode

Property Documentation

◆ CurrentPosition

Vector3 MoreMountains.Tools.MMAim.CurrentPosition
getset

◆ PrimaryMovement

Vector2 MoreMountains.Tools.MMAim.PrimaryMovement
getset

◆ SecondaryMovement

Vector2 MoreMountains.Tools.MMAim.SecondaryMovement
getset

The documentation for this class was generated from the following file: