Day 5.333: Cells and Membranes


Wasted much of a day again, this time on BSP map generation and doors. It's good for rectangular rooms, which are boring. Because I don't like it much, I spent a long time trying to make improvements without success. Finally I realised it's not the shape of the rooms that makes them interesting, it's what you put in them... and I've got nothing. Still, I don't want a maze.

As I said before, placing doors is tricky. There are many ways to do it, and I haven't written a BSP mapgen before so I don't know which is easiest. I went with telling the child rooms in which direction they should place a door. One child is told to connect in the direction passed in recursively from the parent, the second child is told to connect to the first. Doors are put on a list to be placed later once all walls are down.

This produces a tree-connected set of rooms (not enough doors), and breaks when you try to break up the grid doing all the things I tried: shrinking rooms, omitting rooms, omitting walls. Add more doors, check for full connectivity, restart on failure, etc.

That was Day 5. The first part of Day 6 was wasted on... *alcoves*. That alcove model from Day 4 turned out to not be aligned to the grid. Where the problem is along the Blender -> .gltf -> Godot scene -> Godot MeshLibrary chain we couldn't figure out. After Seilburg looked and gave up I spent an embarrassing amount of time trying to fix the problem while refusing to use Blender, by computing the correct offset and setting the mesh offset or even modifying the mesh.

Next, wasted time trying to get the shadows cast by/on the alcove to look right by tweaking bias settings. I had no idea shadow maps were such a pain.

Also, fixing more 3D graphical glitches. Wrote custom sprite billboarding to support rotations, for all those limbs we need to connect at funny angles. They remained billboarded anyway. Had to disable billboarding in about 10 places, argh.

Meanwhile Seilburg's being concerningly productive pumping out various concerningly unfinished features and we'll probably need a week to get it all working!


(In the image: an evil alcove, a door, an L-shaped room, a hopeless jumble of limb sprites, perspective-corrected billboarded sprites, everything in sight unfinished)

Get Grim Rejoiner

Leave a comment

Log in with itch.io to leave a comment.