Friday, 28 September 2018

Jugular Spurtiness, Engineered Brutes And Boolean Modifiers

Scorching heatwaves have faded into Autumn and the oversized fan I went to so much trouble to get hold of is now packed badly into it's box. At one point I was swarmed by the "Idea Fairy" for other game ideas.

Actually footage of me defending myself from new game ideas

Back on the gamedev front, I added GUI markers to the interface for when the player gets a temporary boost or decline. Previously such events were heralded with an informative element saying what had just happened and how long it would last for, but there was no actual timed element to let the player know whether it was still on-going or had stopped. I decided to change that with a simple "up arrow" icon for boosts next to Experience, Health, Energy and a "running man up/down arrow" for temporary speed changes. Once the temporary change is over, the icon vanishes. Having a speed boost also now protects the player from slowing attacks.

I also gorified the decapitations. Not only do head explode and blood splatter but now jugular veins spurt and throw extra splatter on to the ground near the neck when the corpse finally comes to a halt.

Boom! Headshot!

A long time ago in a galaxy far, far away I had coded some custom homing missiles. However they would cause a crash if their target was deleted - even though I had told them to reset and lose height if there was no target.The hacky workaround was simply not to have any deceased target permenantly delete faster than the lifespan of a missile. Recently I realized that I had failed to add a "isProperlyRemoved" for the target deletion check, and this fixed the crash.

Getting on with modeling and coding new enemies, I eventually found that Blender 3D has a csg style tool called "Boolean Modifier". This can slice, delete and merge two different meshes. Annoyingly I found all of this information out after I had been doing the whole thing manually ... (insert autistic screeching here).

 Nobody Cared Who I Was Until I Put On The Mask ... and then beat the player to death ...

Previously I had modeled a plasma-rifle wielding alien based on the old Manits Man character, and named it the "Kralmok Warrior" after the name of the weapon it carried. This enemy has now been renamed again as the "Hive Warriror" - which is a little easier to say, never mind spell as I found "Kramlok" appearing in my code quite often. The Hive Warrior is a level 5 enemy and is now accompanied by an Engineered Brute.

Brutes with a Hive Warrior and a human sized zombie for scale

The "Engineered Brute" is a genetically engineered ... er ... brute. A large and relentless enemy with a melee attack which whilst slow, recovers quickly. They are the sort of solid enemy which the player will find difficult to push out the way, especially the default ranged weapon (gun) based player character. It spawns by teleporting in just like the Hive Warrior and gives out a gutteral snarl to announce it's entrance in overly dramatic style.

Dramatic Entrance Is Dramatic

Now that I am at testing level 5 enemies all together I realised that I had not created an easy function for this and instead would have to play through the other levels first. Which is fine apart from the time taken - unless I get chomped on by giant spiders in level 3 and it's all game over and start again. To rememdy this I coded a little function which starts the game at the desired level with the player upgraded through typical experience leveling and powerup collections from previous levels.

My Face When I Didn't Do This Earlier ... 

10 whole minutes of testing combat against Level 5 enemies. I got pwned in the 10th minute and never escaped the level.

So, that was the month that was. I fixed and tweaked loads of stuff, got level 5's enemies modeled, animated and working, and found a whole new and easier workflow inside Blender for modeling.