Exploder issues: black voxels and too many voxels?

0
evyatron posted this 19 June 2016

Hi all,

I'm trying to use the built-in Exploder, however I'm getting two issues:

  1. All chunks are created black, regardless of the volume exploding. I tried using different materials (PBR and Diffuse) to no avail. I also tried toggling the Cast/Receive shadows on the particle system.
  2. I'm getting a lot more voxels than what was removed from the original volume - is that intended behaviour? Is there a way to make sure the explosion voxels (particles) correspond to what was removed from the volume?

Cheers

Ev

2 Comments
Order By: Standard | Newest | Votes
0
evyatron posted this 19 June 2016

Okay first issue solved, it was my own issue (layers and lighting).

Second issue still stands though!

0
GarethIW posted this 20 June 2016

Glad you solved the first problem (I didn't have a clue off the top of my head for that one!)

The number of particles created during an explosion does correspond to the number of destroyed voxels, up to a maximum of whatever is set as the Max Batch Particles on the PicaVoxel Particle System:

http://i.imgur.com/urwIXgU.png

I imagine that you are getting the correct number of particles but it just seems like too many, because it's easy to forget exactly how many voxels you're dealing with. For example, an 8x8x8 volume which seems an incredibly small number of voxels is actually 512 total voxels. If you completely exploded an 8x8x8 volume, you'd get 512 particles. Which will look like a lot.

You can change the Max Batch Particles to something smaller to reduce the number of voxels you get out of an explosion.

If you're interested in finding out exactly how many particles are being created, put a breakpoint on line 120 of VoxelParticleSystem.cs. When an explosion occurs, batch.Voxels.Count will be the number of voxels that were destroyed.


Our 125 members have posted 459 times in 111 discussions