Friday 29 December 2017

Tests, Checks And Gameplay Balancing

It's that time of year again folks, when you feel like this ...

And end up looking like this ...

Of course some of us are still working hard on "muh gaem dev" - and this month it's been mostly playtesting to try and create game balance, and hunt down a few elusive bugs. And when I say "elusive", I of course mean badly/drunk coded.

Like the Rocketrix offensive smart bomb attack. It picks the most dangerous group of enemies so it can do the most damage, swoops in and ... blows the player to smithereens. Yep, pretty sure that is not supposed to happen. Turns out I was calling the attack from the enemy target instead of through the player. Simple mistake by passing the opposite variable, possibly explained by the following image:

One thing that extended playtesting has shown is that stacking powerups - repeatedly collecting the same swag - does not happen as often as I thought it would. Even with 15+ items available each level, there are a total of 108 seperate bonuses (including upgrades to weapon drones). Whilst this does not really effect offensive or defensive events (which are added to an array list for chance of activation during attacss/damage), it does mean that permanent bonuses (health, speed, energy, etc) to attributes do not happen as often as originally planned, and individual bonuses confer too little benefit to the player.

Boosting the effect of permanent bonuses is the obvious way to balance this unforeseen lack of reward. For instance increases to player health are now percentage driven rather than a stock value, and speed is now hiked much higher as the original gain was meaningless beyond the first few game levels.

Another event that did not quite live up to it's predictions is the "Momento Mori". This is a sort of "rage gauge" which fills each time the player kills an enemy, but reduces each second. Enemies killed by heavy attacks fill the gauge faster than light attacks, and all other attacks (drones, swag events, etc) even less. The bar can fill multiple times, changing colour and conferring a multiplication bonus to the player's scoring.

"Gore Gauge" - Orange Bar and x3 Text, top right

Originally the player would fill the "rage gauge/kill bar" three times - now forever to be known as the "Gore Gauge" ;) - at which point the player would be healed and for the next thirty seconds the Gauge would stick at 4, multiplying the player's scoring.

To make this more of an actual event for the player to aim for, I increased the fill trigger level to 4, at which point it leaps to score multiplication x8 (4 = death, 8 = wealth), the player is healed 100% and for the next 30 seconds whilst the Momento Mori lasts is also invulnerable to all damage, which is a really big help in crowded and frantic later game levels.

Momento Mori event triggered. Red bar and x8 text top right (GUI still needs some work)

The GUI incorporating the Gore Gauge needs a bit more work, such as an icon to show what it represents like the XP/LevelUp, health and energy bars top left (a small skull would probably be a good fit here).

Momento Mori in action from ~02:02. Gore Gauge starts at x3.

Of course, what was missing from the above video is an indicator for the player that the Momento Mori event is still on-going and not yet ended. After a quick bit of modeling, texuting and scripting, I created what I felt would be a suitable aura type object to mount on the player to signify that the event was active.

Behold, one visual indicator, brought to you in the format of GIF

There have also been numerous other bugfixes and tweaking of code and gameplay - it's not all been eat, drink and be merry this Decemeber. ;)

So, next up is more gameplay balancing, but I am at the stage of development that this requires creating the actual data for the enemies which the player will be encountering in the game worlds, and their unique attributes and characteristics for attack and movement. This also requires drawing up a list of boss types rather than the singular one which I have at the moment.

Roll on 2018 ...

Tuesday 28 November 2017

Test Tweak Twiddle

With a basic level blocked out, the past month has been mostly about testing, tweaking and twiddling with gameplay. This meant a lot of playtesting followed by minor adjustments to scripts and code, as well as the usual "let's streamline everything" followed by the equally usual "oh god everything is broken now", followed by fixing it. None of this makes for particularly interesting pictures of videos.

One thing which is "screenshotable" is the new level based statistics screen which now pops up at the end of the level. Previously at the end of each level a continued game progress screen would display, giving various statistics on the player's progress that run. Now a minor version detailing statistics from the previously completed level displays with information and percentages relating to player activity.

From the top; time taken to complete level (or die a horrible death, whichever comes sooner), score for that level, swag parcels opened, cash looted, enemies killed, overall percentage for that level/world and finally the pre-existing, remaining cash on exit converted to points. Once art and animation are the priority "something interesting" will fill the left side of the screen too - probably the players character with a celebratory animation corresponding to level completedness.

