Learning Stencyl 3.x Game Development Beginner's Guide
上QQ阅读APP看书,第一时间看更新

Preface

Creating video games has traditionally been a long and complicated process, requiring years of experience and a vast array of skills. However, with the introduction of comprehensive game-development toolkits such as Stencyl, the fun has returned to the art of game creation—anyone who has the desire to create his or her own video game can now do so with almost any desktop computer and a free software download from the Internet.

Stencyl eliminates many of the tedious and time consuming aspects of game development, but getting to grips with such a comprehensive software package can be somewhat daunting—there are so many great features that it's difficult to know where to start!

Learning Stencyl 3.x Game Development: Beginner's Guide will guide you through learning the essential skills that are required to create your own video games without knowing how to write computer code. We're going to start with a blank screen and, before we reach the end of the book, we'll have developed a complete game, ready for publishing. We won't stop with just the basics in place—we're going all the way, right through to including many of the important features that we would expect to find in a professional production!

Let's install Stencyl and create a video game.

What this book covers

Chapter 1, Introduction, explains what Stencyl is, how it works, and how we're going to learn the skills that we need to develop our own video games. We'll also install Stencyl and check that the installation is working as expected.

Chapter 2, Let's Make a Game!, guides us through the first steps of creating our game. We'll learn how to control our game's main character, design a game level with platforms, and create a scrolling display.

Chapter 3, Detecting Collisions, explores the management of different types of collisions within Stencyl. We'll add enemy characters and collectible items, and we'll fine tune the collision detection by modifying collision shapes.

Chapter 4, Creating Behaviors, explains how we can take full control of how our games work, by constructing our own custom gameplay routines. We'll learn how to use Stencyl's instruction blocks to introduce more advanced features into our game, such as random in-game events and decision making.

Chapter 5, Animation in Stencyl, introduces some of the different ways in which we can implement animation in our game. We'll discover how to bring our in-game characters to life with Stencyl's built-in animation and graphics editing tools.

Chapter 6, Managing and Displaying Information, focuses on managing information and sharing that information with players of our game. We'll be learning how to display text on screen, keep track of collected items, and also how to display a countdown timer bar.

Chapter 7, Polishing the Game, shows us how to add some essential elements to our game, such as an introductory screen, a game-over message, and a pause feature with a pop-up banner. We'll also be implementing an interesting visual effect and creating additional levels for our game.

Chapter 8, Implementing Sounds, concentrates on the skills that we need for implementing audio within our game. We'll learn many of the important techniques required for introducing sound effects and a soundtrack, to add that final professional touch to our games.

Chapter 9, Publishing and Making Money from Your Games, explains how we can publish our games on the Internet, and discusses some of the options available to us for selling or licensing our games. We'll also discover how to implement in-game advertising so we can earn some money each time our games are played.

Chapter 10, Targeting Mobile Platforms, discusses how we can test our games on mobile devices, and we'll also learn how to use the accelerometer and touchscreen features to control games.

Appendix, Planning, Resources, and Legal Issues, examines some of the important aspects of planning the development of a video game. We'll also consider the availability of third-party tools and resources and, finally, we'll review some of the legal aspects relating to the use of third-party assets within our video games.

What you need for this book

You will need to download Stencyl 3.x from stencyl.com.

Stencyl can be installed on Microsoft Windows XP (and later versions of Microsoft Windows), Mac OS X, and Linux (Ubuntu distributions recommended).

No prior knowledge of game development or computer programming is required.

Who this book is for

This book is for beginning game developers who have no prior knowledge of creating games or computer programming.

It's also an ideal resource for experienced game developers and designers who need to create rapid prototypes, or who want to speed up the game-development process.

Teachers and students, who think learning should be fun, will also benefit from this book!

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

  1. Action 1
  2. Action 2
  3. 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:

Have a go hero – heading

These are practical challenges and 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 are shown as follows: "The game file named 5961_02_13.stencyl represents how our game should look at this point in the book!"

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: "Before we can open up another game, we should close the Adobe Flash Player window in which the previously tested game is running, and we must close the current game in Stencyl by clicking on File | Close Game and follow any prompts that appear".

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 , 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/diagrams used in this book. The color images will help you better understand the changes in the output.

You can download this file from: http://www.packtpub.com/sites/default/files/downloads/5961OT_ColoredImages.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 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 if you are having a problem with any aspect of the book, and we will do our best to address it.