Skip to main content

The Culprit

·287 words·2 mins

Okay. Progress.

Unearthed hangs for several seconds after the intro sequence and I haven’t been able to figure out why. Partly because it doesn’t seem to happen on my machine, even in browser. So I finally set myself up so I can run Linux and Windows at the same time.

First I tried adding some debug output. Just a way to see when things are getting called so I can search for delays. Had to do it this way because I can only seem to duplicate the issue in the browser.

By the way, it’s kinda nice to see Prima again. Been a while.

It seems like the issue was happening after the room was completely initialized. It wasn’t the loading taking a long time, or the initialization. Probably one of the children initializing.

I removed a bunch of stuff to see if it would fix it. Something worked. The problem is gone. Now I just need to narrow down what the issue actually was.

I’ve removed:

  • music
  • effects layer
  • hiding spots
  • tunnels (and the crates blocking them)
  • doors with the signs
  • diary entries

Maybe loading the shaders is taking a while?

Aha, it wasn’t the shaders it was the GPU Particles. The firefly effect we’re using to highlight diary entries and tunnel entrances is causing the lag. Phew, found it!

I will forever have an association in my head between lag / hanging and GPU particle effects.

I added the particles to the main game page as a test and that caused the rest of the game to run just fine. Good good. Problem is, the Godot loader hangs for several seconds when its progress bar is at 100%.

So where should I load this thing?