Unfathom
Get to the bottom of the ocean. How far can you make it before giving up?
Controls:
Down Arrow - Go Deeper
Credits
- Credit for the fish art goes to reddit user Wizard_Smoke and their post https://www.reddit.com/r/PixelArt/comments/913b0l/pixel_fish/
- Everything else was done by me for this jam.
Why does this game exist?
TL;DR - Adding the simple restriction of making a game as small as possible made me realize how inflexible I am with creating.
This game is for https://itch.io/jam/mini-jam-159-ocean. I joined with 1 day left in the jam and decided to impose the limitation ("as small as possible") on the actual game creation process. The criteria I used:
- As few files as possible
- I only count files that are directly used in the game.
- Ex: I ignore the .import files that Godot creates for each image because they just map to the compiled image used in the editor, but include the project.godot file because it has specific settings that help run the game in it.
- I only count files that are directly used in the game.
- Files are as small as possible
- As few lines of code as possible
- within reason, I'm not going to mess with standard code formatting to create some monstrosity.
Design
This is a pretty bare-bones 'game'. You hold down and go deeper into the ocean, occasionally seeing a fish swim by. I kept the game logic to a single file with a single method, and simplified the input handling to only be 3 lines. Honestly, the fish that shows up randomly used the most lines of code and most storage space for the fish images, but it didn't feel right to call a 'mostly blue image with a number in the corner that counts up' a game. So the fish stays for the little entertainment value it provides :)
I wanted to use a shader to make the screen get darker as you go deeper, as that seemed reusable and simple to add, but creating a shader adds another file, and takes over 50 lines of code to implement, which was too much to be worth it (for reference all of the game logic was 18 lines). Instead, I extended the background image downwards (over 10k pixels in height), created darker layers, and offset the image height according to the 'depth' in game. I also saved this as a compressed jpg, reducing the file size by 50% (from it's png version).
For the fish, I found a reddit post with some great pixel art, so I used it as a spritesheet for selecting which type of fish to show. It randomly selects between 35 'frames' of fish, keeping all the fish images in one file. This needed to stay as a png for the transparency, so not much file size reduction there.
How did I do?
File Count
If you ignore the engine/VCS specific configuration files (like Godot's export_presets.cfg and git's 'ignore' file) and only count the files that directly contribute to running the game, I used 5 files. The files I consider valid are:
If this were golf, I think only using 5 files is par. It's not too impressive, but not terrible either!
File Size
These 5 files had a total size of ~72,420 Bytes, or ~72.42 Kilobytes. Most of this came from the images, specifically the fish spritesheet (42 KB). I scaled it down to the pixel size I needed, but it already wasn't my image (so I felt bad messing with it) so that's all I did to it. I'm also not familiar with compressing png files. Overall I'm pretty happy with the total size of the game files. I had wanted to end under 50 KB, but the time limit and my inexperience with tiny games are both limiting factors.
Lines of Code
I think this was my worst metric. Ignoring comments and whitespace, the project settings were ~30 lines, the game scene was ~230 lines, and the game logic was ~18 lines. Having roughly 280 lines of code/configuration for a game of this scope seems like waaaaay too much. I cleaned up some of the game scene and project settings manually, but it was a constant fight against Godot's need to auto-format (hence why I added the 'within reason' clause). If I wanted to reduce the lines more I would have to write some custom game setup code. This quickly becomes a balancing act between myself and Godot; Who can write more concise code?
Comparison
Comparing this with my previous GameJam game (Latency), that was a 2 week jam and I ended up with over 50 files, a total of 14,000,000 Bytes (14.5 Megabytes), and 1600+ lines of code. While that game has a lot more polish, I am still impressed I was able to make something with less than 10% of the resources.
And Finally, The Conclusion
Overall, I think this was very eye-opening! While this might not be a good game, it was a good lesson. I followed the limitation well, but counterintuitively I felt myself bumping up against the limits of my experience, knowledge, and skill while making this small game. I don't know enough about image compression to really lower my file size (my art is also programmer art). And I don't have the knowledge to write project settings or the game scene without the Godot editor so I am fighting against auto-generated code and the auto-formatting that comes with it. Adding a simple restriction made me realize how inflexible I am with creating.
If you read all of this, thank you for reading! I tend to ramble, especially with minimal sleep :)
Here's the repo for this project if you want to take a look: https://github.com/SlickleCode/MiniJam159
Comments
Log in with itch.io to leave a comment.