C# Class BallController, Imagine_fudge-roll

Inheritance: MonoBehaviour
Afficher le fichier Open project: Microsoft/Imagine_fudge-roll Class Usage Examples

Méthodes publiques

Свойство Type Description
cameraSensitivity float
cameraTransform Transform
highRollSound AudioClip
lowRollSound AudioClip
moveSpeed float
stickyStages StickyStage[]

Méthodes publiques

Méthode Description
ChangeMovementSound ( ) : void

Changes the ball rolling sound to the correct one for our current stickiness.

FixedUpdate ( ) : void

Logic that runs at fixed time intervals regardless of frame time.

OnCollisionEnter ( Collision collision ) : void

Logic that runs when the ball collides with another object

SetStickyness ( int index ) : void

Sets the stickyness.

Start ( ) : void

Logic that runs when the object is initialized.

StartMovementSound ( ) : void

Starts audio for ball movement.

StopMovementSound ( ) : void

Stops ball rolling audio.

Update ( ) : void

Logic that runs every frame.

Private Methods

Méthode Description
CanStick ( GameObject other ) : bool

Determines whether this instance can pick up the specified object.

Method Details

ChangeMovementSound() public méthode

Changes the ball rolling sound to the correct one for our current stickiness.
public ChangeMovementSound ( ) : void
Résultat void

FixedUpdate() public méthode

Logic that runs at fixed time intervals regardless of frame time.
public FixedUpdate ( ) : void
Résultat void

OnCollisionEnter() public méthode

Logic that runs when the ball collides with another object
public OnCollisionEnter ( Collision collision ) : void
collision Collision Collision.
Résultat void

SetStickyness() public méthode

Sets the stickyness.
public SetStickyness ( int index ) : void
index int Level of stickiness.
Résultat void

Start() public méthode

Logic that runs when the object is initialized.
public Start ( ) : void
Résultat void

StartMovementSound() public méthode

Starts audio for ball movement.
public StartMovementSound ( ) : void
Résultat void

StopMovementSound() public méthode

Stops ball rolling audio.
public StopMovementSound ( ) : void
Résultat void

Update() public méthode

Logic that runs every frame.
public Update ( ) : void
Résultat void

Property Details

cameraSensitivity public_oe property

public float cameraSensitivity
Résultat float

cameraTransform public_oe property

public Transform cameraTransform
Résultat Transform

highRollSound public_oe property

public AudioClip highRollSound
Résultat AudioClip

lowRollSound public_oe property

public AudioClip lowRollSound
Résultat AudioClip

moveSpeed public_oe property

public float moveSpeed
Résultat float

stickyStages public_oe property

public StickyStage[] stickyStages
Résultat StickyStage[]