Bespoke Coding

canopy2

My plan for last week was to plow through the entire city prefab set, but as I started working on that one, I realized it would be easier to start by stubbing out each level, and that led to solving problems of decorating the forest level. As I discussed in Tuesday’s video, there’s a few more pieces left to add here, procedurally placing trees and stumps and silhouettes of distant trees, but it’s starting to look and feel how I’ve been imagining in my head, so that’s exciting.

This has required a fair amount of one-off implementations in code (“bespoke coding,” if I want to make it sound fancy and not terrible), which is something I usually try to avoid in favor of generalizing systems and allowing data authored in the editor or external markup sheets to drive these systems. That’s a trait I picked up working on the Borderlands series, and it’s generally served me well in my solo projects too. But in this case, time is not on my side; I have a finite number of known use cases, and I’ll take whatever option lets me wrap this work up quickly. It would cost me more (time and therefore money) to try to generalize these patterns than it would to make some small changes to large amounts of copy/paste code. So in this particular scenario, good programming practice takes a backseat to just getting it done.

Anyway, I’ll be tackling those remaining issues of decoration this week, plus stubbing out the fourth and probably final level, the Unmade hive. This one will presumably require some of its own unique decoration work, as each of the others has, and once that’s done, then I can begin putting together prefabs for all four levels.