Third Person Cover Shooter  1.6
CoverShooter.AIFollow Class Reference

Moves and rotates the character motor so that it faces and follows the enemy when needed. More...

Inheritance diagram for CoverShooter.AIFollow:
CoverShooter.AIBase

Public Member Functions

void OnFoundCover ()
 Notified by another component that a cover was found. More...
 
void OnInvalidCover ()
 Notified by another component that current cover is no longer valid. More...
 
void OnThreatPosition (Vector3 position)
 Notified by the brains of a new threat position. More...
 
void ToStartFollowing (Vector3 position)
 Told by the brains to follow a position. More...
 
void ToStopFollowing ()
 Told by the brains to stop following. More...
 
void ToKeepCloseTo (KeepCloseTo value)
 Told by the brains to keep close to a position. More...
 
- Public Member Functions inherited from CoverShooter.AIBase
void Message (string name)
 Sends a message to other components. More...
 
void Message (string name, object value)
 Sends a message to other components. More...
 

Public Attributes

float AvoidDistance = 10
 Distance to maintain against a threat. More...
 
float FollowDistance = 20
 AI walks closer if it is further than this distance. More...
 
bool UseCovers = true
 Is the AI using covers to follow a threat. More...
 
float FollowFromCoverChance = 0.6f
 Chance that the AI will leave the cover to follow the threat. More...
 
bool RunToCovers = false
 Is the AI running towards covers. More...
 
bool UsePeeks = false
 Should the AI continuously turn back and forward between walk direction and the threat. More...
 
float PeekDuration = 1.5f
 Duration of a peek in seconds. More...
 
float PeekDelay = 3f
 How long to wait between peeks. More...
 

Detailed Description

Moves and rotates the character motor so that it faces and follows the enemy when needed.

Member Function Documentation

◆ OnFoundCover()

void CoverShooter.AIFollow.OnFoundCover ( )

Notified by another component that a cover was found.

◆ OnInvalidCover()

void CoverShooter.AIFollow.OnInvalidCover ( )

Notified by another component that current cover is no longer valid.

◆ OnThreatPosition()

void CoverShooter.AIFollow.OnThreatPosition ( Vector3  position)

Notified by the brains of a new threat position.

Parameters
position

◆ ToKeepCloseTo()

void CoverShooter.AIFollow.ToKeepCloseTo ( KeepCloseTo  value)

Told by the brains to keep close to a position.

◆ ToStartFollowing()

void CoverShooter.AIFollow.ToStartFollowing ( Vector3  position)

Told by the brains to follow a position.

◆ ToStopFollowing()

void CoverShooter.AIFollow.ToStopFollowing ( )

Told by the brains to stop following.

Member Data Documentation

◆ AvoidDistance

float CoverShooter.AIFollow.AvoidDistance = 10

Distance to maintain against a threat.

◆ FollowDistance

float CoverShooter.AIFollow.FollowDistance = 20

AI walks closer if it is further than this distance.

◆ FollowFromCoverChance

float CoverShooter.AIFollow.FollowFromCoverChance = 0.6f

Chance that the AI will leave the cover to follow the threat.

◆ PeekDelay

float CoverShooter.AIFollow.PeekDelay = 3f

How long to wait between peeks.

◆ PeekDuration

float CoverShooter.AIFollow.PeekDuration = 1.5f

Duration of a peek in seconds.

◆ RunToCovers

bool CoverShooter.AIFollow.RunToCovers = false

Is the AI running towards covers.

◆ UseCovers

bool CoverShooter.AIFollow.UseCovers = true

Is the AI using covers to follow a threat.

◆ UsePeeks

bool CoverShooter.AIFollow.UsePeeks = false

Should the AI continuously turn back and forward between walk direction and the threat.


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