Skip to content
This repository has been archived by the owner on Feb 16, 2024. It is now read-only.

Oil Generation disobeys chunk borders causing chunk loading during worldgen #18

Open
Cydhra opened this issue Jul 20, 2019 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@Cydhra
Copy link
Member

Cydhra commented Jul 20, 2019

During world generation forge outputs warnings that are (probably) caused by oil generation:

[15:25:26] [Server thread/WARN] [FML]: Technocracy Foundation loaded a new chunk [-14, 24] in dimension 0 (overworld) while populating chunk [-15, 24], causing cascading worldgen lag.
[15:25:26] [Server thread/WARN] [FML]: Please report this to the mod's issue tracker. This log can be disabled in the Forge config.

This is (again: probably) because the oil generation disobeys chunk borders and spans multiple chunks instead of waiting for the next chunk to generate.

This could (probably) be fixed like this:

When generating oil lakes for a chunk, ask the random number generator for all lakes in the eight neighbor chunks as well. Then, check whether those overlap with the current chunk and generate only the overlapping parts. Lakes that are centered in the current chunks shall never generate the parts that overlap into neighboring chunks. This way, a chunk may generate only partial lakes, but as soon as the next chunk is generated, the other part is filled as well.

@Cydhra Cydhra added the bug Something isn't working label Jul 20, 2019
@Cydhra Cydhra assigned Cydhra and Pokemonplatin and unassigned Cydhra Jul 20, 2019
@Cydhra Cydhra changed the title Oil Generation disobeys chunk boarders causing chunk loading during worldgen Oil Generation disobeys chunk borders causing chunk loading during worldgen Jul 20, 2019
@Cydhra Cydhra added this to the Quality Assurance milestone Jul 20, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants