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

Animation delegate used to change the size and color of the light behind the player. More...

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

Public Member Functions

override void Init (Animator playerAnimator)
 Initialize the animator. More...
 
override void PlayerBadBallHit ()
 The player has been hit with a bad ball. More...
 
override void PlayerGoodBallHit ()
 The player has been hit with a good ball. More...
 
override void PowerUpActivated ()
 The player has activated a power up. More...
 
override void PowerUpChargeChange (float percentCharge, bool prematureActivation)
 The amount of charge the player has has changed. More...
 
override void PowerUpDeactivated ()
 The player has had their power up run out. More...
 

Public Attributes

Color minColor
 
Color maxColor
 
Vector3 minSize
 
Vector3 maxSize
 
Texture2D [] noiseTextures
 
float swapRate
 

Detailed Description

Animation delegate used to change the size and color of the light behind the player.

This light is used to accent the current power up charge value with the scale and color changing based on the amount of charge. There is also a twinkle animation used by moving the verticies of the texture random in the x and y axis.

Member Function Documentation

◆ Init()

override void CoopPlayerLightAnimatorDelegate.Init ( Animator  playerAnimator)
virtual

Initialize the animator.

Parameters
playerAnimatorThe Unity animator component on the CoopPlayer gameObject.

Implements CoopPlayerAnimatorDelegate.

◆ PlayerBadBallHit()

override void CoopPlayerLightAnimatorDelegate.PlayerBadBallHit ( )
virtual

The player has been hit with a bad ball.

Implements CoopPlayerAnimatorDelegate.

◆ PlayerGoodBallHit()

override void CoopPlayerLightAnimatorDelegate.PlayerGoodBallHit ( )
virtual

The player has been hit with a good ball.

Implements CoopPlayerAnimatorDelegate.

◆ PowerUpActivated()

override void CoopPlayerLightAnimatorDelegate.PowerUpActivated ( )
virtual

The player has activated a power up.

Implements CoopPlayerAnimatorDelegate.

◆ PowerUpChargeChange()

override void CoopPlayerLightAnimatorDelegate.PowerUpChargeChange ( float  percentCharge,
bool  prematureActivation 
)
virtual

The amount of charge the player has has changed.

Parameters
chargePercentThe amount of charge the player has from 0 to 1
prematureActivationMeans that the player tried to use their power up before actually having a full charge.

Implements CoopPlayerAnimatorDelegate.

◆ PowerUpDeactivated()

override void CoopPlayerLightAnimatorDelegate.PowerUpDeactivated ( )
virtual

The player has had their power up run out.

Implements CoopPlayerAnimatorDelegate.

Member Data Documentation

◆ maxColor

Color CoopPlayerLightAnimatorDelegate.maxColor

The color the material should be when the player has full charge/currently has a power up activated.

◆ maxSize

Vector3 CoopPlayerLightAnimatorDelegate.maxSize

The scale of the texture when the player has full charge.

◆ minColor

Color CoopPlayerLightAnimatorDelegate.minColor

The color the material should be when the player has no charge.

◆ minSize

Vector3 CoopPlayerLightAnimatorDelegate.minSize

The scale of the texture when the player has no charge.

◆ noiseTextures

Texture2D [] CoopPlayerLightAnimatorDelegate.noiseTextures

The images of noise to offset the verticies of the light texture.

◆ swapRate

float CoopPlayerLightAnimatorDelegate.swapRate

The amount of time a texture should be used before swapping to the next one


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