Before the story here is a link to the very very rough pre-pre-pre-alpha game. I have tried not to add any instructions as I hoped that it could be tutorial through discovery. I will add some to the next build.
WASD 🡐 🡒 🡑 🡓 — move
R — reset level
The goal only works if you are alone.
Touching another block makes it attach to you.
Blocks of the same colour disappear if they touch.
As a young game addicted youth (World of Warcraft) I always dreamed about making a game and learning to program. Countless weekends with RPGMaker making a grand epic world but very little coding. Some time with 3D Studio MAX making a little Black mage sprite wave. Lots of time on pro-desktop for my Product design classes.
Ho Chi Minh City was in lockdown. I had spent 2 week in a hotel room and when I finally got out I was faced with a few more weeks of total lockdown. Even delivery for anything more than groceries was suspended. I wanted to be productive during lockdown. This didn’t initially happen, first I watched all of Mr. Robot. That might have helped. But I have gone from isolation to isolation to isolation. It had been 2 months in suspension. Reading, cooking, watching shows, exercising, working, cleaning…. but it was getting old. I needed to make something.
It only took 15 years. I resolved to download UNITY for the… 5th time and actually finish a tutorial. No need to debate why I chose Unity over GODOT. I always just use the largest free program until I know enough to form an opinion. Blender, GIMP, audacity etc.
The first few tutorials that they place people into are frankly useless. Here a premade thing. Click and drag and fill in the blanks. Precisely the reason I disliked the other times I had tried. I grit my teeth. I finished them but I still did not have the first clue on what to do. There was of course the option of skillshare, Udemy or just flat out Youtube vidoes. I decided to have a proper look into learn.unity.com and lo and behold there was something actually useful 8 steps in. And after that essentials course that guided me around the interface there were another few with super basic beginner programming challenges.
As I worked through those tutorial I still needed a think of what game I wanted to make. Without this crucial step I knew my interest would falter. All the ideas I really wanted to make were far to complicated for a solo neophyte programmer. Even the cut down simplified ideas I kept try to come up with involved too much “design”. I needed to program. I look at some game jam videos for inspiration. Theses jams start with a core theme and a multitude of game spring forth. From that the designers built a core mechanic and a functional microgame. I chose the theme of ISOLATION for obvious reasons. I also set out some additional criteria.
- It would be a puzzle game
- It would only use blocks
- It would be 3D – for future projects
- It would be grid based
- The core mechanic would be simple
- Difficulty emerges from inventive use of this mechanic rather than platforming, timing or aim
The idea took a few days mostly because I was distracted by ideas better suited to a 3rd or 4th project. They required full 3d rigged character models. In my mind these other game would also be grid based puzzle games but more story driven so time spent on the simple puzzle game would definitely build toward this. The early puzzle ideas did not have any hook to them and I have forgotten them. Dismissed before they even had made it a scribble.
When I finally had the idea it was so obvious. Most block games had the mechanic of adding blocks to matching a pattern. What if the pattern was instead made by discarding blocks? What if you had to eliminate all blocks and the pattern was a sole block? The question was then, how to get rid of all these other block. Building on the theme of isolation, coloured blocks that match with a similarly coloured blocks vanish, leaving the player block all alone. Only then could the player progress to the next level.
While I did not realise it at the time, I later remembered a game featured in one of the game jam videos. I have not played sleepy blocks yet, and I will not until after I have finished my game. I am sure he has many great features and ideas, but I worry that if I see him use an idea, I would omit that idea to avoid copying him, and at this early stage I cannot afford to discount a good idea. I am still too much of a novice.
So the mechanics are
- The goal only works if you are alone.
- Touching another block makes it attach to you.
- Blocks of the same colour disappear if they touch.
- Blocks can go over the edge but the player cannot.
Minimal viable product. Finish a project. Deliver something, anything
The goal was to make a vertical slice of the mechanics. Then make 10 levels. Then figure out menus and add music. The simplicity of the mechanics was of course on purpose as I did not know how to code. It would give me a chance. It would also considerable cut down the chances of feature creep. I did not want to spend time more than was necessary. Lack of graphics, lack of anything animated, minimal time with lighting. Everything takes time and I wanted my focus to be singularly on programming something that worked. I would not add sound effect, or options or tutorial yet. My short time with Audacity frustrated me so I would like to wait until it is the focus of a large set of audio tasks when I take the time to learn how to use it properly, rather than it being the thing stopping me from making a quick edit of the music track into a loop when all I actually want to do is fix the menu. Deciding on a position for the camera also took far too long.
My time spent around programmers, general times as a physics teacher, and the ridiculous convolutions that exist in my personal admin spreadsheets did help me a lot. I can use a sine function make an object scale up and down from 100% to 80% and back again. I want it to rotate while it does that. Wait rotation is not matching the sine, surely both would be in degrees. Nope sine is radiant. Ah translating between the two is easy. I will eventually need to read up on quaternions again, but not today, I will never get that time back and forget everything the next time I need it. The text editors are very helpful now, auto formatting, pointing out missing semicolon immediately with and giant red stop signs. Far more enjoyable than I remembered from year ago.
Life would have probably been easier if I had made it 2D as it is essentially a 2D game. My reason were the game after this I want to be in 3D so lets get stated on learning that environment. Between my time working with 3d model, and my time spend with sprites in RPG maker, plus other times I had to make graphics with GIMP and inkspace, I knew how much I did not like sprites. It was an irrational and a bad choice. Even as a write this blog I am considering rebuilding the whole thing again from zero in a 2D environment. I had to still make textures and in doing so realised that in a very short space of time, and using a decent tool m its actually not bad. I should make something in 2D at some point. but not this. I will not admit I am wrong. Unless it runs badly on mobile devices. Then I will remake.
When learning a language, as I have tried to do living in non-English countries, there is an element of forgiveness. I can also freely blame the language for not making sense since the rules are arbitrary and based on historical quirks or formalisation of errors or borrowed from another language and many other ways to hand wave problems away.
Programming is not like that. It is frustrating because every mistake is your fault and the answer is right there. There is so much help and resources online. It is meticulously documented and exact. But when I had a problem the helpful forum post always seemed to give me code snippet that I did not know how to adapt, or where to put, or how connect to my other scripts.
I teach physics. One thing that is frustrating is watching students unable to complete a simple step. Especially if the step is something they know. This cannot be made simpler, your brain just has to click. In fact it already clicked, several times. It just needs to click reliably. For example, “treat perpendicular vectors independently”. They know what the individual words mean. They know what the concept is. They can recite the steps. They can point out when I do not do it. They feel like they are ready to use the knowledge, but as soon as they need to do it themselves it become impossible. I liken it to a board game. The first time I play it, no matter how simple the rules, I still need to ask “What happens when I roll a seven? but what if I have this card? and what is the order of play again?”
When programming I constantly did the same thing. Transforms and Game Objects are different. The logic is put in the wrong order so the bool gets set to false then back to true again before the next frame is able to do anything with it. You need a Rigidbody to interact with a collider.
A music bug really annoyed me. The audio would stop between the menu and a level, but not between levels. It was because in my haste to make a working build I put the following line in two separate locations rather than use a function. I knew this was bad practice. I knew dividing by an integer gives an integer. I knew it needed a float. But that does not matter. The program only does what I told it to.
// On load music.volume = vol / 3; // On clicking menu button music.volume = vol / 3f;
The most frustrating bug was with the goal. For some reason if there was a coloured cube next to the goal the player would still teleport away. This happened right at the end as I was having a friend test it. It had been working the whole time but evidently some kid of fix to another system now meant that the load new scene event was now happening before the attach cube event. But it used to work before. After ages I could not make it return to the old behaviour by tweaking the code so I fixed it the way I fix everything. With a bunch of new code that is called every frame and brute force the behaviour I wanted rather than executing neatly and efficiently. Because I had 1 goal. Make a working alpha. Fix it later.
I had to draw from a lot of the trite advice I give my students. That learning is not only a process of knowing the rules, but developing an understanding of the way said rules interact. Not to get worked up. Slowly revise and double check what they know and what they did. to say it all out loud. Lay it out properly. Sadly, despite repeating such phrases thousands of times, when it came to myself it was still not automatic, because doing is the only way to really develop, and I had not been doing those bit of advice, merely reciting them. But I also knew that sometime taking the time to write out and do everything properly breaks the flow. Scatter shot approaches can get you something that almost works. Ultimately flow keeps the engagement so I eschewed good practice and hacked together something that worked because it got me my alpha build. Just like the in decipherable scribbles in exam scripts that somehow produce an answer.
This also informed the type of frustration I was aiming for in my game. Fair because all the rules were in front you, and engaging because the simplicity of the rules means the one does not want to admit defeat.
I learned a lot from watching many gamedev logs on Youtube. It is also why I did not decide to record the any kind of video. That would need time to edit, and learn to edit, decide on a style, and script, and then do voice overs, then clean up the audio, and maybe even expand my storage to handle all these video files, and make a thumbnail and scrub through for personal details.
I wanted it to be paper based as its would be time taking me away from a screen. I did want to buy a good dot grid journal and make journal entries of what I was working on but we were in the middle of a strict lockdown. So I instead had to settle for whatever notebook I had lying around. It forced screen breaks to write out plans, go through the pseudocode steps, track things I attempted and ideas I did not want to forget. Most importantly I had to take the time to write down what I did at the end of the day, giving a fixed retiring point rather than “one more thing”.
That is also the reason I wanted to make a whole blog about it. I resolved to not make any more changes to the game until after I had made a functional WebGL build and hosted it. I later discovered that even though I have a build hosted on this site, and that it is the exact same build hosted on the unity play site, some settings needs to be changed or it will take 40 minutes to load. But I was not going to make ANY changes until I had properly taken the time to share it with a few people for testing. Blogged about it. Tweeted it. Added github. Rewritten the spaghetti code into something have decent. Then I can add new things.
That did not end up being quite true as I added some normal maps to give a colourblind option. Well it is not an option, it iss the default for now as I would have to learn how to use playerPref to make an option. There was also a level that existed twice because of a unity bug when deleting scenes. I also added a different texture to the wall as someone could not see it clearly. Fixed a couple of bugs that allowed her to move diagonally and clip through walls.
When building the game there were many times I broke previously working code and sadly could not go back as I was not versioning properly. All in service of getting that first build done. So the immediate priority is getting Github working properly. Good thing I waited before adding github. Every time I make a small change and press play this happens so I will have to fix this before getting back to the game. If I cannot make it play nice I might have to start from zero. That is not so bad. I had planned to improve the current project file so that I could practice patching and bug fixing a live working game rather than condemning it entirely and starting fresh.
But I have my game and a plan. Finisht he game, make it work on steam, itch.io and mobile. See the whole process.
Thankyou and please leave feedback