In a destructible voxel terrain system, I’m comparing generating collision meshes from visible block faces versus merging adjacent solid blocks into larger AABB colliders per chunk, since terrain is mostly static but can change when blocks are edited, and I want to know which method scales better in performance and update cost in modern voxel engines;
additionally, when blocks are destroyed, I plan to spawn particles that visually match the broken block by sampling random UV regions from the same texture so each fragment looks unique, then make these particles fall and lerp toward the block space below to simulate debris accumulation, and I’m interested in how engines efficiently handle many simultaneous block-break particle effects
title should be merged aabb collider vs fake collider. Collision mesh is not good for performance. By fake collider I meant literally checking voxel data “Is there an air or solid block?” then stop or let player to move.
For block collider I think I will just do merged AABB boxes. I just want to let engine physics handle rest of it
For block break particles, when a block is destroyed I want to spawn small fragments that sample a random UV region from the block’s texture, fall, and eventually come to rest on the terrain surface. I’m not sure if defold’s particle fx system is capable enough for this specifically I could fake the behavior with a bounce tween to simulate debris settling, but before going that route I’d like to know if particle fx supports any of this out of the box:
can particle fx interact with colliders so particles actually land on terrain instead of passing through it?
Is there a built-in billboard mode?
Can I set random textures from atlas to particles?
Or do I need to implement all of this manually in code by using sprite maybe?
can particle fx interact with colliders so particles actually land on terrain instead of passing through it?
The particles emitted from the Particle FX component is not interacting with collision objects, so no, there is no such solution for them, but you could of course do this with your own spawned game objects with collision objects and sprites, like in Acid Rain or Defold Debris.
Can I set random textures from atlas to particles?
To particles in the Particle FX component - no, not yet, please follow the issue:
Is there a built-in billboard mode?
No, I would say, or at least not-so-out-of-the-box, but you can achieve it with a custom shader: