Hey Folks! Hope everyone had a good weekend. Ours was very, very outdoors. And I've got my vitamin D quota for a long while, I think.
Back at work, I set about a minor task I've been meaning to do: add auto-tile ability to certain items. Namely, conduits and walls.
Up until now, if you placed a conduit, there were two pieces. A 2-way pipe, and a 4-way junction. I once also had an "L" shaped corner piece, too. And if you wanted them all to line up, you had to carefully choose each piece separately, and place them by hand.
And for a wall? There's only one wall block. And it looks the same everywhere.
Long-term, I wanted that to be more versatile, and easier on the user. I wanted thinner wall pieces that could auto-form junctions, and similarly, have conduits snake around the ship without requiring paintstaking placement.
So I've nearly got that working now. I've setup a specialized item variant that uses a sprite sheet (see the right side of today's image), and it shows one of those subsections of the whole sheet at a time. Some code checks the surrounding tiles to see what fits best, and uses that.
I say "nearly" because there are still some edge cases. (Perhaps literally.) Most of the connectors look right. But I occasionally get one that seems sub-optimal. Like it's connecting to the existing pipes fine, but also connecting to one I cannot see. Maybe there's some data getting left in the tiles after an item is removed?
Anyway, a few more kinks to sort out. But once they're done, I'll convert the walls to use this, too. And either now or later, I might add interior and exterior cladding for walls, to control things like comfort (interior) and heat/impact/rad shielding (exterior).