World Generation, Biomes, and Core Systems

Here’s what I’ve been working on since the last post.

World Generation



I finally got the world generation up and running. I utilized an algorithm I had previously used from GitHub. This algorithm calculates moisture, heat, and elevation to determine the distribution of biomes. It’s not ground-breaking or anything. It just works.

Biome Tables

To define different planet types and their available biomes, I set up biome tables using scriptable objects. But, it was challenging to identify the biomes in the table since the object names weren’t visible. After some dicking around, I found a hacky way to change the icon of the scriptable objects, making it much easier to understand the table.

Local Maps

For individual local maps within the game, I implemented the wave function collapse technique. I had used this method before when I was making my roguelike tutorial. Essentially, I saved training data to disk and reused it at runtime, resulting in varied and interesting maps. Here’s a long-ass video where I set it up:

AI and Dijkstra Maps

I added AI and learned how to use Dijkstra maps. It was a learning experience, but eventually I wrapped my head around it, and I’m pretty happy with it so far. I used GoRogue’s GoalMap implementation to calculate the maps and added logic to handle many goals at once.

Factions and Relationship System

I set up factions and a relationship system. This system keeps track of the relationships between different entities — defining friends and enemies based on faction affiliations. It’s an essential component for creating dynamic interactions within the game.

Friend then foe

Stats, Skills, Abilities, and Attributes

I dedicated a significant amount of time to developing the core systems of the game. I added stats, skills, abilities, and attributes, all managed through scriptable objects. This approach greatly reduced the amount of code required. Plus, it was kind of a fun challenge.

Customizable Ability Bar

One of the more challenging tasks was creating a customizable ability bar with support for both mouse and keyboard input. It was a pain in the ass, but the end result turned out alright.

Things that don’t deserve a paragraph

  • Added a message log
  • Added a save system
  • Added melee and ranged combat
  • Added Basic UI StuffTM like player’s name and a health bar

Next Steps

Gonna add items and equipment into the game next. This will involve designing various items, creating an inventory system, and handling the mechanics associated with equipping and using different gear.


Thanks for reading and following along with my progress.


Note: All graphics in this post are placeholders and are not representative of the final product.

Body Part Editor and Other Odds and Ends

Here’s what I’ve been up to since last post.

Worked more on the Body Part editor. Version 2 of the prototype is about finished, save for some cleanup and testing. I decided to do my best to make it clear what slots represented what by arranging them like a human body.

Removing some parts

I decided against having Arm and Leg slots be separate and made them into Limb slots. That way the player can have all legs, all arms, or whatever. Hell, people do torso runs in Kenshi so go for no limbs if you want – screw it. I’ll then be able to derive some kind of movement and manipulation scores based on the parts added.

I also added support for more limbs by adding an insect torso which has three pairs of limb slots. The editor can handle up to four pairs of limbs, but I haven’t decided if that will make the interface too cluttered. I’m going to try it out at some point and see how it goes.

Swapping multi-slot parts

The editor can also swap multi-slot body parts, which I’ve arranged in pairs. So a pair of bat wings for instance would take up a pair of limb slots. This made it less confusing to see where parts were going to end up when dragging the parts to their slot. I plan on displaying the body part over all the slots it will inhabit while it’s hovering over the destination slot. That will make it crystal clear.

I added pop-up windows so the player can edit the head’s slots like eyes, brain, mouth, and ears. Same thing with the torso so internal organs can be swapped. A right click on the respective body parts brings up the windows. Doesn’t seem too cumbersome.

Pop-ups for Head and Torso slots

All in all, it has turned out pretty decent. It doesn’t look pretty since I’m getting the functionality all set, but I’m hoping that it can be an easy to read and use interface.

I didn’t work on the body part stuff the whole time, though. I took about a month off from it because I was sick of looking at it. I spent that time learning how to draw on a tablet, making music, and picking up some other skills that I’ll need to work on another project. My wife has an idea for a survival horror game, so I’ve been learning how to make PS1 style graphics and whatnot.

