Now the big thing with enemy mobs is what their actual gameplay is. I need to add a bunch more arch-types and decide on “arch-mechanics”, so to speak — something unique to each mob. This is still partly “placeholders”, but also partly “I’m out of time and this will likely be the final thing”. For now, I have a bipedal walking bot, a tank-thread driving bot and a jet-booster hovering bot. I will just call them by their highly technical names Walkbot, Tankbot and Hoverbot for quick reference:
So these are the sort of robot arch-types (color-coded for convenience), which is why I was so eager to break them further apart in minor variations. Now, I spent some time with pen and paper and came up with a few reasonable-sounding ideas. This is actually way harder than it sounds, because I have a lot of restrictions on these mobs — how big they are, how they move, how they animate, etc. So the ones I came up with are:
These all need their own animators, death parts, weapon selection, weapons, add them to levels, and do whatever else that’s unique. Not to mention actually adjusting the values.
Now I “just” need to come up and implement the actual mechanics for my new semi-placeholder mobs. I have some generic ideas about what they do, but I need to add some gameplay mechanics by which they differ.
One of the more straight-forward designs is an Explodebot:
In short, this one blows up when it dies, so the player has to avoid it. It’s a very simple and straight-forward mechanic and pretty much everyone understands how to deal with it and even use it to their advantage. So I basically need to add gameplay at least enough to stisfy these expectations.
So I have to add an option to enemy definitions saying what happens on their death:
And one of the options is then to explode with any extra parameters I want to be adjusting:
While I’m adding this, I might as well add mob death effects:
And then I can have them properly explode in-game (I boosted screen-shake, so now the GIFs are very shaky…):
I made the mobs damage each other, damage props, have the props damage mobs and other props. So these explosions can chain up in a room:
On on hand, it’s over-powered and lets the player clear rooms easily. On the other hand, awesome! I mean, how awesome would that look and feel with proper sprites?
Another feature I am thinking about that I really want to add as a mechanic is cowering — mob state where it doesn’t shoot, just gets its armor up or something and waits. So explodebots would stop and cower if the player shoots them, so they don’t get exploded by getting shot in their “explody bits”.
First thing I need is an entry in the AI belief thing:
Basically, I am adding a new mob desire — to cower. It’s disabled by default for mobs, but I am making a specific AI version that enables it:
I also need to add an animator entry for this:
And arrange the sprites in a suitably cowery layout:
And tweak and adjust the AI options until enemies actually cower from time to time:
I certainly learned a lot about making AI and I definitely overdid it a little. The general idea was fine, but I rather hand-craft more things next time with some generic values to control it.
Next I need the mobs that cower to absorb a lot of the incoming damage, so there’s an actual benefit for the enemies to cower (although they would be better off not cowering and just spam-shooting the player):
The player ends up playing a bit of a whack-a-mole with these. Shoot the ones now cowering, then they cower too, so they switch to other ones. It’s actually not half bad gameplay-wise. It certainly changes the dynamic of “shoot continuously until dead”. There’s no point shooting these unless there’s nothing else to shoot.
Actually, I like this mechanic so much I think it deserves its own mob rather than also being “explody”. So, I’m going to “copy” the mob into a “Cowerbot”:
And make its own sprite variants:
And they work pretty cool in the end (my GIF went super-sonic for some reason):
Well, that’s good enough for two more mob types. I’ll work on others now. I will cover these in future individual posts, probably a couple or few at a time, depending on how much work I actually do for each.