This level statistic interface then fades into the standard game progress screen which gives a more indepth view of statistics which the player has achieved.

I had also started to list the various types of enemy and player characters and abilities which I want to feature in the game. Variation is the nemesis of repetition and thus a wide assortment of enemies and capabilities is something to strive for. Currently in the way of hostile attacks I have a simple melee enemy, a charging enemy and projectile shooting one. These are certainly the main themes for the opposition which can feature good variations. On top of this I have already coded "elite" enemies who have special abilities ranging from contact based damage to temporarily slowing the player for a few seconds. These elites carry a certain colour and aura to distinguish themselves to the player as extra inhospitable. They also carry more hit points.

Hit points carry cash which is used to open swag parcels for the player to gain powerups and useable items. Each level the cost of powerups increase, but as the player becomes more powerful and enemies more numerous the amount of lootable coins also increased rather too fast. I have had to reduce the amount of cash enemies drop in later levels as a result of this.

The entire system for usable items has had an overhaul. Previously the player could collect items and be able to use the current highlighted one on screen. Every three seconds thecurrently  sclected item would advance to the next. This became incredibly infuriating when in the throes of combat to try and time using the right item at the best time and often led to the wrong item being used. This has now changed to allow the player to manually cycle through the list of useable items with a simple button press to choose which will be active.

So there we have it. I am continuing to list enemy types, and their abilities in prepartion of when they become actual models. Until then, huzzah for placeholder cubes!

Tuesday 31 October 2017

Mulit-Level Long Play Test

 Blast monsters, grab loot, buy swag powerups, unlock nodes, beat boss, run to exit. Rinse and repeat for next level.

Finally I actually got around to blocking out some level design. Nothing fancy, just a plan of walls and obstacles for the player to manoeuvre around (apparently that's maneuver for Americans).

It didn't take long before I realized that the whole thing was way too big and needed to be smaller. But that wasn't the only issue. As the game time increases in a level, so does the difficulty. And as the levels increase, the game gets harder. Obviously this is a tried and tested gaming concept, but I was finding that the difficulty curve ramped up very sharply. A little rejigging later and ... it was far too easy. Minor adjustment and too difficult again. Balancing this difficulty curve has taken up the vast amount of time this month.

It turned out that a lot of this difficulty stemmed from the player's powerups not reinitiating in later levels. I had made various changes to the powerup system and how it gets stored for reference and not all of it carried across correctly, and in one case I found that the variable being stored had received a name change at the other end which was no longer being referenced.

Going through the various powerups I fixed all the broken paths and references, and generally tweaked the strengths and effects. Gradius style "option" followers, or weapon satellites which follow the player and increase firepower were toned down in the amount of damage they did. "Static Heal" powerup was scrapped because the player never has chance to stop long enough to increase healing without getting swarmed by enemies. Enemies and their spawning routines were tweaked to give a more gradual rise in challenge but also to watch out for the player wiping the floor with them over a longer period of gameplay.

Each level has an exit, and each exit requires unlocking via activating nodes with later levels having multiply nodes to unlock. To make sure that the player understands this concept there are visual hints in the bottom right of the screen and the in the first level the node is next to the exit. Once all nodes are unlocked the level boss spawns (currently just a large cube with an aggressive charge attack) and once the boss has been defeated the exit opens. To prevent the player from lingering in the level to "clean up" cash and remaining swag I decided to stop the enemy from dropping loot coins once the boss has been defeated. Difficulty also takes a temporary increase both whilst the boss is released and also when they have been defeated to encourage the player to head for the open exit and progress the game. 

In the end it all seems to work rather well, and I am pleased with the result. Here's nearly an hour of playtesting the system. I also found an error at the end of it, as not statistical information was being passed to the end of level screen when the player was killed and the game was over - now fixed.

So, next up is adding a few more statistics to the end of level screen such as percentage of kills, cash, swag, etc that the player has gained that level. After this it will time to get on to actually designing art for the level, and eventually even the characters with a greater variation of enemies, bosses and enemy attacks. But hey, one thing at a time! ;)

Friday 29 September 2017

Loot Crates And Swag Parcels

Loot Crates and Swag Parcels ... are actually the same thing. Previously they were just placeholder grey cubes, but now they have a final form.
Top row Large crate (rare swag items), middle row Medium crate (uncommon items) and bottom row Small crate (common and useable items). Each crate type has three models which are placed with a randomized rotation.

When the server loads the level, Loot crates are randomized throughout the game world. Initially I added an impact decal with each crate but realized that previously spawned decals do not get passed to new clients when they join unless they are first saved into the level's decal file. This seemed a bit of a faff, so I simply modeled the impact texture into the actual loot crate mesh.

I also replaced the Level Exit Node (which up until now had been just another Activation Node) with it's own model and updated the on-screen prompts to reflect this.

The post-level status screen has also got (yet another) change, replacing the text with icons though text explanations will pop-up via using mouseover. I was hoping that the icons would be fairly self-explanatory but decided to include the pop-up text for safety's sake. Nothing worse than a player wondering what the hell they've got 30 somethings of.

And here's how it all looks in the demo level I use for testing when the Exit is unlocked and the boss fight against Placeholder Huge Cube Boss begins.

Next up, either start to flesh out the remaining models for powerup special attack events - which will lead onto creating characters and the like, or it will be time to start creating some actual game levels - all of which will no doubt start out as whiteboxing.

Decisions, decisions, the pressures of command ...

Monday 28 August 2017

Level Exit, Boss Fights, HUD, Statistics, Chaos Engine Reference

Busy month - well they're all busy months, it's just that sometimes more stuff end up working than others.

I coded a level exit system which ends with a boss fight, which is currently a big placeholder cube with a charging attack. The exit itself is shielded and the player has to find and activate a seperate node ("NODE ON!" Chaos Engine was a great game back in the ... er ... early 90s?). This unleashes the level boss, and once defeated the exit's final shield fails, the exit opens and all hell breaks loose whilst the player runs to escape the level.

Deactivated nodes have a padlock item above them and a single shield of falling energy particles (which is an animated texture mesh), whilst the exit can have multiple shields (one for each node and an extra one for the level boss). Exits have a revolving exit sign above them. Currently both nodes nad exits are using the same model but that will change in the future. so that exits look unique. In the first level the node will be next to the exit to teach the player the clear relationship between them. In all future levels the node and exit will be randomly placed away from each other and there may be multiple nodes which require unlocking. Nodes are unlocked in the same way SWAG is bought, stand over them and press BUY button and spend that cash.

After successfully completing the level, the player is shown a progress screen which displays multiple statistics and a big scroll list of all the swag that they have picked up.

Testing the gameplay for an hour and then viewing the statistics it became clear that the scoring system needed some tweaking. Sixty minutes of blasting the hell out of everything and collecting nearly 90 power-ups made the score not seem particularly charitable. To this end, I decided that doing anything would increase the score. Kill enemy score++, pickup cash score++, take damage score++, spend cash score++, etc. I also decided to throw in a score multiplier system. This works like a rage system in fighting games (or at least I "think" it does because I've never been a fan of fighting games). I called it "Momento Mori" because dead enemies boost the bar and it can go through 3 levels of muliplication for kill scores before sticking at level x4 for 30 seconds and multiplies all points from all sources. Using heavy attack boosts Momento Mori the most, light attack less and item kills the least.

Which brings me to changes to the HUD and general player interface. I added icons to all the bars and other player display objects. Cash and Points are animated meshes embedded in the HUD which rotate. Cash is a silver coin  - gold for a king, silver for a gentleman ;), score is a gold star in a ring (cos it looked better than just a star), health is a heart whilst energy is a lightning flash and Player Status is still a placeholder banana. Experience and Leveling was a little more awkward. Initially it was just "XP" though I eventaully settled on a bar chart with a small arrow at the end.

When the player exits the level - or dies, whichever comes first - their remaining cash is transfered into points at a rate of x10. Originally there was a whole load of text explaining this but I replaced that with an icon which hopefully does the same. This now displays for a few seconds before the whole screen fades out and the statistics interface fades in. I may in the future replace the text in the statistics with symbols.

I also declared a major victory in the on-going struggle against console spam. When a trigger was deleted, it would list the objects in it for a final onExit callback - except it didn't have a list anymore because it was being deleted. A quick "if ( gEvalState.thisObject->isProperlyAdded() )" put paid to these needless warnings and lines of red highlighted text in the IDE and console. Hurray!

Sunday 16 July 2017

Paved With Good Intentions

Puts on gravely voice.

This is road ... to hell.

So, so much for making a development blog every month as I completely forgot during both May and June. Anyhow, here's July's.

SPARKLES! Everything is better with sparkles, and now sparkles are better than ever before! They're now an animated bitmap texture which changes colour and work along a complimentary colour scheme - eg: opposites, red/green, blue/orange, etc

There have also been some serious improvement in AI. Enemies now come in a variety of flavours.
Red are ranged based enemies who shoot projectiles. Light blue are dumb/zombie melee enemies (and thus carry a white stick to denote that they are melee based class) who stalk the player. Purple/magenta are melee class hunters who follow the player. Black are melee class chargers who rush at the player to attack and go flying past if the player can dodge out of their way.

On top of these enemy classes there are also special types of attacks. These are Radioactive Fire who have a green glownig arua and leave a green fire in their path, who do damage on contact; Electricity who can stun the player for a second and thus reduce movement at close range; Retardant which is a yellow falling aura who stun and slow the player for several seconds on contact; and finally Homing missiles, which come in two forms, one which is semi-accurate and can be dodged without too much difficulty and one which is both fast and accurate and very difficult to dodge.

There is also now a game over screen which lists various statistics for the player such as enemies killed, damage absorbed, cash picked up, etc, and also displays a list of swag collected by their icon's. Currently it's only a game over screen for when the player dies but it will also double as an end of level screen once I get level progression coded - and coding level progression is what I am currently working on.

My thoughts on level progression are as follows. Player needs to get to the exit, but the exit requires unlocking from a separate node. The higher the level, the more nodes there will be to unlock. Currently I am in two-minds whether to have the node activated with cash the same way swag collectibles are purchased, or whether to have them activated by having the player stand in the area for a certain amount of time like base/point capturing in an First Person Shooter (like planting the bomb in CoD multiplayer - though I've not played CoD since number 5 WaW, so what are they up to now? CoD 9000?). Either way, when the level exit it unlocked an enemy Boss appears and must be defeated to open the exit. I think that only defeating the end of level boss will be neccessary rather than cleaning out the whole level (like in say, Risk of Rain).

So that's how things are shaping up on the still untitled Swag 'Em Up!

Sunday 30 April 2017

Power-Up Death March Volume 9000: The Death Marchening

Whoopsie, almost missed the monthly devblog!

So I am still hammering away at the final few power-ups. They are all much more complicated in models and animations and have been taking longer than expected ... which should not really be unexpected as everything always takes longer than expected which is thus ... er ... expected?

Everything looks better with sparkles! Desu!

Time Stop, special defensive item. When activated it stops all enemies from attacking the player for several seconds. There is also a joke about Japan in there. ;)

The original version of the animation had the watch spinning around. However this made it difficult to see the actual movement of the watch needle and the spinning of the internal gears. In the second version I took the spinning out and made the whole object a BBZ, that is a billboard which always faces towards the camera whilst also orientating vertically (the Z axis).

One thing which I discovered was that mesh models of the explosion class object do not use LOD, so the highest level of detail always shows.

And here it is in action against the AI enemy red cubes.

Still more complicated modeling and animations to do for further power-ups before I can get started on actual world building and level creation. Death march onwards ho!

Wednesday 22 March 2017

Collectibles Continue

Developing collectible power-ups, bonuses, and general work on creating 108 pick 'em up swagables continues.

I'm in the final stages of creating the events for using special items, where the remaining objects are consist of more complicated models and animations. Much of the audio for special events has been done. I ended up buying a couple of huge audio packs from ImphenziaAB which took some time to wade through as there was several thousand unique sounds and a further several thousand tweaked audio tracks. Many of the sound effects I wanted for in-game events needed multiple sources mixing together.

The following images and videos should give somewhat of a flavour of the special events and power-up collectibles I've been working on, with the whole thing not taking itself overly serious, as can be seen from the description overlay upon picking up the object.

Cuddle Free Zone featuring the "Keep Out" yellow tape from certain Japanese "entertainment"

Rebound Attack which sends the damage back against the attacker

The Floor Is Lava being an old children's game

Fantasy Armour works pretty much as you would expect ... and features a reference to the old Doom invulnerability shader

Ban Hammer - when the enemy gets reported to the mods

Amongst all of these collectibles I've added the randomized chance for a "Swag Dispensor" (I'm gonna need a btter name than that, maybe just "parcel") to drop a poison bomb. The player gets an audio and visual alert of the danger which gives them a small opportunity to get clear.

Poison Trap

 There are only several more special events to finish off, though these require somewhat more complicated animations and modeling than all the previous ones which have been completed - which is why they were left until last. There are around a dozen others which still require audio adding to their events. However the code has already been completed for all 108 special items. Hopefully after this I can finally get on to designing some levels, and seeing which of the design conecpts for building environments work best.

Tuesday 21 February 2017

Swag Test

Not going to be much of a Swag Em Up without making sure that the Swag drops.

With 108 power-up collectibles I needed a way of distinguishing the type of object that would be collected from each drop point - without having to resort to making a model of every single one. For this I decided to go with the class value of the item, as used in the image displayed.

Laser Beam - Uncommon Item, Amber Triangle

On top of Common, Uncommon, and Rare upgrades, I also have Use items and added a Hidden/Mystery indicator which hides the class of the collectible. There are also Gradius style Follower "options" which increase firepower and are hidden from displaying in the Mystery category. These Follower objects have their own upgrade system which runs through the colours of the rainbow - influenced from the security clearance levels of the old pen-and-paper RPG Paranoia: ROY G BIV(U).

Gradius Style Follower Weapon Platforms In Action

So I ended up with the following visual indicators for what type of Swag might be dropped. Unknown collectible is a swirling animated vortex, whilst all others use the same class value symbol as displayed on their image when picked up. I might extend this to show the type of power-up available such as on Attack, Defend, Temperory, Permenant, etc.

Swag Value Indicators

To test if all my code and math was in working order, I created a test zone and heavily populated it with repeating terrain meshes and Swag drops. Having previously learned that 1 30x30m mesh produces far fewer drawcalls than 9 10x10m, I used 1,190 meshes to cover roughly 1km squared. Placing Swag Drops 40m apart over a 300m area, meant that I ended up with 272 Drop points for Power-Ups. Each dropPoint (think Swag vending machine) consists of the rotating, non-colliding item for the value indicator (heavier load than the previous static mesh I was using), a placeholder cube for the dropPoint, a pulsing light - categorized in colour to the class value, and some particle and sound emitters for charging the point, and also for dropping the Swag. The last thing was to add some LOOT in the shape of bronze, silver and gold coins.

Swag Em Up!

So that works nicely. I've been recording the value quantities spawned and it all seems to work well with my mathematics formula which is based on difficulty/level progression. And it's beginning to feel kinda like a game now.

Thursday 19 January 2017

Fancy Pants Stuff

Disclaimer: Blog post does not actually contain any pants which are fancy.

So another yeah towards the universe's doom lurches into existence. I made a whole 5 blog posts last year - 60% of them in February ... ahem ...

I finally updagraded my 10 year old Dell to a new all singing, all dancing, super-computer of a dev machine.

In other news I survived the Great Yorkshire Earthquake which wreaked widespread devastation.

Anyhoo - back to dev:

I finally completed 104 icons, which like everything else to do with indie game development, took far longer than it should have.

I also made a few changes to the HUD to try and finalize a layout. I merged the energy system for heavy attack and special evade into a single recharging system with collectable bonuses to increase the recharge rate.

For fancy effects I started playing around with a little shader code which found to give objects a distortion similar to Predator style camouflage or the invisible demons in ye olde Doom.

It's still a bit of a work in progress for optical camo but after a few additions to explosion code (code here) makes some nice shockwave ripple effects. See the two videos below and look carefully for the magnified turbulence shockwaves.



So ... onwards and upwards. Development is getting to the stage where I'll soon be swapping out the placeholder items and modeling and animating some actual art assets. To be continued! - hopefully with posts that are more regular than 2016 ...