Making a giant mesh

Hey guys, i’m trying to get all my meshes to stick together and make one giant one, does anyone know how to achieve this?
At the moment i’m drawing one mesh for every face of a block (6) and replicating it for every block drawn (256) which means i’m having to draw 1536 different objects (not including the Z axis, otherwise it would be 1536 x Z) so does anyone know of a way to make all of the meshes combine and make 1 giant one?

Thanks - Shamus

GeometryBatchFactory for static objects, BatchNode for single, movable objects. Documentation is available right through the links up and to the right as well as in the SDK via F1.

Edit: For block worlds or similar, search for “voxels”, box worlds are not made out of boxes. Generally look at https://wiki.jmonkeyengine.org/legacy/doku.php/jme3:advanced:custom_meshes to get a handle on how the big boys do this kind of stuff :wink:

Okay, i tried using optimize, but it keeps saying ‘Required - Node, Found - Spatial’ When my node clearly isn’t a spatial?

@normen said: For block worlds or similar, search for "voxels", box worlds are not made out of boxes. Generally look at https://wiki.jmonkeyengine.org/legacy/doku.php/jme3:advanced:custom_meshes to get a handle on how the big boys do this kind of stuff ;)

Aha, i know they’re not make out of boxes, i am using custom meshes and am going to record their positions in an array so when i hit it, it updates the main mesh to notify it of the loss, dunno if that’s gonna refresh the whole world or what though? Guess we’ll find out :stuck_out_tongue:

@shamushay said: Okay, i tried using optimize, but it keeps saying 'Required - Node, Found - Spatial' When my node clearly isn't a spatial?
I tried using optimize and it optimized my node just fine.
@shamushay said: Aha, i know they're not make out of boxes, i am using custom meshes and am going to record their positions in an array so when i hit it, it updates the main mesh to notify it of the loss, dunno if that's gonna refresh the whole world or what though? Guess we'll find out :P
We have working box world plugins in the repository. In the SDK go to Tools->Plugins and install the "Cubes" jME3-Library.
@normen said: We have working box world plugins in the repository. In the SDK go to Tools->Plugins and install the "Cubes" jME3-Library.

Yeah, i’ve been playing around with them, Just wanna give my own a go :slight_smile: