Binding agent crashes the game

I’ve tried playing around with binding in free build mode but anytime I turn the binding agent on the game crashes.

log

Process Started

Godot Engine v3.3.2.stable.mono.official - https://godotengine.org

OpenGL ES 3.0 Renderer: Intel(R) UHD Graphics

OpenGL ES Batching: ON

Mono: Log file is: ‘C:/Users/JordM/AppData/Roaming/Thrive/mono/mono_logs/2021-08-30_11.53.29_17300.log’

This is Thrive version: 0.5.5.0

Startup C# locale is: en-CA Godot locale is: en

user:// directory is: C:/Users/JordM/AppData/Roaming/Thrive

Game logs are written to: C:/Users/JordM/AppData/Roaming/Thrive/logs latest log is ‘log.txt’

Doing delayed apply for some settings

Set audio output device to: Default

Set C# locale to: en-CA Godot locale is: en

Loaded registry for Compound with 11 items

Loaded registry for MembraneType with 6 items

Loaded registry for Background with 11 items

Loaded registry for Biome with 11 items

Loaded registry for BioProcess with 13 items

Loaded registry for OrganelleDefinition with 18 items

Loaded registry for MusicCategory with 3 items

Loaded registry for HelpTexts with 5 items

Loaded registry for NamedInputGroup with 6 items

Loaded registry for Gallery with 3 items

SimulationParameters loading ended

SimulationParameters are good

Jukebox now playing from: Menu

Jukebox: starting track: res://assets/sounds/main-menu-theme-1.ogg position: 0

Previous patch doesn’t exist, despawning all entities.

Applying patch (Pangonian Vents) settings

Number of clouds in this patch = 8

Registering new spawner: Name: ammonia density: 4E-05

Registering new spawner: Name: glucose density: 2E-05

Registering new spawner: Name: phosphates density: 4E-05

Registering new spawner: Name: hydrogensulfide density: 4E-05

oxygen spawn density is 0. It won’t spawn

carbondioxide spawn density is 0. It won’t spawn

nitrogen spawn density is 0. It won’t spawn

sunlight spawn density is 0. It won’t spawn

Number of chunks in this patch = 4

Registering new spawner: Name: FLOATING_HAZARD density: 0.0001

Registering new spawner: Name: SMALL_IRON_CHUNK density: 5E-05

MARINE_SNOW spawn density is 0. It won’t spawn

Registering new spawner: Name: BIG_IRON_CHUNK density: 5E-05

Number of species in this patch = 1

Registering new spawner: Name: 1 density: 1.438849E-05

Player Microbe spawned

Jukebox now playing from: MicrobeStage

TaskExecutor started with parallel job count: 4

Jukebox: starting track: res://assets/sounds/microbe-theme-5.ogg position: 0

Jukebox: starting track: res://assets/sounds/soundeffects/microbe-ambience2.ogg position: 0

Jukebox now playing from: Menu

Jukebox: starting track: res://assets/sounds/main-menu-theme-2.ogg position: 0

Entering freebuild mode

Editor going to freebuild mode because player has activated freebuild

Starting microbe editor with: 1 organelles in the microbe

Editor action is now: cytoplasm

Jukebox now playing from: MicrobeEditor

Jukebox: starting track: res://assets/sounds/microbe-editor-theme-1.ogg position: 0

Elapsing time on editor entry

TimedWorldOperations: running effects. elapsed: 1 total passed: 100000000

Applying auto-evo results

Species Chitus Nira has gone extinct in Pangonian Mesopelagic

Species Cyulosens Obia has gone extinct in Pangonian Abyssopelagic

Species Nequito Thiomia has gone extinct in Pangonian Coast

Species Lehaeidia Raroipsis has gone extinct in Pangonian Estuary

Species Snagpien Crodntor has gone extinct in Pangonian Estuary

Species Chotrum Opaspian has gone extinct in Cave

