Building A Game With Unity and Blender - Sample Chapter
Building A Game With Unity and Blender - Sample Chapter
Building A Game With Unity and Blender - Sample Chapter
D i s t i l l e d
E x p e r i e n c e
P U B L I S H I N G
Sa
m
pl
C o m m u n i t y
$ 44.99 US
28.99 UK
ee
Preface
In the wake of the indie game development scene, game development tools are
no longer luxury items costing up to millions of dollars but are now affordable
by smaller teams or even individual developers. Among these cutting-edge
applications, Blender and Unity stand out from the crowd as a powerful combination
that allows small to no budget indie developers or hobbyists alike to develop games
that they have always dreamt of creating.
Preface
Chapter 7, Creating Levels and Game Progression, will help you learn how to create
in-game power-ups to boost your player's ability and create save points to save
your game progression.
Chapter 8, Post-Production and Visual FX, will show you how to enhance your game's
visual quality by learning how to apply camera effects to your game and create
numerous types of particle effects.
Chapter 9, Deploying the Game, will help you learn how to deploy your game for
multiple types of platform with Unity.
[1]
Tester: A game tester helps to playtest the game during the development
phase to ensure that it's free of a programming bug and complies with
the requirements set by the publisher. They will also make sure that the
gameplay meets the expectation of the game designer and that it's fun to
play with.
There are many other job roles that we have not covered here, such as an AI
designer, a level editor, a lighting artist, and so on. Specialized roles like these are
normally only available in big studios, which have the resources to ensure that every
aspect of the game they are creating is at its highest standard.
For a smaller game development team, an individual team member can handle
multiple roles, and more than one person can share some roles in order to split the
workloads.
Gameplay design
The process of gameplay design can be divided into five major stages.
[2]
Chapter 1
Starting point
Different people have different approaches in designing a game. Some designers like
to start with the characters' design or storyline, and only after that, they will decide
what type of gameplay is suitable for it. On the other hand, some designers like to
start with the gameplay instead. There is no absolute rule on how to start designing a
game; it's entirely dependent on what inspires you in the first place: Did a good story
suddenly pop up in your mind? Were you inspired by a game you loved to play
during childhood? Or were you inspired through silly conversations with your best
friends? Write down your initial ideas; who knows, it could become the next popular
game one day.
For me, I like to start by choosing the game genre and designing the gameplay right
before anything else. I find that it's quite important to design a gameplay early on
so that it can be tested repeatedly and to check whether the gameplay is fun or not.
Otherwise, all the time we spent on writing a good storyline might be wasted if only
to find out the gameplay simply doesn't work the way we had imagined. You can try
to experiment on different approaches and see which method suits you more.
One mistake made by most of the newbie game developers is neglecting the
importance of a game design document (GDD). A GDD is usually a collaborative
effort within a development team to organize ideas and help convey the designer's
vision to the rest of the team. It also helps to make sure that everyone is working
together at the same page, avoiding assumptions, and conflicting workflows.
Besides this, GDD is also very helpful for solo developers. It allows you to see the
bigger picture of your game and easily spot any major flaws in the game design.
Other than this, you can also look at the list of every aspect of the game and decide
what needs to get done based on its priority.
Most of the time, a common office suite, such as Microsoft Office, OpenOffice, or
LibreOffice, is sufficient for creating the GDD. If you're in a team, however, it's
best to use an editor that has the capability of real-time collaboration between
team members. I personally find Google Documents very useful for this purpose,
especially during brainstorming sessions where every team member can contribute
their ideas and let others to see them during discussion. Try to pick the most suited
tool for you and your team.
Alternatively, you may also invent your own genre if you are the type of person who
likes to try out new ideas and always think out of the box. Although this may sound
overly ambitious, but this is actually doable, as game genres are being invented all the
time. However, following this path requires a ton of prototyping to prove that your
idea is workable and fun as you're trying to create something that no one has even
seen before.
If you have no idea which genre to pick at the moment, you might want to look at
the statistics of the best-selling video game genres, and hopefully it will give you
some inspiration:
It's important to decide on the genre early before you start working on the game. Basically,
switching game genres during development means starting all over again from scratch.
Game mechanics
Gameplay is something that connects players' actions with the purpose of the game
and its main challenges. Gameplay will define what the player can or cannot do in
the game, as well as conditions that allow the player to progress through the game.
Gameplay design involves a wide range of designing aspects, such as a level design,
gameplay balancing, player behavior prediction, and choices planning. All of this
can be incorporated into something called game mechanics.
[4]
Chapter 1
Game mechanics are constructs of rules that make up the gameplay of a game.
It determines what actions the player can take, how the actions interact with the
game states, and how other game entities respond to the player's actions. Gameplay
defines what a game is to the player, whereas game mechanics are the parts that
define the gameplay itself. In other words, gameplay is nothing more than a set
of game mechanics. Oftentimes, gamers are popularizing famous games for its
game mechanics. For example, Gears of War was famous for its cover mechanic
when it first released in 2006. Prince of Persia blew peoples' minds away when first
showing two of its famous mechanicsthe parkour mechanic as well as the time
manipulation mechanic. Angry Birds would not have been downloaded by two
billion times across the globe if it didn't feature the slingshot mechanic!
We can split a set of game mechanics into two main categories: core mechanics and
sub-mechanics. Core mechanics are the most important mechanics in your game. You
cannot simply change your game's core mechanics because it will break the nature
and essence of your game. For example, take away the shooting mechanic from
Counter Strike, and the game would simply become something else, but something
other than Counter Strike. It will not make any sense at all to play Counter Strike
without a shooting mechanic. Sub-mechanics, however, can be taken away without
breaking the game. Again, we use Counter Strike as an example, but this time, we
will take away just the jumping mechanic. Now the players can no longer jump, but
that doesn't make Counter Strike a different game; it's still a first person shooter, you
can still make the headshots. It's important to determine what are the core mechanics
of your game early on, but not so important for sub-mechanics. You can add in submechanics later on during the production stage because, as previously mentioned,
it won't break the game. A strong and solid core mechanics will ensure the success
of your game, so focus on it first before anything else. After this, you can try to
experiment on different sub-mechanics to enhance the gaming experience.
In short, proper planning will ensure that the gameplay is balanced, unpredictable,
and makes sense to the player. Even an experienced game designer can hardly
design a perfect gameplay in one shot. It takes a ton of testing and iterations in order
to get the gameplay to feel right and fun to play with. The formula is simple: test,
test, and more tests!
[5]
Level design
A level is the venue where a player interacts with the gameplay elements. It can also
be called as a map or stage. As a level designer, you're responsible for designing
the layout of the levels to comply with the purposes of your gameplay: Does this
level carry missions? Is this level for multiplayer purposes? Roughly how long do
you expect the user to play this level? You need to ask yourself all sorts of questions
before you start designing your level.
One important aspect of level design is flow control. Game level with good flow
control can direct a player toward the goal of the level and prevent idling or moments
of unintentional confusion from occurring in game. You need to be clear about the
intent and purpose of the particular level and then by using the elements within the
level, such as lighting, props, and items. You can subconsciously lead the player
toward the goal. You will learn more about this later when we design the environment.
Let's have a look at the sample level I designed for this book. Players must search
for the key in order to open the gate and fight the final boss. While exploring the
environment, player will occasionally encounter monsters and involve in intensive
battles. There are also some items aligned randomly across the path for the player to
pick up, restore health, and help progress the game. Here's an image showing a simple
level with simple gameplay in mind to demonstrate what a map layout looks like:
[6]
Chapter 1
Rapid prototyping
Rapid prototyping is a good way to quickly test out your game idea and see if it
works the way you want. Sometimes, a game idea might sound good only on paper,
but it just doesn't work out like how you'd imagine it to be. The last thing you want
is to only realize that you have been working on a bad idea in the middle of the
development phase. Rapid prototyping not only saves you from this situation, but
also allows you to think out of the box and freely experiment on all kinds of random
ideas. If the idea works, then it is great; if it doesn't work, just scrap it and try the
other ideas.
When you rapidly prototype your game, you should stop worrying about the
graphics and just focus on the gameplay mechanics alone. The character could be
just a cube, a sphere, or anything simple. The level could be just a plane or with more
cubes on it acting as obstacles. You also shouldn't worry about the storyline at this
stage because you might be scrapping the idea minutes later.
Unity Game Engine, the game development tool that we will be using in this book,
is built for rapid prototyping in mind. It's extremely easy to just throw in some
primitive shapes, applying some scripts to the shapes, and you are good to go. You
can instantly start playtesting your ideas without much effort spent on setting up
the game engine. In addition, you can download sample game assets from the Unity
Asset Store, including 3D models, animations, and even sample scripts to kick-start
your prototyping process.
Besides this, there are also plenty of plugins available at the Unity Asset Store,
which provide extra tools for you to rapidly construct a demo level or create game
mechanics without the need of writing any code. All-and-all, Unity Game Engine
makes rapid prototyping even more rapid with the features mentioned previously.
You will only be learning how to use Unity in later chapters.
Chapter 1
When designing characters, it's best to start with the silhouette. Try to define the
character's personality using only the silhouette and ignore all other forms of
details. We don't need to worry about the color, texture, facial expression, clothing,
accessory, and anything else at this stage. Focus only on the body shape, size,
contour, and posture that can easily make a player recognize the character and be
able to tell the roles of the characters by simply judging from its outlook.
I prepared an image showing three characters' silhouettes. Try to guess what their
personality is by judging from their respective silhouette.
Character B: The second character looks like an ordinary person, but his
uneasy posture infers that he could be a sly character with bad intention.
Better not to get too close to him.
Character C: The third character looks extremely dangerous even from afar!
Does he bite? I'm sure he does more than that!
Once you have chosen the silhouette of each character, you can now start adding
detail! However, no color should be used at this stage. Use only lines to sketch out
the appearance of the characters. Concept sketches should be fast, and it's okay for
the sketches to look messy at this stage because we want our brain to continuously
come out with different ideas without being distracted by small details. Don't be
afraid to experiment with different ideas you have, you might be surprised how
creative you could be!
[9]
After you've done a dozen or so rough sketches, pick one that you think most
suitable for your game. Redraw the characters with fine lines and make sure that
they look clean this time because we are going to put some colors on it!
The following image shows the sample characters' concept that I used for this book.
I have chosen a more manga-ish, chibi style for my game characters. I skipped the
silhouette and rough-sketching steps because well, the game demo I'm showing in
this book is just a very, very simple game, so it's exceptional.
Character A: Block out the character with simple shapes, only simple shapes!
After you have done all the clean-up jobs, we will proceed to the next stage, which
is adding colors to your characters! Use only plain colors to fill in the design at
this moment. No lighting or shadow should be allowed because again, we want to
focus on experimenting different sets of color pallets on our characters and not be
distracted by elements.
Be cautious when deciding the color palette for your characters. Choosing
the wrong color could influence your player's interpretation toward
your character's personality and role. Wrong color could also affect the
visual focus of your character, making it hard to be seen on the screen (for
example, a green character standing on a grass field).
Here, I experimented with three different colors on my character. I picked the one
that, in my opinion, resembles his personality:
[ 10 ]
Chapter 1
Character A: Although red color looks really nice on him, it looks way
too aggressive and that doesn't suit my faint-hearted character.
Character B: Blue color looks more calm and friendly, which is suitable
for my character.
The same method is used for the monster design as well. Eventually, I picked the
one with red/pink patterns on its body. The color is more aggressive and at the same
time contradicts with the main character's color. Also, warm colors, such as red or
orange, often represent caution or danger. In order to speed up the process, I will
just pick monster C as the final boss.
[ 11 ]
Finally, create a scale comparison chart to let everyone in your team know exactly
how big or small should the characters look like. This information is extremely
important for the 3D artists as well as gameplay designer. Make sure that everyone
in your team is aware of this chart.
[ 12 ]
Chapter 1
Summary
In this chapter, you learned all the important aspects on how to design your own
game as follows:
The process of creating concepts for your game character and environment
In the next chapter, we will gain knowledge on how to turn our characters design
into 3D models using Blender.
[ 13 ]
www.PacktPub.com
Stay Connected: