O'Reilly logo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Stencyl Essentials

Book Description

Build beautiful, unique, cross-platform games rapidly with the free Stencyl 2D game engine and toolset

In Detail

With the incredible growth in the global games industry over the past few years, Stencyl makes it possible for anyone to learn how to create amazing, engaging, and polished 2D games in just a fraction of the time.

Whether you are new to game development or an experienced developer looking for a quicker, more intuitive way to prototype, develop, and publish your game ideas, this book will show you how to achieve your game development goals using Stencyl. By following a clear, step-by-step development cycle for our first game prototype, you will rapidly gain a working knowledge of the Stencyl game engine and toolkit. With ample screenshots, you can be certain that you'll be able to follow along at every stage.

What You Will Learn

  • Discover the key benefits of Stencyl, its technical structure, and what makes it so special
  • Understand and work effectively with the Stencyl interface
  • Set up scenes and alter their settings at will
  • Import and utilize graphics
  • Integrate sound FX and music in your games
  • Create and configure actor types and instances
  • Implement tilesets and backgrounds by importing them in to your game
  • Write custom behaviors to control your actors

Downloading the example code for this book. 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.

Table of Contents

  1. Stencyl Essentials
    1. Table of Contents
    2. Stencyl Essentials
    3. Credits
    4. About the Author
    5. Acknowledgements
    6. About the Reviewers
    7. www.PacktPub.com
      1. Support files, eBooks, discount offers, and more
        1. Why subscribe?
        2. Free access for Packt account holders
    8. Preface
      1. What this book covers
      2. What you need for this book
      3. Who this book is for
      4. Conventions
      5. Reader feedback
      6. Customer support
        1. Downloading the example code
        2. Downloading the color images of this book
        3. Errata
        4. Piracy
        5. Questions
    9. 1. Exploring the Stencyl Toolset and Game Engine
      1. Downloading and installing Stencyl
      2. Creating an account and signing in
      3. Exploring Stencyl – screens and windows
        1. The Welcome Center
          1. Drop-down menus
          2. The toolbar
          3. The Welcome Center tab
        2. The Dashboard
          1. Scene Designer
          2. The Palette
          3. The Log Viewer
      4. Summary
    10. 2. Starting the Game Project
      1. Mudslide Cowboy
        1. The fictional element
        2. The game rules
        3. Target platforms
        4. The control system
          1. Adaptive cursor
      2. The project files
      3. Creating the game project
      4. Summary
    11. 3. Backgrounds and Tilesets
      1. Backgrounds and foregrounds
        1. Adding our first background
        2. Three more backgrounds
      2. Our first tileset
      3. Summary
    12. 4. Building Levels Using Scenes
      1. Creating our first level
        1. Implementing foregrounds and backgrounds
      2. Adding tiles to our level
        1. Exercise
      3. Summary
    13. 5. Actor Types and Instances
      1. What are actors?
      2. Adding our first actor
        1. Importing our first animation
          1. Collision shapes
          2. Importing the rock Actor Type
      3. Summary
    14. 6. Writing Simple Behaviors
      1. The player handler
        1. Creating a new actor behavior
        2. Creating attributes
        3. Custom events
        4. Testing and debugging
        5. Adding the balloon
        6. Configuring prefab behaviors
          1. Modifying prefab behaviors
          2. Testing the changes
      2. Summary
    15. 7. Complex Behaviors and Code
      1. Adding player interaction
        1. Initializing the variables
        2. Handling player clicks
        3. Our first custom block
        4. Handling directional clicks
        5. The when mouse is released event
        6. Switching animations
      2. Summary
    16. 8. Adding Sound FX and Music
      1. Supporting both MP3 and OGG formats
      2. Importing audio files into Stencyl
      3. Sound file designation in Stencyl
      4. Playing sound FX and music in Stencyl
      5. Summary
    17. 9. Adding HUD Elements
      1. The dynamic cursor
      2. Summary
    18. 10. Adding Menus and Buttons
      1. Adding the scene and background
      2. Adding the buttons
      3. Programming the button
      4. Summary
    19. 11. Scoring and Game Rules
      1. Collecting coins
      2. Coin collisions and physics settings
      3. Importing the font
      4. Coin collection
      5. Rendering text to the screen
      6. Multiple tile layers
      7. Summary
    20. 12. Publishing and Monetization
      1. Mobile publishing and monetization
        1. Monetization with ads
          1. Ad extensions
        2. Store certificates
      2. Summary
    21. Index