Hbm's Nuclear Tech Mod

Hbm's Nuclear Tech Mod

1M Downloads

Radioactive Barrel causes extreme TPS lag

gengyunmaster opened this issue ยท 5 comments

commented

I would like to build a mob farm with functionalities that targets in a large area can be killed simultaneously. I believe placing some Radioactive Barrels in your mod around that area must be a good way to meet my requirements courtesy to extensive damage traits of radiation. However, this scenario which works fine in the beginning comes into being to cause extremely conspicuous lag in my server. Specifically, the TPS began to decrease to less than 1.0 after half an hour of placing dozens of barrels in an area with chunk loaders and remove chunk loaders to unload chunks will restitute the TPS positively. Could you please help me to check whether the radioactive mechanism of environment was not optimized enough? Thanks for your time reading this issue.

commented

It's unlikely that it's the radiation clouds themselves, as those are particles which only exist client-side and don't affect TPS at all. There was however a recent issue that has been identified where certain checks regarding the radiation block destruction code would force chunks to load which may be the source of the lag. The issue was fixed a few days ago and will be included in the next version. If you want more clarity on what's causing lag, consider running a profiler like Spark for example.

commented

I guess there is a lot of chlorine-like fog all over the place. This rad smoke causes most of the lag in my observation. Use a demon lamp to execute mobs instead.

commented

its due to radiation clouds

commented

Thanks for your suggestion! I have profiled my server by Spark. I am not sure if the situation indicated in the following picture presents that the reason why my server has TPS lag is related to radiation, because I am not a programmer who understands logics of Java code. The report generated by Spark can be found here.
https://spark.lucko.me/kNVu0MLVSK
screen

commented

As I expected, in an effort to find out if a chunk is loaded, the world calls getChunkFromChunkCoords which inevitably ends up loading the chunk anyways, which due to being out of range immediately unloads, and that happens constantly. Expect a fix to be included in the upcoming release, probably this sunday.