@XerroLP said:
I understand how Perlin Noise works and what noise is on a technical level.
What I can’t understand is how you can come across an equation that would accomplish the task of creating a good heightmap.
There are hundreds and hundreds of articles on exactly that all over the web. I think if you search for “fractal terrain generation” you will find lots of info. Use “fractal terrain generation with perlin noise” if you want something more specific.
The topic is pretty huge. The simple answer, plug a scaled down x, y (divide by frequency) into perlin noise and use the value to scale your height. Do that again at a different frequency if you want more variation… add or multiply that value with the first. But really now there are about 6 different main ways you could go… as I said, it’s a deep topic and the web is bursting with content on this every since Minecraft became a thing. And there was plenty even before that.
@lawsy said:
Wow, this is looking really good, great work! love that tree too :)
Voxel worlds are new to me, but very interesting in learning and creating these types of worlds, care to share ideas?
hi, sure! Just shoot!
The last weeks I was a bit inactive, and I pretty much rounded of the engine/learning stuff.
I am playing with an idea of a game now, think the legend of zelda set in a cartoony block world with heavy RPG elements in it. (the windwaker style)
At the moment I am trying to implement a good responsive third person camera.
I also switched the controls from keyboard input to a controller (I am using my ps3 controller) and this was actually pretty straight forward!
My previous attempt of the character control and the first person perspective had a lot of problems, and with the use of the cookbook, I started over based on the BetterCharacterControl and the ChaseCamera.
When the controls are finished, I’ll upload a video of the results. But it will take some more time and finetuning, as this is for me the make-or-break element of a game.
Yes me too, going for that block cartoony theme, currently focusing on a multi-player voxel world with pirates, where players can explore the ocean depth or search for islands, with player created ships, submarines and zeppelins voxel vehicles, have prototyped the voxel vehicles with battling and repairing while in combat, all tests went very well, but ATM focusing on the voxel world engine which is an extension of the cube framework and greedy meshing, have named the engine (Greedy Vox) and have a couple of videos here the videos lost some game rendering quality, but these videos are more of a history version of the engine progress.
Also purchased both jmonkey cookbooks, and have implemented some of the features found in the books. Since we have similar voxel engine project, Thought it would be good to bounce ideas of each other, and would be happy to share anything of interest, currently I am networking chunk data for server and clients, have managed to store all block data into a 64-bit long variable, which has proven to be very fast and low on memory, but still in the stages of flushing out networking bugs.
Really like your water, was thinking of doing something similar, at the moment culling all face of a water block except the surface face, just as a place-holder until I am ready to make a better looking ocean, any tips or advice in making a nice ocean?
PS: had to edit this post, added html code by accident.
For the water I used a transparant material, with a shader that lowers the y coördinate by 0.1f or 0.2f to create the ‘feeling of depth’.
But my water needs some serious rethinking. After the third player camera finetuning, I will be looking into cellular automata for the water, and at the moment I don’t really have an idea how I will be implementing this.
Each chunk has up to a maximum of 2 meshes. One ‘normal’ terrain mesh, and one water mesh. But I have no idea what the impact on the performance will be on really stretched out oceans or lakes. Since each block will needs it’s own control to check the amount of water that this block contains. Maybe I will need a ‘watercontrol’ on a chunk per chunk basis, I really don’t know at the moment…
I have one extra mesh when needed for transparent blocks such as glass blocks, not sure if that’s the best method but was the only way to stop seeing through the terrain mesh.
Oh yeah, no way would you need a cellular automata control for every chunk or body of water, a body of water like an ocean or lake, just treat it as a infinite supply of water, after all its only game mechanics.
At the very maximum using one cellular control per chunk, this control will handle all liquids inside a chunk, and when no longer have the need for flowing liquid then the control is removed.
If a liquid is flowing into a neighbouring chunk, then that chunk will add a cellular control which will continue on the flowing liquid, and just like minecraft, when you remove a block neighbouring a infinite water block source, then add a cellular control and water source location and set a volume amount.
From the cookbook cellular automata example, I just added features and changed it around a little, not creating a array for the water volume grid inside the cellular control, instead using the chunk block array as the water gird (why waste memory when you already have a chunk grid), and sharing water flow between cells, so setting a water volume, water will spread out as far as the volume of water, with downward flow direction having the highest priority, note that using this method not to set a infinite volume, cause this would kill performance, the flow of water will never stop and would spread as far as the end of the voxel world
But I sure you know from the cookbook how the cellular automata works, hope this helps, and from testing, found using this approach for fastest performance.
@remy_vd said:
For the water I used a transparant material, with a shader that lowers the y coördinate by 0.1f or 0.2f to create the 'feeling of depth'.
But my water needs some serious rethinking. After the third player camera finetuning, I will be looking into cellular automata for the water, and at the moment I don't really have an idea how I will be implementing this.
Each chunk has up to a maximum of 2 meshes. One 'normal' terrain mesh, and one water mesh. But I have no idea what the impact on the performance will be on really stretched out oceans or lakes. Since each block will needs it's own control to check the amount of water that this block contains. Maybe I will need a 'watercontrol' on a chunk per chunk basis, I really don't know at the moment...
Interesting, I haven’t fully grasp shaders, shaders for me has been a very steep learning curve never knew you could lower the water level using shaders, I used code to drop the water mesh level, and guessing the shader also decreasing the transparency of the water too?
the video tutorials on shaders where very helpful. But I still don’t know 1% of it. It’s more like trial and error.
I also have 1 ‘terrain’ mesh for the normal non transparent blocks, and 1 transparent mesh (if needed) for water and glass and … on each chunk.
Thanks for the info on the cellular automata for the water. I’ll keep you updated on my progress
@remy_vd said:
the video tutorials on shaders where very helpful. But I still don't know 1% of it. It's more like trial and error.
I also have 1 'terrain' mesh for the normal non transparent blocks, and 1 transparent mesh (if needed) for water and glass and ... on each chunk.
Thanks for the info on the cellular automata for the water. I'll keep you updated on my progress :-)
lol, I am the 99% of the population that don’t have a clue about shaders but when I get a shader to work how I wanted, its like a new years party!
I will be interested in your progress on the cellular automata, and as crazy as it may sound, I found it fun making the cellular automata code (engineers) also made a abstract class that’s used as a extension for fluids and lighting, with fluids as controls and lighting as a class but not a control, cause its just a once of calculation to baked into the mesh, where calculations are made on every chunk build.
Other plans for the future will be to make a path finding control using the cellular automata, when you have access to 3d grids (chunks), just makes perfect sense to me, cellular automata, simple maths at its best!
Hi,
I’m working on a voxel, but with a more limited size. However, the game appears to lag out (the game isn’t responding) when I try to render about a 48 x 48 x 1 area of voxel terrain. I use a set of 6 textured quads in each voxel, but I optimize. Do you have any tips for me? The eventual goal is about a 160 x 160 x 1 terrain.
EDIT: It’s not my computer, it works with simple boxes at 60 fps.
after more then 6 months of absence I am back. I had some rough time at home, but it is all falling into place now.
I am back working on YAVE, and actually a game! I’ll release some in-progress screenshots and movies in the coming days.
Keep going man! We (I as a Voxel Engine developer also) have to show to the whole world that we don’t just start developing Voxel Engine, we finish 'em!!