I’m excited to move on from the body part swapping and get a proper prototype of the game setup. I want to focus on map generation for a bit to do something different. Then I’d like to add body parts and other items as pickups in the world and see if it’s any fun picking up pieces of entities and attaching them to the player’s body.

Below are a few demos of songs I’ve been working on. A few bass tracks and a spooky scary boi I wrote in high school and tossed into Ableton.

Spirit Demo

Everlasting Demo

Spooky Boi Demo (Loop)

Early Progress on New Project

I spent a couple of weeks kicking around some ideas for my next project. After a lot of research and false starts, I ended up deciding that I should make use of the stuff I worked on since March. Being that it would be silly to make a colony sim at this stage, I decided to go back to making a traditional roguelike. The solo developers love child.

This is still in very early stages, so nothing is cast in stone. The basic premise is that you’ll be a far future feller delving a planet for valuables and information. I was thinking a wyrdstone equivalent like in Mordheim, but I haven’t thought it through yet. All I know for sure is I’d like the player to explore war torn planets, dangerous biomes, and planet-wide cities. Think any 40k planet and you’re on the right track.

The main mechanic I am focusing on is being able to swap out your body parts at will. So that you can become this mishmash of organic material and machine.

To test this out, I took my body system from the previous project and simplified it to be more like an inventory system. Body parts have some body part slots such as legs, arms, and heads. And those parts will have their own slots and so on.

For example, a humanoid torso has five slots: a head, two arms, and two legs. Legs and arms have slots for hands and feet and a humanoid head has two eyes, two ears, a mouth, and nose. This made it easy for me to make a struct that holds what kind of body part slot the part fits into and what side it is on for labeling purposes.

I simplified the parts since I don’t see any real value in simulating the bones or fingers and toes. But I suppose I can add those in later on as non-swappable parts down the line if I find a use for them.

Ye olde human body

In the previous project I had used Odin and scriptable objects to build templates of body parts and bodies and it worked pretty well. The issue with that system was that it was not built in an inventory style where you can swap out parts like you would a weapon or armor. It could have worked the way it was, but I wanted it to be direct and easy to understand.

I was able to enforce body parts fitting into the correct slots when editing the templates by using before and after insert triggers. If the wrong part is added to a slot, it kicks it back and gives the user a message on how they fucked up.

I did run into a few problems early on. One problem I needed to solve was how it didn’t make sense to equip a hover-jet in one leg slot and have a normal ass leg in the other. That’s goofy. It makes more sense to define parts like a hover-jet or wheels to take up more than one slot and view them as one unit. This opens up opportunities for interesting builds. Like a cyborg insect that has a hover-jet and standard legs that they can switch between. While the hover jet can be immune to movement cost and environmental hazards, it could have the drawback of being slower and make it more difficult to aim . Whereas the legs are subject to movement cost, but are faster when there is no movement penalty and may also not incur any kind of aiming penalty. Yet, there may be bonuses to having a matching set of parts. So there’s a lot of potential for these kinds of builds.

I was able to use some validation for multi-slot parts in the editor. It’s pretty basic, but it makes sure there’s enough slots available and replaces the first n slots it encounters. When I implement this in the game, I’d prefer to make it clear to the player they are choosing a pair of slots. That way, it’s clear which slots are being used.

Attributes ahoy

Another thing that came up was how could the player swap out something like their torso, head, or even brain? My solution for that is to not allow for swapping of vital parts without outside help. You can find a body mechanic hiding out in the dark corners of a city or you happen upon body modification pods. Essentially suspend you and replace that which you depend on to live. Want a super sophisticated targeting CPU for a brain? A circulatory system that sprays acid when you are injured? Sure, strap in and wake up a new, deadlier you.

I’m also planning on allowing parts to have a certain number of cybernetics installed as well. Things that can block pain, increase melee damage, that sort of thing. When it comes to cybernetics, you can come up with pretty much anything.

In that same vein, I’d like to mess around with genetics as well. In the same way hobby scientists are messing with gene kits in their garages, you could splice in a frog’s DNA to jump farther or toughen up your skin like a rhino.

