Loading...
96
Game
Hensen Hopper
6 months ago

This is a much larger (in terms of resolution) video than I've shared here before!!!

This is a full round of Hensen Hopper in it's current state! I mainly recorded this to showcase the new wave difficulty curve algorithm I've been working on!


The enemy wave spawning algorithm itself (that is the algorithm that handles when new enemy waves are spawned and how said process of spawning new enemy waves is executed) really hasn't changed much.

image.png

Random waves are still drawn from a list and their enemies spawned accordingly every time there are no offensive enemies (that is enemies that attack the player) in the scene. The only major difference here (as you can probably see in this snippet) is that the random waves are no longer drawn directly from the waves array that is accessible in the inspector window but instead from a separate internal list of waves that is built on Start and re-built every 10 waves during runtime.

image.png

The process of doing so can be separated into two subparts, adding new waves and pruning waves that are too easy for the point in the round the player has reached, this is in order to keep things exciting for the player, of course!

Waves added are based on a new wave difficulty system. Each enemy now holds it's own difficulty value and the difficulty of a wave is simply the sum of it's enemies' difficulty values.

image.png

Every time the internal list from which waves shall be drawn is updated, I loop through the FULL list of waves (the one I can modify in the inspector window) and add any waves that have a difficulty value less than the player's score divided by five (keep in mind the players score and the difficulty of enemies are both integers so this is an integer division operation) plus three to the list skipping any wave configurations that are already present in the list.

For example, when the player's score is less than five, the max difficulty of a wave that can spawn is two, meaning at most two soldiers can spawn until you reach a score of 10 where the list is next updated since soldiers have a difficulty value of one. Beetles have a difficulty value of two but all configurations involving them also include at least two soldiers so they don't spawn until you've gotten 10 points and the list is updated again (at this point waves with a difficulty leq 4 are added to the random draw list)

image.png

Pruning "easy" waves creates a brand new list from the current one where any waves with a difficulty value less than the players score over five minus five are left out (this proved more intuitive, at least to me, than trying to REMOVE items and since this is only being carried out every 10 waves I wasn't TOO concerned with the runtime complexity, after all, I can always have this happen more rarely by changing the value by which I mod the wave number in figure one).

This created a potential problem I noticed almost immediately, however, where eventually the players score would get to a point where there were literally NO waves that could meet this requirement and they'd all be left out. In order to fix this, I went ahead and made it so they'd also be included if their difficulty was five or greater regardless of the player's score. This seemed totally fine as the straight row of five and any wave with at least three soldiers and a beetle are a difficulty of five, both of which are REASONABLY challenging waves and shouldn't feel too boring to have spawn on you late-game (again, I can always tweak some values later if I need to so shrug).



0 comments

Loading...

Next up

I've been working on the backdrop today! Among other things I've done, I made a bush! I know, SOOOO impressive lol.

Close-up of the re-shaded Hensen!

Okay, so the stages and score saving are both more or less working. Your score and high score will be saved throughout the lifetime of the application. Currently nothing saves when the game is closed, though, I'll be working on that next weekend.

Doki Doki Literature Club is celebrating Monika's birthday and the 8th anniversary of DDLC with exclusive stickers, avatar frames and backgrounds on Game Jolt! 

Head over to the shop to collect yours 👉 https://gamejolt.com/#shop

Very unfinished but the backdrop image, as it is in this video, is already leagues better than what I had last weekend! I'm going to work on it incrementally over the coming weeks as I work on implementing the stages idea I talked about before!

Mae Borowski is the main character of Night in the Woods! It's an adventure game that tells the story of her return to her hometown of Possum Springs. She was confirmed as canonically pan in a social media post by the game's creator Scott Benson.

I mentioned some time ago that I'd upgraded the shading on the beetle enemy's character art. Finally got around to putting together a before-after shot of that upgrade! This time, I made gifs for both!

Here's a short video showing off the improved gameplay loop and "stage complete" screen. The updated artwork for Hensen and his gun and the honey bullets can also be seen.

The Knightling launches on August 28! Wishlist it now so you don't miss out: https://bit.ly/KnightlingSteam

To celebrate the game's impending release, we've added The Knightling Pack and The Knightling Community Pack back to the Shop!

This is just about the only situation in which I'll ever do this. I almost never put multiple calls to methods on the same line but here I've logged a warning to remind furure me to do something I didn't have time to do today in a glaringly obvious way.