Birdoggydog's Builds

Fixing three Breakout Site problems I found playing in Godot

A locker code nobody could find, furniture blocking the cupboards, and a flickering lamp. How I traced each one to a rule instead of a single room.

I played through the Breakout Site and drew three notes in the game. Each turned out to be a fix for a rule, not for the one spot I’d pointed at. Carl now tells you his locker’s code, no furniture stands in front of a cupboard, and the ceiling lamps stopped flickering.

50 seconds: Carl asked about the locker and giving the code, the marker on the map, the locker opened on the keypad, a bunk room with every front clear, and a lamp walked round from every side.

How can you find the locker’s code?

My note said there was no way to find the keycode for this chest, and that probably Carl should mention he has a chest in his office and tell you the combo. Picking the lock is still a way in, with a 1 in 10 chance for Gristle. But nothing in the game said the code at all.

Carl’s last answer did say it, but that’s easy to miss. So I gave him a new option, “Is there anything here worth taking?”. His answer names his office, east along floor 1, the locker against the far wall, and the code in words: four, zero, zero, four. It also adds a map marker on his office room, labeled “Carl’s locker: code 4004”. His last answer adds the same marker. The game has no journal of things you were told, so the marker is how it remembers.

A test reads the code back out of his words, then opens the locker on the keypad with it. It has 23 checks.

Why did the furniture block the cupboards?

The note was about one bunk room: “This organization of stuff leaves the cupboards unusable and looks strange”. A tall cupboard, a chest of drawers and a smaller case were crammed into a corner, one against the doors of the other. I could have moved things in that room, but the dresser had no idea a wardrobe needs floor in front of it, so every room could do this.

So a prop that opens now has an opens depth in meters in content/dressing.json. A wardrobe is 0.75, a cabinet 0.55, a locker 0.65 and a safe 0.6. The dresser’s grid for each room keeps two lists of boxes, what stands and the floor kept clear in front of each piece that opens. A spot is refused in three cases:

  • Its body would stand in someone’s kept front.
  • Its own front would overlap a piece that’s already there.
  • Its front would run into rock or out of the room.
static func front_box(box: Rect2, front: Vector2i, depth: float) -> Rect2
func clear_before(box: Rect2, front: Rect2) -> bool
func stand_box(box: Rect2, front: Rect2) -> void

Rooms get furnished two ways in the game, from templates and round-robin and by seating things around a host, and the check is in both. Seating a chair at a desk checks the chair’s front too. I shrink each box by a centimeter first, so pieces that merely touch don’t count as overlapping.

I counted blocked fronts over every room on the Breakout Site’s floors. Before there were 19, in 9 rooms. After there are 0, and the floor still holds the same 355 pieces. A switch turns the rule off so the test can lay the same rooms with the same seed both ways.

Why did the ceiling lamp flicker?

The note said “This light is glitching strangely as you move more or less black is visible”. Looking up at the lamp, its cyan face had a black shape inside it that changed with the view. That’s z-fighting, two surfaces drawn in the same plane.

I measured the model. The lit disc sits at y = 0, in exactly the plane of a 0.13 m cap on the lamp’s housing. My first try was growing the glow material along its normals to push the disc out. The disc’s rim has smoothed normals pointing outward, so that cut a dark seam through the housing’s lip instead.

What worked was splitting the mesh when the lamp loads. Every surface whose material name ends in _glow goes into a second mesh, a child named Glass, set 4 mm lower. Everything else stays where it was. It runs on every operating lamp in every state, and the model file itself is untouched. I filed the proper fix in the model generator as its own item.

Over five views, the dark pixels inside the disc ran from 53 to 999 before. After, the only ones left are the crosshair’s 26.

Two rows of five close-ups of a round ceiling lamp seen from below. In the top row each cyan disc has a different black shape inside it. In the bottom row every disc is solid cyan.

The lamp’s lit disc from five views. The top row is before, the bottom row after.

Also done

  • A suite of 25 related tests ran with none failing, and content validation came back with 0 errors.