Skip to content

Fixing a crash we got on our server - #1529

Open
Mallowwww wants to merge 1 commit into
ryanhcode:mainfrom
Mallowwww:main
Open

Fixing a crash we got on our server#1529
Mallowwww wants to merge 1 commit into
ryanhcode:mainfrom
Mallowwww:main

Conversation

@Mallowwww

Copy link
Copy Markdown

Hi, we had an issue recently where someone did some weird combination of things and broke a nearby contraption to the point that the entire server crashes upon loading the chunk. I narrowed down the issue to a missing null check when attempting to find the center of mass of the contraption. From what I saw, there IS a null check, but it happens slightly later in the initialization Mixin which leads me to believe that this was unintentional. All I did was expand out a line so I could verify the center of mass exists before continuing.

I won't be too butthurt if you decide to fix this some other way; I just thought it would be worth a PR so you could look at it yourself. I do not fully understand the circumstances required in order to cause this bug, and I was unable to recreate it myself, outside of the broken chunk on our server. I suspect it has to do with a race condition of some kind where the contraption has not figured out its sable data before initializing.

The player told me he was using a steering wheel while standing on a contraption when it broke. My best guess is that rapid assembly/disassembly of a contraption due to the steering wheel has something to do with it. From what I was told, there was not a sublevel anywhere nearby, so it's likely that the contraption Mixin is the sole culprit.

@CLAassistant

CLAassistant commented Aug 31, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants