Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

Hello all, I have been developing a mod which is going to require a large number of new dimensions soon. I am having difficulty understanding how the World, WorldProvider, BiomeGenBase, Chunk, and ChunkProvider classes all work together. I have made an educated guess but I would like to have my ideas validated.

 

Before I start, I know that there are lots of existing tutorials. I have not been able to get the big picture out of them because they guide the reader through lots of small steps, instead of explaining the purpose of each class. I am not new to Java or coding and all I want to learn is the API. So please answer this question instead of re-directing me to a tutorial. Thanks for your time.

 

What I'm guessing is that when a Chunk is created for the first time, it uses a ChunkProvider to generate its basic terrain (probably stone and perhaps caves and such?) using the Perlin noise algorithms. Then the appropriate BiomeGen adds the layers of soil, ores, trees, and other decorative blocks? The WorldProvider determines which BiomeGen's to apply to each chunk, and handles such things as multi-biomed worlds (WorldProviderSurface) and single-biomed worlds (WorldProviderHell). Does all this seem to be correct?

 

And which methods should I override to control the stone population process? I am fairly sure that I can control dirt, sand, trees, and all such features with BiomeGen, but I can't figure out how I would remove all blocks from a chunk, which I will need to do to create a space dimension.

 

Once again, thanks in advance for your help.

Guest
This topic is now closed to further replies.

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.