With all that I can mix some premade templates of robots, animals, and humanoids along with some proc gen monstrosities. Maximum Cronenberg.

Like I said, a lot of this is brainstorming and in the early prototype stages. But I am hoping to have a test harness setup for swapping out the parts soon. Hopefully making it a fun time while I’m at it.

Next Steps

So the game I’ve been working on did not pan out in its early stages. The short story is that the Biotech DLC pretty much covers what I was going to make. At least to the degree that it doesn’t make sense to continue working on it. But that’s no big deal. I learned a lot, actually. Some of which I am planning on making tutorials for. Anything that I had to figure out on my own or with almost no help, I’m going to cover at some point. Either here or on YouTube. Likely both. But I promise I won’t be one of those people that embeds a YouTube video and calls it a day for a blog post. Sometimes I prefer to not interact with YouTube when I’m looking for a tutorial. I like it written with still images. At most, a few GIFs when necessary.

Anyways, I am between projects at the moment and sort of absorbing and collecting. I’m currently playing Disco Elysium and about past where I had stopped last time. And I’ve been playing Rimworld of course. And a few other games that are fun time wasters like Rocket League. Or browsing the EA Play library and wondering how they managed to perfect the art of making pure garbage. Not all of it is garbage. There are gems in the landfill, of course.

So what else? I’ve been focusing on music the past few weeks. Released a couple of house tracks. Gotten some demos done of some other tunes that I’ll revisit in a few weeks with fresh ears. I think I’ll stick with music as my focus while my next project forms. I’m also going to fix this site up. Hasn’t been up-to-date since I canceled Dunnigan’s Trail.

So I guess that’s what’s next for me in the months to come. Pre-project planning, music, tutorials, and updating the website. Who knows, maybe I’ll succeed at one of them?

On Self-Help

I was looking at bright white rooms inside spotless houses on Marie Kondo’s site and thought, “Who lives like that and are they doing okay?”

This time of year, self-help rears its head in all directions. But how helpful is it? They all say some variation of

“If you live your life in this way, according to these rules, and adopt this mindset then you will achieve the fabled Final Happiness Moodlet and shine as bright as the beacons of Minas Tirith!”

Imagine the day to day of thinking like that. What happens when you have an off day and can’t meet parts of your routine? For me, it would fuck up the whole day. Like “oh no, I slept in and didn’t prepare my breakfast and missed my morning walk listening to the Happy Forever podcast! The whole day is lost!”

And that goes on for the rest of the week. One day’s failure cascading into the rest of the week like so many dominoes.

Some people can shrug that stuff off and continue on. In a perfect world, that’s what you would do with any advice. “I prefer to do these things”, rather than “I should do these things”.

It’s okay to feel bad. It’s okay to make mistakes and fail. You’ve done it a lot already. You’re going to do it a lot in the future. You cannot avoid it. Trying to avoid it is going to make you feel even worse. When bumps in the road come around, you’re going to feel even worse because you tried so hard to NOT feel bad. You mark yourself a failure and shrink into a corner.

You can’t put that much pressure on yourself to have a Perfect Day everyday. I have a person like that inside of me and they look like a fucking nutcase. Eyes wide, chesire cat smile. Straining to be Happy Forever. It makes me sick looking at them. I’m sure I let this person take over a few times in the past. Now they hang around as a cautionary tale.

Recognize when you are neck deep in trying too hard. Step back for a bit to take a look at what you’ve built for yourself day to day. You’ll find that a lot of pieces don’t have any real value if you look long enough. You can’t build these things expecting them to last your lifetime when you and the world are changing. These structures need to be stable and modular. And when they stop being either, you have to get out the crowbar out and fuck them up a little.

This requires time, patience, and humility. You won’t get done and feel great. You have to build again. But some parts will remain. Some parts have stood the test of time and you have evidence of why. They’re not much on their own, but they make a difference and they work for you.

You’ll be building for a lifetime. Self-help is people sharing blueprints of their own structures. You might get lucky and they’ll fit exactly. But I’m willing to bet you’ll have to figure out where those pieces can actually fit into your own structure.

