DoopelPonger
Public Member Functions | Public Attributes | List of all members
TutorialBadCannon Class Reference

Object used to fire bullets directly at a player to make sure they know how to use the shield. More...

Inheritance diagram for TutorialBadCannon:
Inheritance graph
[legend]
Collaboration diagram for TutorialBadCannon:
Collaboration graph
[legend]

Public Member Functions

void Awake ()
 Initialize references needed. More...
 
void Init (System.Action animationFinished)
 Reset all state of the object as if it was brand new. Also trigger the fade in from nothing. More...
 
void StartFiring (System.Action animationFinished)
 Start the cannon firing the numberOfShotsToFire. More...
 
void StopFiring ()
 Force the cannon to stop firing, even if not all the bullets have been fired. More...
 
void FixedUpdate ()
 Fire bullets, wait, or fade in/out depending on what methods have been called. More...
 

Public Attributes

Transform firePosition
 
float timeBetweenShots
 
CoopBadBall badBallPrefab
 
CoopPlayer playerToAttack
 
float ballMovementVelocity
 
int numberOfShotsToFire
 
float timeToTransitionIn
 
float timeToTransitionOut
 
MeshRenderer [] meshRenderers
 

Detailed Description

Object used to fire bullets directly at a player to make sure they know how to use the shield.

Member Function Documentation

◆ Awake()

void TutorialBadCannon.Awake ( )

Initialize references needed.

◆ FixedUpdate()

void TutorialBadCannon.FixedUpdate ( )

Fire bullets, wait, or fade in/out depending on what methods have been called.

◆ Init()

void TutorialBadCannon.Init ( System.Action  animationFinished)

Reset all state of the object as if it was brand new. Also trigger the fade in from nothing.

Parameters
animationFinishedCallback for when the cannon is fully visible.

◆ StartFiring()

void TutorialBadCannon.StartFiring ( System.Action  animationFinished)

Start the cannon firing the numberOfShotsToFire.

Parameters
animationFinishedCallback for when all shots have been fired.

◆ StopFiring()

void TutorialBadCannon.StopFiring ( )

Force the cannon to stop firing, even if not all the bullets have been fired.

Member Data Documentation

◆ badBallPrefab

CoopBadBall TutorialBadCannon.badBallPrefab

Bullet prefab to spawn.

◆ ballMovementVelocity

float TutorialBadCannon.ballMovementVelocity

How fast the bullet should move.

◆ firePosition

Transform TutorialBadCannon.firePosition

Place bullets should spawn from.

◆ meshRenderers

MeshRenderer [] TutorialBadCannon.meshRenderers

Renderers used to change the alpha when becoming (in)visibile.

◆ numberOfShotsToFire

int TutorialBadCannon.numberOfShotsToFire

Number of bullets to shoot.

◆ playerToAttack

CoopPlayer TutorialBadCannon.playerToAttack

The player to aim at.

◆ timeBetweenShots

float TutorialBadCannon.timeBetweenShots

The time to wait before firing the next bullet.

◆ timeToTransitionIn

float TutorialBadCannon.timeToTransitionIn

The amount of time it takes to become visible.

◆ timeToTransitionOut

float TutorialBadCannon.timeToTransitionOut

The amount of time it takes to become invisible.


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