Summary
This project will attempt to remake Hannah and the Pirate Caves (HATPC) from memory as an educational pursue. There is no guarantee on the project. No deadline and no expectations.
This wiki will serve as a public diary of the design and whatever thoughts I have while on this project.
Why
Some time ago, I wanted to learn about game engine and to implement one for educational purposes. However, I didn't really have a good reason to do so. Apparently, just implementing a game engine without a proper game isn't enough to push me to attempt the project.
One day, I remembered playing Hannah and the Pirate Caves from Neopets years ago. I remember it being a fairly straightforward platform but really fun. Then, it hit me: "Why not re-create that game?", followed up by "Why not create a game engine for this?". That's the motivation I need to do this project.
Goals
The main goal is simple: Recreate Hannah and the Pirate Caves as closely as possible, implementing my own engine. Again, the purpose of this project to learn what goes on in a game engine and gain a appreciation for modern game engine. To help out with this, I am lightly following the COMP4300 C++ Game Programming by Dave Churchill here. I recommend this lecture series to anyone who wants to look into game engine, particularly Entity-Component-System (ECS) design.
Although this is a remake, it is not a faithful remake. All these are implemented based on how I remembered it to be, and how I want it to be. I do aim to implement all the existing mechanics, but do not expect 100% parity.
Some Early Decision
Programming Language
The first I have to make is the programming language of choice. The lecture series uses C++, which make senses given its STL containers and Object-Oriented functionality provided, both facilitates well into game engine implementation.
However, being the stupid person that I am, I decided to use C instead. These are my (bad) reasons:
- I'm more familiar with C than C++
- C is simple (not easy. There is a difference)
I'm a masochist
Why not Rust or <Insert other languages>
I have looked into Rust before settling on C. Once again, I'm not too familiar with Rust and the point of the project isn't to learn a new language. If it is so, I would have picked another project for it. That said, I do see the merits of Rust and would try it out proper one day. I am prepared to shoot myself in the foot using C.
C is so limiting
Yes, but that's also part of the reason why I want to do this in C. I want to see what kind of solution can be used in this journey to implement a game engine in C. To me, this is quite satisfying.
That said, I am not opposed to using external libraries. There are a few libraries why I would use an external library:
- Implementing that functionality does not provide me satisfaction and fun
- I am not confident in my ability to properly implement that particular functionality
- Shorten development time. This indirectly helps with burn-out.
- Using said library does not take away the learning experience
With that said, I do wish to keep external libraries usage to a minimum.
External Libraries
Raylib link
Similar to the lecture series, I'm using a library to handling drawing onto the screen and input polling and handling. These topics are their own rabbit holes and would have exploded the scope of the project. The library used is Raylib. It is a minimal library for game programming.
I have used this library before and have positive reception towards it thus far. Hence, this is my choice of library for the project
SC link
Another thing that will be important for development is data structures. Common data structures such as vector, FIFO/LIFO data structures, and maps are going to be useful in the game engine implementation.
After searching a little bit, I've decided to go for SC. It is simple to use and has a permissive license. There may be better alternatives, but this is the first good one I've found. So far, I'm having a good time using it.