Hey, im making a 3d game and right now I can only have up to 1000 block grid size without lwjgl freaking out. I would like to know if anyone knows how to have an unlimited terrain sort of like minecraft PS. Im using LWJGL

The best ideas will come from the weirdest and sometimes most f***'d up places, you just have to realize them.

Here is my guess about what you need to do. I'm sure someone else who knows more about this will be able to tell you more useful information. I assume that you have to do some sort of memory management by removing things from memory when they are far away. I believe Minecraft does this by storing "chunks" of some size and only bothering to draw the chunks that are close enough to the player. Everything else gets deleted from the GPU's memory, so you have to constantly be loading/deleting chunks as the player moves around. Again, this is only my guess about this, maybe the GPU is smarter than I think it is?

That's exactly what Minecraft does, yes. Chunks are 16x16 square and 256 deep, and only the surrounding chunks are streamed into memory from disk (or generated if they weren't already there). It does some pretty basic visibility culling (not drawing blocks you can't see), then draws it into a display list (something any modern game probably shouldn't use, preferring VBOs instead).

It's not all that sophisticated, it's a file per chunk, encoding the X and Y in the filename. Can't recall if it does any directory hashing or if it just bogs the filesystem with tens of thousands of files in one dir -- I don't really play minecraft anymore. You could use something like Berkeley DB or HSQLDB instead of the filesystem if indexing large numbers of chunks are a concern.

Really though, you need to start simple. Get your game working on a smaller map with all your chunks in memory first, then worry about streaming them in from persistent storage. You move mountains one teaspoonfull at a time.

No one's saying use the Minecraft code directly, it's only useful for Minecraft anyway. The wiki just contains a high level description of the format you can use for ideas. Even so it's not really a good idea to try to copy the format without trying to design something of your own first, since you don't want someone else's design dictating yours.

That is very true, and so to basically make an unlimited world you would have to continue on rendering blocks whenever needed. Well, never thought about it that way ut it does make a lot of sense in a way

The best ideas will come from the weirdest and sometimes most f***'d up places, you just have to realize them.

Minecraft heavily uses Display lists.They have chunks, as sproingie said, which they split up into 16x16x16 mini-chunks again. These mini-chunks have their own display list. And before compiling that display list, they look, which sides of what block are visible. Then they create these Display-Lists, and when drawing they only call that display list.

The reason for the chunks being split up into 16x16x16 mini-chunks is, that everytime you break a block, or build a block, minecraft has to recalculate the display-list.

I have class called Nod, hi have 3 dimension arrayShort[][][] (better use 1 dimension ,but 3 dim better for debug)Every nod have links to near NodsLikeNod LeftNod Right,Nod TopYou can hold them all not sorted in simple arraylist, same easy you can add new one

For render I use part of Nod (nod Quit big)And create display list, why display ? test show display faster then VBOIts quit simple get access to data in near nods, and + you have unlimited Y axis, not ZX like MinecraftCheers

Also I decide that’s all games I relize will be fully free without payments, or stupid ads.Maybe later add free donations, but not now I really want do open source, but cant, its may produce to many not quality clones.

I don't feel so dumb now - I was planning on chunking the landscape myself.

But what about VERY far way stuff, like a mountain which might be two chunks away but still would be visible... Is there a way of rendering a horizontal projection of a scene to am image that can then be used as a backdrop? Or is that planned for OpenGL 9?

there are a lot of different LOD(Level of Detail) approaches out there, Imposters(rendering an image of a far a way object and displaying then only the image) is one of the many.

Just from the top of my head, when you already have a world like Mincraft(lots of blocks) which are in a way Voxels. Why not try some LOD methods which are used for Voxels, one thing Voxels a really great for in comparison to triangle meshes.

Lets say your normal chunk has Data for 100x100x100 single blocks which you render by converting the data to some triangle mesh which treats each block as one cube.Now you could easily add something to your conversion process to change how detailed this generated triangle mesh should be.For example instead of creating 100x100x100 cubes why not create only 10x10x10 cubes for chunks which are far away.

Hey, im making a 3d game and right now I can only have up to 1000 block grid size without lwjgl freaking out. I would like to know if anyone knows how to have an unlimited terrain sort of like minecraft PS. Im using LWJGL

java-gaming.org is not responsible for the content posted by its members, including references to external websites,
and other references that may or may not have a relation with our primarily
gaming and game production oriented community.
inquiries and complaints can be sent via email to the info‑account of the
company managing the website of java‑gaming.org