McJtyMods / InControl

Be In Control of Mob Spawns and others
MIT License
46 stars 17 forks source link

[1.16.5] Game freezing/getting stuck on tick? #282

Open BigMartin58 opened 3 years ago

BigMartin58 commented 3 years ago

InControl! is causing my game to get stuck on a single tick and after 180 seconds, the game forcibly closes. What may be causing it and how do I remedy the situation?

Edit: Just to note, this seemingly happens only when I go underground.

Crash Log: crash-2021-08-28_14.27.28-server.txt

Also link to text-paste if you don't want to download: https://bit.ly/3jp5qo2

McJty commented 3 years ago

Can you show me your json rules?

BigMartin58 commented 3 years ago

spawn.json spawner.json

The spaces in the spawn.json are due to large-scale editing. I'm pretty sure it's not causing the problem since I also use a json verifier.

McJty commented 3 years ago

I'll check it out. You do have a HUUUGE spawner.json though. I think you might reduce that somewhat by combining rules (you can put multiple mobs in a single spawner rule)

BigMartin58 commented 3 years ago

That's good to know. I'll definitely look into combining some rules.

BigMartin58 commented 3 years ago

Ok, so I was able to rework my spawner.json, combining some rules and I did some testing. My game still freezes after a few minutes of being underground. I have listed the updated json and a new crash log. If you have any updates, it'd be appreciated. Otherwise, no worries. I know you're probably a busy person.

spawner.json crash log

McJty commented 3 years ago

I will check it out soon

McJty commented 3 years ago

Oh I just noticed you're not using the latest In Control. Please always use the latest version of my mods. Otherwise bug reports really are not useful

BigMartin58 commented 3 years ago

Yes. I recently noticed and updated. The problem persists.

New Crash Log

McJty commented 3 years ago

I think I might have an idea what is going on. Investigating...

BigMartin58 commented 3 years ago

If it helps, I did some more testing and the freeze always happens once I am around y=36/37.

McJty commented 3 years ago

Yes indeed. It has to do with the height you are at

BigMartin58 commented 3 years ago

Did more testing. Thought there might be a conflict with some of the mods listed in the crash report that use mixin, but can confirm, after disabling all of them, including optifine, the freeze still occurs.

New crash log

P.S. I don't mean to be bombarding you, I'm just trying to help debug.

McJty commented 3 years ago

It's ok. I can handle it from here

McJty commented 3 years ago

Just released 5.2.1. Can you check that this version fixes the issue?

BigMartin58 commented 3 years ago

So far so good. Already working longer than before. I want to keep this open for a few more days, in case I encounter the problem again. Otherwise, I will close it on Sunday. Thank you very much. You are a rockstar.

BigMartin58 commented 3 years ago

I seem to be running into a new problem that may be unrelated, but it has only occurred after the update. Now mobs aren't being spawned by InControl. The only mobs that are spawning are the occasional default vanilla or lycanites mobs and even rarer does incontrol spawn a mob. I enabled incontrol's debug command and it is reading off "null" on most mobs. Is this something I did, or related to the update?

Debug Log

BigMartin58 commented 3 years ago

Never mind. I restarted my client and it fixed it.

McJty commented 3 years ago

I will close this for now. For new issues best to open new tickets. Thanks for testing

BigMartin58 commented 3 years ago

I encountered the original problem again.

Crash Log

McJty commented 3 years ago

Same spawner.json or did you make changes? If you can reproduce this it might help me a lot if you can try to find the rule that break it by removing rules until it starts working agin

BigMartin58 commented 3 years ago

I made some changes to my spawner.json but I deleted the changes, so it's still the same as before. I will experiment with the rules. The deadlock is a lot rarer than before. It has only happened once since the update.

BigMartin58 commented 3 years ago

It still hasn't happened again, but I will continue testing.

BigMartin58 commented 3 years ago

I had another crash and I believe it may have something to do with the Rats mod in conjunction with InControl. I have to test it, but this is my hypothesis.

Crash Log

BigMartin58 commented 3 years ago

So, I'm having some difficulties. I found a method for reproducing the deadlock, so I used it for testing. With all my rules in my spawner.json, it deadlocked when I go below y38 then back above. So I removed all of the rules and it didn't deadlock. Then I re-added each rule, one-by-one until I encountered the deadlock, reloading the config each time. Eventually, I re-added every rule and it never deadlocked. Now, even with all my rules, it doesn't deadlock. I'm at a wall. If it just needed a file refresh, awesome. But if it deadlocks again. I don't know what else to do.

BigMartin58 commented 3 years ago

Pretty Sure I finally figured it out!

Spawner.json

There seems to be an issue with vertical spawning in tandem with the spawning distance. As you can see in the rule below, the "maxdist" is 90 and the "minheight" is 128. Like I've stated, the deadlock always happens at y=38 and wouldn't you know it, 128 - 90 is 38. I have tested it multiple times now. Without it, no deadlock. The moment I re-enable it, deadlock.

The Rule:

{ "mob": ["lycanitesmobs:naxiris", "lycanitesmobs:vespid"], "persecond": 1, "attempts": 5, "amount": { "minimum": 1, "maximum": 1 }, "conditions": { "dimension": "minecraft:overworld", "norestrictions": true, "inair": true, "mindist": 24, "maxdist": 90, "minheight": 128, "maxheight": 256, "maxthis": 3, "maxtotal": 500 } },

BigMartin58 commented 3 years ago

@McJty Not trying to rush you, just notifying you.

McJty commented 3 years ago

Are you on discord? I would like to give you a preview release so that you can test out a fix I just did

BigMartin58 commented 3 years ago

Sure. Send an invite.

McJty commented 3 years ago

https://discord.gg/4wMtFKT