You can’t demolish the whole thing in one go. Some pieces have been around for so long that you’re going to have to erode them for a long time. These are the behaviors and patterns that always come back after another “better me” episode. That’s the core you. So no, it’s not likely you can slam someone else’s blueprint into your life and it’ll work. You’re not them.

Approach adding these blueprints as experiments. Try it out for a bit, see what works and what doesn’t. Go in with the expectation that it won’t work out the first couple of times. Possibly not at all. But you gave it a shot and now you have another thing to add to the short term “does not work” list. That list is not meant to be permanent, but referred to in the future. You’ll be trying to solve a problem and realize “Oh yeah that thing I tried a while back might be useful now!”

We’re not comfortable with the thought that we don’t live in a stable universe with clear cut rules on how to live. It’s much easier to subscribe to a set of rules that promise success. It takes the responsibility off the subscriber. They can shrug and say, “Sorry I’m just following the rules don’t blame me!”

Maybe for some that’s the best they can do I don’t know. If you’re buried in work and raising a family, it might be hard to have the time and energy to change your structure. That bit takes a lot of reflection. A luxury maybe. Would things be different if everyone were allowed that luxury? I am interested to see.

I fired an employee a week before Christmas

Let me explain.



Working with The Banana Man isn’t easy. I love everything in excess. I will push extremes to new heights because Linda in HR said I can’t. So what if the employee health plan “iSn’T LeGAl”?


That’s what started the whole mess. In a fit of cocaine induced euphoria last New Years Eve, I promised Christmas bonuses for all employees next year. It felt good to see all the positive reactions in Slack. But that feeling faded when the reality of the cost set in like a bitter wind.


Our controller had burst through the door to my office that day. Sweat pouring from his face and eyes set ablaze with panic. I felt myself grow numb as he shouted numbers and shoved the scribbled graphs in my face. It took me a long time to come to terms with the truth. Our annual Vegas Trip would shorten to five days and each exec would have to ration their hookers to two a night.


“THIS WILL RUIN US!”


I’m not quitter. I don’t lie down in times like these. Rather, I welcome them. That’s how I ended up meeting with HR to revise the employee health plan.


“I understand what you’re saying Mr. Banana, sir. But we can’t give the employees a fake plan and pocket their cash. It’s too risky! Why don’t we downsize and redistribute the work like everyone else?”


“So short-sighted.”


Elbows on the table I rubbed my temples. “We make way more money in the long-term this way, Linda. Even if we do get caught, it’ll be long enough down the road that we’ll still come out on top.” I waved my hand vaguely. “We’ll pay a fine and settle a few lawsuits.”


“Okay, well… I guess I don’t understand how they’ll use the insurance.”


I sat back. “It’s simple. They won’t! We’ll set up a system to reject the claims. If they can’t pay, they’ll go to collections and then we can buy the debt ourselves. Too bad we can’t enforce something like making them work here as long as they have a debt. Legal is working on that.”


It was settled. And it worked as intended. The Vegas Trip was even better than last year’s and nobody went without.


Back to the employee. One of my middle managers Josh. He started taking a lot of time off. He even ended up questioning the new health plan as it wasn’t covering a treatment that he needed to live.


We explained that our hands were tied. This year’s Vegas Trip had set higher expectations for next year and we could not afford a different plan. Some of the higher ups worried he’d blow it all open, but I reassured them,


“He’s bald. No one will listen to him.”

George


Later, he stopped coming in and HR processed him through the termination pipeline. Dying isn’t an excuse. He got sick and fired because he was weak! I never took a day off in my life!


Anyways, we replaced him with my snake plant George and it’s been working out great. Josh took up space and used my oxygen. Not to mention we had to pay him to be here. George never leaves his desk and PRODUCES oxygen albiet in trace amounts. For free!


Still, our PR department thought it would be a good idea to memorialize Josh somehow. So we had license plates made with his face on it and started a fund for the Vegas Trip in his name.


Things are looking up and forward in 2022!


Happy Holidays and Dog Bless!