Buying and Placing Items

Finally, buying and placing items is working in Dehoarder 2. It may only work as well as a rickety wagon right now, but it is at least working end to end. I can open a catalog, choose a furnishing, choose a style, choose a location for the furnishing, confirm my purchase, and have the furnishing appear and successfully persist to the save file.

This is a feature that has caused much consternation over the past few months. While it seems simple and straightforward, it is actually complicated by several requirements: Handling several distinct purchase types (furnishings, plants, expendables, home improvements, and events), only allowing placeable items to be placed on certain surfaces and only if they are not colliding with other objects, and allowing customization of appearance for certain items. This all required a lot more infrastructure in the game engine than I originally realized. I also had a couple of false starts on the design approach before finding my current approach to be actually workable.

This was by far the largest piece of development left for the game engine. From here, I can add the few more remaining features that were depending on this being complete, and start focusing on making everything in the game engine more robust and adding more content. Today I’m working on allowing expansion of trash and recycle bin capacity.