Cutting and Bashing Crates, Interaction Upgrades

Hey Folks! Wall-to-wall busy today adding new interactions with the crate, and upgrading the interaction system.

First task of the day was to make it possible to use a laser torch on a crate. And this actually went really smoothly and quickly. Within minutes, I had crates breaking into scrap parts and spilling their contents on the floor with my trusty laser torch. A few bug fixes are necessary to ensure scrap loot didn't appear inside my crew when it happened, as well as a spawned loot not appearing where it should.

My next task was to do something similar for the fire extinguisher, to allow bashing the crate open. However, I thought we'd also want to do this with a crowbar. And rather than making bespoke interactions for each specific tool, I decided to change interactions a bit.

Previously, an interaction could specify certain tools to use, or items required to give/take. These items were specified by name. So if you had a yellow crowbar it might work, but a red crowbar wouldn't work unless you also made an interaction specifying both colors.

The change I made today replaces item names with item descriptors (called CondTriggers). Now, instead of requiring a yellow crowbar (and all other combos), I just specify any edged, rigid, tough, solid handheld object. Since both crowbars and fire extinguishers have those conditions on them, they both can substitute in and work.

Basically, the way NEO Scavenger did it with encounters and crafting.

And so far, that seems to work! You can see in today's screenshot, from left to right: the crate room and fire extinguisher ready for use, the context menu option to bash the crate, and then Bucas Carlos Hutchinson beating the devil out of it. The result is a pile of small parts, carbon fiber pieces, and trash, plus the drill that was inside.

Going forward, this should open up a wider range of possibilities with interactions. It also opens us up to weirder bugs. (Like one where I tried to install a loose floor, and the crew kept picking up installed floors to fill the hole.)

But overall, I think this makes the game more interesting, since the player can get creative with tools and problem solving.

Tags: Ostranauts