If you’ve ever played a game and started wondering “how do people make these things? 🤔”, then you’re not alone. It was these sparkles of curiosity that made me discover the world of programming and game development. Since then, coding and making video games have been a hobby of mine that I would spend hours and hours every week.
Hi, I’m Duong and in this article, I’d like to tell you about a recent project that I worked on, its development process, and some interesting things I found out along the way.
Dave the Duck
Dave the Duck is a game about a duck painter trying to draw the masterpiece of his life. It was a submission to the game jam I can’t draw but I want to make games, a jam all about not being able to draw super detailed characters and artwork for games.
I made it in one week using the Unity game engine and some other complementary tools such as Visual Studio Code or Inkscape. Most of the 3D models in the game are simple shapes like cubes or spheres, which the Unity Editor provides, so there was no need for a 3D modeling application.
The player views the game world from an isometric perspective and through an orthographic camera which is a great way to eliminate the complexity of depth, scale and also add a touch of novelty to the presentation of the game.
The main mechanic is simple: the player controls a duck to move around on a canvas, this duck will then paint any area that he touches with a pre-defined color. If the player can paint the entire canvas before a timer runs out, they can move on to the next level. I think this works well enough for a novelty game and I can complete it in time for the game jam.
Paint the picture
In this section, I will walk you through the development process of Dave the Duck.
I started by creating the duck himself. The model comprises two spheres representing Dave’s head and body and a very stretched sphere representing his mouth.
I was rather happy with how he looked. He, however, still felt somewhat stale and boring.
So, I added some animations.
That’s much better 🤘
I implemented the duck’s running mechanic in no time, added some scripts to animate him as he is running and voilà, we have a running, animating duck.
The next thing to do was implementing the canvas platform. In order for the duck to paint this platform in separate areas, I figured I have to combine many smaller cubes to form a larger platform. I can then paint these cubes individually to give the illusion of painting in areas. There might have been a more comprehensive way of going about this (like using decals) but I decided that was the quickest and easiest route.
Then, it was time to implement the color-changing feature. I added a box trigger to the duck and every cube to detect whether the duck should paint this cube. I created a set of colored materials to use in the scene. I will assign each cube one of these colored materials, which is the color that they should change to. When the level starts, these cubes will revert to their default materials. When they come in contact with the duck, subsequently, they will change their materials to the colored ones.
Looking good, huh?
I added a timer and a rating system to add some stakes to the game, some supporting mechanics like teleportation and elevation, and it looked a lot more completed.
But is it, though? No, no, it’s not. Time for some polishing.
I added some trail particle effects, more animations, post-processing effects, a bit of camera shake and camera transition and this is the eventual results:
Now that’s what I call video games 😎. I also figured it would be nice if the player can view their painted picture after they complete the level.
And that’s it! I added a few more levels, a level progressing system, and I finally completed the game.
Exposure vs Quality
One of the hardest decisions that I had to make during the development of Dave the Duck was which platform to target. To most developers, this almost seems like a straightforward decision. Since Unity is very versatile in this aspect, it’s super easy to just make a game and then build for Windows, Mac, and Linux. So why was it my hardest choice?
I was considering whether to target the Web platform.
This may sound ridiculous. Why would I want to work with the constraints of the Web platform when I can easily be free of them and just make my game target native desktop platforms instead?
The answer is exposure. Statistics show games that are playable directly in the browser have a higher chance of getting played by curious sight-seers. Targeting the Web platform would increase the player base of the game, leaving it exposed to even more players. Having more players will lead to more feedback and insights from them, helping you grow as a developer. Besides, who doesn’t want as many people to experience their project as possible?
Targeting the Web platform can, however, have some drawbacks as it may hinder players’ experience. The processing power and graphical capability of the Web are, compared to native platforms, severely limited. The performance of the game also relies heavily on the player’s connection, which is not always in ideal conditions. These may cause lag, stuttering, and overall frustrating experience.
Dave the Duck run natively on Windows at a stable 60fps
Dave the Duck run on WebGL with frame rate averaging at around 25fps
Unless you can choose both (which I couldn’t), the answer ultimately depends on the scope and size of your game and you, the developer, to choose which direction your games will go.
No artist, no problem
One of the biggest challenges I face as a game developer coming from a programming background is that sometimes it’s very difficult to make your games look good when you don’t have tremendous talent in art and design (which I don’t 🙃). I know that many developers are struggling with this the way I did, therefore I’d like to share some tips I learned throughout the development of Dave the Duck that can make your game look a lot nicer.
- Color and contrast: One thing that I’m very guilty of when starting out is using every color randomly and boringly. Color theory is a long and complicated topic that I will not dive into here. However, at the most basic level, one piece of advice I can give you is to use two colors on opposite sides of the color wheel as your primary and secondary color for your game.
With Dave the Duck, I use yellow and dark blue as the two contrasting primary and secondary colors.
If you’re too lazy to figure out the colors yourself, no worries, use a color palette. A color palette comprises multiple colors that work well with each other. There are sites like Lospec or Color Hunt that provide you with great color palettes you can use in your game. Whatever you do, just don’t pick a color at random.
- Animations: Animations provide some subtle, but necessary, feedback to the player about events happening in the game. These animations don’t have to be super complicated character rigs or frame by frame drawings, they can just be a slight change in position, a small increase of size, etc. Never leave your scene at any point in the game, with everything on-screen unanimated, it makes your game feel lifeless and boring.
Dave the Duck with and without animations
- Particle effects: Again, these don’t have to be photorealistic explosions or smoke effects but tiny dust when a character is walking, trails left by moving objects, etc. Similar to animations, particle effects are subtle but important in bringing life to your game.
- Post-processing: This is optional, as it takes a hard toll on your game’s performance. However, if you want that last bit of juice in the game’s feel, this is a must. Unity conveniently provides most of the effects through the post-processing package, with most of them already configured for the best balance between graphics and performance. I would, however, advise that you go through these effects, tweak them and see whether they fit the look that you’re trying to achieve or not as enabling all of them not only tank performance but also make the game look unnecessarily noisy.
Dave the Duck with and without post-processing
The promise you can’t keep
I released Dave the Duck with only 7 levels and promises to add more levels and supporting mechanics in the following weeks.
I never did.
This is one thing that many developers (including me) are very much guilty of. You work on a project, finish it, move on to the next one, and the cycle repeats. Without spending time to look back and reflect on what you’ve done, you are likely to repeat the mistakes you previously made. Think about what makes you proud of and what disappoints you during the development of the game and find out ways to capitalize or improve them.
If you think you’ve completed a project, you’re probably only halfway there. I recommend you take a bit of time after publishing your game to improve it even further. Test it more, fix the bugs you didn’t see, add more content, and interact with the community. These not only extend the lifespan and player base of your project but also help you grow and learn as a developer. And maybe even write a postmortem about it, why not?
A mistake I made so you don’t have to.
One does not simply
Game development is a long and tiring journey, but you made it this far, don’t give up. Keep improving, learning, and even failing so that one day, your dream game will become a reality.