Jump to content
  • Advertisement
Sign in to follow this  

Voxel engine destroy object

This topic is 1091 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hi all,


we are about to start to develop our 3D voxel shooter game,

we have done with our 3d models and environment and we realized something,


we saw in some shooter games that when an object or a character is shot, only a certain part of the object is destroyed

so how to handle it? was it modeled separately? like let say, if i shot thru a square head of a character, there will be a hole inside the character.

coz if it is modeeled as one, then there wont be any vertex on it right? so that means it is modelled as different tiny squares? its not efficient i think.


so how to eiffciently approach this?

here is an example to what i meant:



we are using our own engine written in C++/OGL by the way.


Share this post

Link to post
Share on other sites

Well, a voxel engine should by definition allow such operations. But it sounds like you "just" have content with a voxel-y look for a traditional engine.

You have two possibilities:

1. Define the damaged variants of your meshes in advance and create the content. This of course allows only for a limited set, say ripped off heads and limbs (it will always look the same). There's an GPU Pro article about this to improve performance: Authored structural damage. Basically they have flags per vertex which allows for masking per drawn instance. Not sure this applies here, I fear you might get z-fighting.

2. Create a real voxel renderer, which allows creating meshes on the fly from a volume representation (or rather only when they change shape). You could have a look at the various open source minecraft engines how to dynamically create meshes, e.g. minetest. But yeah, doing this efficiently is a challenge sad.png .

PS: Merry Christmas

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!