All Classes Namespaces Functions Variables Enumerations Enumerator Properties
plyGame.ObjectDestroyerHandler Class Reference

This class handles destroying an object. There are various ways in which it can happen like first sinking the object below the terrain before removing. This class is used by behaviours as needed. More...

Public Types

enum  DestroyMethod { DestroyMethod.DoNothing =-1, DestroyMethod.Destroy =0, DestroyMethod.SinkAndDestroy =1 }
 Method to use More...
 

Public Member Functions

void Start (Transform target)
 Called by an objet to start the destroy procedure More...
 
void Update ()
 Called by an object to have the destroy procedure update as needed More...
 

Public Attributes

DestroyMethod method = DestroyMethod.Destroy
 destroy method to use
 
float opt_a = 1f
 the opt_ variables' use depends on what DestroyMethod was chosen Destroy: opt_c is how long (in seconds) to wait before destroying the object SinkAndDestroy: opt_a = how far to sink (meters, must be positive number) opt_b = at what speed it will sink opt_c = after what timeout (seconds) will sinking start More...
 
float opt_b = 1f
 
float opt_c = 10f
 

Detailed Description

This class handles destroying an object. There are various ways in which it can happen like first sinking the object below the terrain before removing. This class is used by behaviours as needed.

Member Enumeration Documentation

Method to use

Enumerator
DoNothing 

Do not destroy the object.

Destroy 

Simply destroy after a timeout.

SinkAndDestroy 

Move a certain distance on Y and then destroy.

Member Function Documentation

void plyGame.ObjectDestroyerHandler.Start ( Transform  target)

Called by an objet to start the destroy procedure

void plyGame.ObjectDestroyerHandler.Update ( )

Called by an object to have the destroy procedure update as needed

Member Data Documentation

float plyGame.ObjectDestroyerHandler.opt_a = 1f

the opt_ variables' use depends on what DestroyMethod was chosen Destroy: opt_c is how long (in seconds) to wait before destroying the object SinkAndDestroy: opt_a = how far to sink (meters, must be positive number) opt_b = at what speed it will sink opt_c = after what timeout (seconds) will sinking start