DestructibleProxy

From Superboss Games Wiki
Revision as of 22:10, 19 May 2018 by Husky (talk | contribs) (Added image as an example, added more info, increased clarity of pitch, & added *children to destroy* section - removed stub tag.)
Jump to navigation Jump to search

Attach a DestructibleProxy to an object to make it destructible by gunfire.

Options

Script menu:

https://i.imgur.com/jiU71Pl.png

Life: how many shots it takes to destroy this object.

Particle Effect: if this points to an object with a particle system on it, a copy of that object and its particle system will be created at the location of the destructible proxy whenever it is shot. You may wish to add a Timed Object Destructor to the particle system object to make sure duplicates do not sit around.

Destroy Particle Effect: this behaves the same way as the above particle effect, but only triggers when the object is destroyed.

Pitch: If you place an audio source component on the destructible object, its audio clip will be played when the object is destroyed. X and Y represent the min and max pitch shift of that clip. A value will be randomly chosen between these values and the sound pitched accordingly. As with music, 0.5 represents 1 octave down, 2 represents 1 octave up. A value of 1 means no shift at all.

Children To Destroy Change the size of the array to any number above 0 and then drag an object from the hierarchy into those slots and they will be destroyed with the original object that has the script applied to it.