DevLog_04: A Simple Game (Self Study)


Ahoy!

This weeks update was huge. The task was to turn the project into a simple game with health, damage, and enemy spawn points. The idea was to have enemies spawn in and die when they touch you, while taking off a small amount of health. That game loop really just promotes running around and collecting health while being charged by crazed suicide bombers. But, I wanted the player to have more agency. So, I pivoted to add an attack that the player can do, and also made it so that enemies don't die on touch (but they still hurt you).

Figure 01: Player Attack.


Health & Hurt.

I added the health packs to help the player along. It had to be a fish, obviously.

Figure 02: Fishy Health



The game needed an end. Either win or lose. I set it up so that if the player health reached 0, then the game would end. One task was to add an explosion on player death, but I felt like it didn't match the feel of the game at the time. I liked the juxtaposition of being completely swarmed and panicking as enemies attack, and then a sudden black screen with "YOU DIED" and the sound of slippery enemies moving around your corpse.I think I've seen a game over screen like that somewhere before..

Figure 03: A Fast Death.



I still had to meet the requirement of an explosion, so I included it in the deaths of enemies. I guess I've ruined the G rating of the game.

Figure 04: The Death of an Enemy


Spawn.

I added the enemy spawner so that an almost endless swarm of enemies will come at the player. The script I wrote last week made sure that all the enemies ran straight towards the player, or a little bit in front depending on if the player is moving or not. I set the spawn rate to be slightly faster than the players attack rate. That makes it so that over time there are more and more enemies, increasing difficulty the longer the player survives (if they try to 1v1 all the enemies).

Figure 05: Enemies Spawning



All this took maybe an hour. Alright. So this is where things went off the rails. I spent the next 16 hours turning it into a full game. There isn't enough room in this devlog for me to go into detail on every change from self study task, so I'll just list a few. But seriously, you can just play the game to see the differences.

The Extras (You can stop reading here. Seriously).

Game-play

  • Changed control system from tank style to something more familiar. Also used Unity's "new" Input System to include controller support.
  • A stamina system
  • Attacking system (complete with charging of attack to avoid spamming)
  • Player sprinting and jumping (jumping is a bit broken at the moment).
  • Enemy attacks.
  • A scoring system, get 6000 points to win (good luck with that). Saving the high score so that the score stays the same as long as your browser cache isn't cleared. 
  • Multiple spawn locations for the player. First location is the easiest to survive the longest.

Audio

  • Three music tracks that will be cycled through
  • Sounds for player footsteps, player attack, enemy death, enemy attack, enemy movement, an intro sound to go with the splash screen.

UI

  • An intro splash screen with the title of the game and a sound effect
  • A pause menu with a restart button, and two volume sliders.
  • Volume sliders that stay persistent between game play, and between closing the game and re-opening.
  • Health, stamina, and attack bars that fill (or deplete) with use over time.
  • A stamina system and sprint so that the player can run away from enemies (who are very slightly faster at a normal running pace).

Particle Systems

  •  Player attack thumps the ground, making rocks fly.
  •  Smoke also appears when the play attacks
  • Enemies exploding into blood.
  • Enemies spewing toxic gas onto the player as they attack.

Bug fixes

  • Millions of them.


And probably a whole lot more than that, but I was having fun. Thanks for reading! Next week the lighting and effects might change.



References

SFX

Intro sound: Fear Riser 2_FX with Verb - Nick Samples - https://freesound.org/people/NickSamples/sounds/792945/

Player Attack Sound: Ovani Sound - Hollywood Action Sound FX Pack Vol. 3 Stone Strike - https://ovanisound.com/

Enemy Move Sound: Ovani Sound - Foley Creatures Sound FX Pack Vol. 1: Flesh Move Loop - https://ovanisound.com/

Enemy attack Sound: Ovani Sound - Hollywood Action Sound FX Pack Vol. 3 Machete Kill - https://ovanisound.com/

Heal sound: Ovani Sound - Sound Epic Music Pack Vol.3: Bullet Hit Flesh - https://ovanisound.com/

Music

Music: Ovani Sound - Epic Music Pack Vol.3: Beast Mode, A New Era & Hope Is Gone - https://ovanisound.com/

Textures & Meshes

Health Fish: Fish Poly Pack - Astral Infinite - https://assetstore.unity.com/packages/3d/characters/animals/fish/fish-polypack-2...

Files

SharkAttackWebGL.zip Play in browser
38 days ago

Leave a comment

Log in with itch.io to leave a comment.