Species Utunra Cerubra has gone extinct in Pangonian Sea Floor

Species Chitus Nira has gone extinct from the world.

Species Cyulosens Obia has gone extinct from the world.

Species Snagpien Crodntor has gone extinct from the world.

Species Chotrum Opaspian has gone extinct from the world.

Species Utunra Cerubra has gone extinct from the world.

Editor action is now: nucleus

Placing organelle ‘nucleus’ at: 0, 0

Editor action is now: mitochondrion

Placing organelle ‘mitochondrion’ at: -2, 1

Placing organelle ‘mitochondrion’ at: 2, 1

Placing organelle ‘mitochondrion’ at: -1, 3

Placing organelle ‘mitochondrion’ at: 1, -2

Placing organelle ‘mitochondrion’ at: -1, 3

Editor action is now: vacuole

Placing organelle ‘vacuole’ at: 2, -1

Placing organelle ‘vacuole’ at: -2, 2

Placing

child process exited with code 3489660927

Do you mean once you finish editing and turn on the binding mode?
That log you provided ends while printing a message about a placed organelle in the editor.

Yes I finished edit. I’m now thinking that it might be the free build mode that isn’t working because I just tried playing as a plant using the free build mode and it crashed soon after I left the editor.

Can you identify a common element? Does the microbe stage work normally for example if you load a save made in the editor and exit to the stage? And also does it work if you play “normally” meaning start a new game and play through a few editor sessions?

Depending on the results, this might be a totally random crash, maybe caused by an engine bug.

Sometimes when I exit the editor the game crashes. This type of crash has never happened before the new update yet it’s been happens every few editor visits since. I haven’t had crashes at any other time except exiting the editor.

This could be related to the rendering mode change in 0.5.5.

@Maxonovien I think this thread might interest you.

Not sure this truly is related to the problem linked above, given that it seems strongly tied to thread (and I have not experienced anything related to binding agents…). The best way would be to find what error is tied to the crash, but I wasn’t able to really find it from the exit code… I’ll see if I can replicate this bug somehow.

However, since I’ve manually removed multi-threading and reinstated it again with a git stash, the game has been pretty stable. So, good news for me, but this may seem I won’t be able to replicate. I don’t really know what is going on here.
EDIT: Take that back, it just crashed

So perhaps the crash has nothing to do with the render mode? It just wants to crash randomly / due to another problem?

From what I get there seems to be a consistency with the binding agents: if placed in the editor, the game crashes for op. Pretty interestingly it seems to affect the logs (Placed … nothing here), so I suspect something related to the print instruction.

I give it that it is pretty rare for logs to end within a single log line.
However the bug reporter said that they can exit the editor. And that placed organelle message is printed before exiting the editor, so doesn’t that mean that the log message is not related to the crash?

Indeed. Can’t that hint at a null variable instead of the Organelle that should be printed? Might explain why it crashes afterwards.

I’m way certain that you can’t fail placing like that, I think there’s at least 2 places that check that you are placing an organelle properly. Also C# exceptions seem to very often actually print some kind of error. The log lines being cut off more indicates like a very serious crash inside Godot itself. Also the log message is cutoff within a static string part. If the organelle was null I expect either nothing to be printed (instead an exception is thrown) or the first string part is printed fully "Placing organelle '".
From our code perspective it makes 0 sense that the log message is cutoff at that point. It must be a native code crash on Godot’s side.

If there’s a single string, you are probably right in saying that we have a crash from Godot. It seems to be too consistent for a random crash, though… I’ve finished my editor button branch (although I’m fairly sure there are neater way to do some things, but I didn’t find them), so I’ll make the PR and try to replicate.

I think I should verify I was the one who closed Thrive. The crash I talked about only made the screen completely black. I exited the app myself because there was nothing I could do.

Well technically if the program becomes stuck, it hasn’t crashed actually. Instead it is stuck showing a black screen.