Preface
Independent video games are larger than ever, and are finally easy to create for anyone passionate about gaming. Over the past few years, the technology to create games has been made easier and more available. There are now free, beginner-friendly engines, such as Unity3D, which novice coders can use to create functioning prototypes in a matter of hours. With the release of the OUYA console, an Android-based console created as a publishing platform exclusively for independent developers, indie games can now be published and played on any TV in the comfort of your living room, making indie games even more pervasive and profitable. This book will give you everything you need to get started with creating three-dimensional games for OUYA as fast as possible, and provide you with the knowledge you'll need to keep growing as an indie developer by the time you reach the end of the book.
What this book covers
Chapter 1, Experiencing the OUYA, demonstrates the usage of the OUYA console and examines its user interface and technological capabilities.
Chapter 2, Installing Unity and the OUYA ODK, shows you how to install and configure the development environment required to create games for OUYA using the Unity3D game engine.
Chapter 3, Diving into Development, describes the anatomy of a basic script in the Unity3D engine and shows you how to create your first basic prototype.
Chapter 4, Moving Your Player with Controller Input, discusses how to create an interactive player object that responds to input from the OUYA controller.
Chapter 5, Enhancing Your Game with Touch Dynamics, talks about the built-in uses of the OUYA controller touchpad in the Unity3D engine and extends its functionality to create custom touch gesture mechanics.
Chapter 6, Saving Data to Create Longer Games, implements a basic data saving and loading functionality in prototypes from previous chapters and helps you understand the value of saving progress and other information.
Chapter 7, Expanding Your Gameplay with In-app Purchases, ensures that your prototypes meet the OUYA content guidelines required to sell a game on the OUYA marketplace. It also explains the finer aspects of packaging and polishing a game in Unity, including visual improvements, menus, and tutorials.
Chapter 8, Polishing and Prepping Your Game for Deployment, illustrates how to create both kinds of in-app purchases supported by the OUYA SDK and explains the differences between the purchases and the applications of each.
Chapter 9, Blazing Your Own Development Trail, helps establish the knowledge you need to grow as a game developer on your own and explores several techniques and tricks not covered in previous chapters.
What you need for this book
To use this book, you'll need a PC that is running a Mac OS X or a Windows operating system as well as an OUYA console to test and play your games on, including all related hardware (a USB cable, controller, display cable, and so on). You'll also need to install the Unity3D engine, which is available for download at http://www.unity3d.com/.
Who this book is for
This book is for anyone who wants to become an independent video game developer but doesn't know where to start. The OUYA console and Unity3D game development engine were both made with small-scale development and ease-of-use in mind, so you'll use both of these to prototype several different games and mechanics and learn how to make your dream games come to life.
Conventions
In this book, you will find several headings appearing frequently.
To give clear instructions of how to complete a procedure or task, we use:
Time for action – heading
Action 1
Action 2
Action 3
Instructions often need some extra explanation so that they make sense, so they are followed with:
What just happened?
This heading explains the working of tasks or instructions that you have just completed.
You will also find some other learning aids in the book, including:
Pop quiz – heading
These are short multiple-choice questions intended to help you test your own understanding.
Have a go hero – heading
These practical challenges give you ideas for experimenting with what you have learned.
You will also find a number of styles of text that distinguish between different kinds of information. Here are some examples of these styles, and an explanation of their meaning.
Code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles are shown as follows: "Open your RollingMarble
Unity project and double-click on the scene that has your level in it."
A block of code is set as follows:
void Update() { if(Input.GetKeyDown(KeyCode.Return)) { print(ChangeColor(Color.green)); } else if(Input.GetKeyDown(KeyCode.Space)) { print(ChangeColor(Color.blue)); } }
Any command-line input or output is written as follows:
source ~/.bash_profile
New terms and important words are shown in bold. Words that you see on the screen, in menus or dialog boxes for example, appear in the text like this: "Click on Sign up on the following page and follow the instructions to create your OUYA developer account."
Note
Warnings or important notes appear in a box like this.
Tip
Tips and tricks appear like this.
Reader feedback
Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or may have disliked. Reader feedback is important for us to develop titles that you really get the most out of.
To send us general feedback, simply send an e-mail to <[email protected]>
, and mention the book title through the subject of your message.
If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide on www.packtpub.com/authors.
Customer support
Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.
Downloading the example code
You can download the example code files for all Packt books you have purchased from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.
Downloading the color images of this book
We also provide you a PDF file that has color images of the screenshots used in this book. You can download this file from http://www.packtpub.com/sites/default/files/downloads/7224OT_ColorGraphics.pdf.
Errata
Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in the text or the code—we would be grateful if you would report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this book. If you find any errata, please report them by visiting http://www.packtpub.com/submit-errata, selecting your book, clicking on the errata submission form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded to our website, or added to any list of existing errata, under the Errata section of that title.
Piracy
Piracy of copyright material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works, in any form, on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.
Please contact us at <[email protected]>
with a link to the suspected pirated material.
We appreciate your help in protecting our authors, and our ability to bring you valuable content.
Questions
You can contact us at <[email protected]>
if you are having a problem with any aspect of the book, and we will do our best to address it.