Firework Mesh (Component)

The firework knows how to spawn using this component.

Variables

  • Spawn Mesh Reference - requires a MeshRenderer - it takes the lowest point of the mesh and spawns the firework using that to make sure it doesnt spawn in ground. A little red sphere is visible with Gizmos on the bottom of the mesh, indicating the spawn point of the firework.

  • Mesh Bounds Position - adjusts the position of the spawn position, should be used for rockets to make sure it is on the stick for it to spawn properly in the rack. You can see it visually adjusted by the red sphere.

  • Rotation On Spawn - determines the rotation when the prefab gets spawned.

  • Material Type - can be Soft or Hard, determines the sound the object does when it gets hit or hits something else, causing a change in sound.

  • Object physics sound surface - takes Object Surface as the value. Determines all the sound when the object reacts using physics.

Troubleshooting

  • If the red sphere from Spawn Mesh Reference is not on the bottom or just not where you want it to be, you can add an Empty GameObject, add a Mesh Renderer component to it and set its position to where you want the spawn position to be. You can drag it into the Spawn Mesh Reference then.

Last updated