Drillgon200 / Hbm-s-Nuclear-Tech-GIT

My fork of the HBM's nuclear tech mod.
47 stars 19 forks source link

1.12.2 server "cascading worldgen lag" #224

Open hl2jeep opened 2 years ago

hl2jeep commented 2 years ago

whenever anyone on my server moves, it causes hbms to cuase worldgen lag, this leads to having a single tick last 60 seconds and the server shutting down. any way to fix this?

Faolon12 commented 2 years ago

I also have this issue, it is eating up my server resources.

Shibva commented 2 years ago

same here

also I was a fried of drillgon200;

willbowden commented 2 years ago

@Drillgon200 PLEASE can you or the rest of the team make some changes to address this cascading worldgen lag? It's making playing HBM almost impossible. There's a forum post on forge.net with an explanation on how to improve your worldgen code to prevent serious lag spikes.

Shibva commented 2 years ago

I dont even think Drill is working on this anymore, someone else took his place or something and only steps in in specific circumstances

although idk who took over

Drillgon200 commented 2 years ago

Could you upload a log and also profile it to ensure that it really is the cascading world gen causing lag? Make sure the structure aren't set too close together in the config. Fixing this requires rewriting all of the structure generation code. The structure generation code is not data driven, which makes it a massive pain to change anything. The original port had me go through the whole thing with a bunch of regexes for hours to transform the setBlock calls, and I'm in no mood to do that again without some proof that it really is the cascading world gen and not something else in the mod like the gas blocks or whatever.

Shibva commented 2 years ago

oh hey, long time no see

I do have something about that, apparently, something about the generation odds appears to break in superflat worlds or something that causes the desert structures to appear very often (the meteor dungeon seems to be working as it should)

Idk if its a generation bug in the game itself because of how superflat works but I thought I would give this tidbit of knowledge to possibly test this cascading issue

its also probs not a bad idea to use an extended log config

on another note, those gas pockets seem to be more prone to explosions due to some alternate cave gen stuff

thats all I have to say on it

Drillgon200 commented 2 years ago

It's not really a bug. NTM tries very often to place structures because most of the attempts fail on a regular world. The checks succeed close to 100% of the time on a flat world, so nearly all of the structures get placed.

Drillgon200 commented 1 year ago

I did a bit of testing on this again recently, and still couldn't find any major issues caused. I never saw it go above 4 cascades (and that was a rare case), which really isn't that much (4 cascades means it had to generate 4 chunks at once instead of 1). That's certainly not enough to cause 60 second ticks. If NTM is in fact the source of this lag, it's probably something other than cascading world gen.

hl2jeep commented 1 year ago

@Drillgon200 sorry for the super late response I haven't checked this convo in ages, I'll get a log file as soon as I can FTP into my host.

makaooo1 commented 1 year ago

Hi I have the same problem, it would seem it starts loading chunks from the middle of the world, on line 1687 it starts it and keeps going. Here is my servers log: https://mclo.gs/9jSaBlt Im also running a quite bit of mods so those could also contribute to the problem but the log says its HBM.

Shibva commented 1 year ago

Weight center of the world?

There was an old ore generation that only generates the center of the world

Curious

makaooo1 commented 1 year ago

Tested with just HBM and didnt notice any lag, I flew around in creative little over 10mins. Log still shows constantly the same cascading worldgen lag message Here is the HBM only server log: https://mclo.gs/xZfmJfB

I guess im just overloading my server, im running it on 16gb of ram and hosting it on exaroton since i just casually play sometimes with few of my friends so their payment method fits me. Shame if their servers cant handle all my mods(54), if so ill just have to drop a few off them.