Mastering Unity 2D Game Development - Second Edition

Master everything you need to build a 2D game using Unity 5 by developing a complete RPG game framework!

Mastering Unity 2D Game Development - Second Edition

Dr. Ashley Godbold, Simon Jackson

2 customer reviews
Master everything you need to build a 2D game using Unity 5 by developing a complete RPG game framework!
Mapt Subscription
FREE
$29.99/m after trial
eBook
$30.80
RRP $43.99
Save 29%
Print + eBook
$54.99
RRP $54.99
What do I get with a Mapt Pro subscription?
  • Unlimited access to all Packt’s 5,000+ eBooks and Videos
  • Early Access content, Progress Tracking, and Assessments
  • 1 Free eBook or Video to download and keep every month after trial
What do I get with an eBook?
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with Print & eBook?
  • Get a paperback copy of the book delivered to you
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with a Video?
  • Download this Video course in MP4 format
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
$0.00
$30.80
$54.99
$29.99p/m after trial
RRP $43.99
RRP $54.99
Subscription
eBook
Print + eBook
Start 30 Day Trial
Subscribe and access every Packt eBook & Video.
 
  • 5,000+ eBooks & Videos
  • 50+ New titles a month
  • 1 Free eBook/Video to keep every month
Start Free Trial
 
Preview in Mapt

Book Details

ISBN 139781786463456
Paperback506 pages

Book Description

The Unity engine has revolutionized the gaming industry, by making it easier than ever for indie game developers to create quality games on a budget. Hobbyists and students can use this powerful engine to build 2D and 3D games, to play, distribute, and even sell for free!

This book will help you master the 2D features available in Unity 5, by walking you through the development of a 2D RPG framework. With fully explained and detailed C# scripts, this book will show you how to create and program animations, a NPC conversation system, an inventory system, random RPG map battles, and full game menus. After your core game is complete, you'll learn how to add finishing touches like sound and music, monetization strategies, and splash screens. You’ll then be guided through the process of publishing and sharing your game on multiple platforms. After completing this book, you will have the necessary knowledge to develop, build, and deploy 2D games of any genre!

Table of Contents

Chapter 1: Overview
Getting assets
Unity's 2D features
Changes to Unity 5
Summary
Chapter 2: Building Your Project and Character
Project overview and structure
Creating the project
Creating a scene
Sprite system
GameObjects and components
Classes
Planning behaviors
Coding with components
Going further
Summary
Chapter 3: Getting Animated
Fundamentals of sprite animation
Animating the main character
Going further
Summary
Chapter 4: The Town View
Backgrounds and layers
Building the scene
Working with the camera
Transitioning and bounds
Going further
Summary
Chapter 5: Working with Unitys UI System
UI Canvas
UI Text and Images
UI Layout and Rect Transform
UI Buttons
Going further
Summary
Chapter 6: NPCs and Interactions
Considering an RPG
Advanced programming techniques
Communicating between GameObjects
Background tasks and coroutines
Serialization and scripting
Adding NPCs and a conversation system to our game
Going further
Summary
Chapter 7: The World Map
The larger view
Creating our game's map
Leaving town
Returning to town
Going further
Summary
Chapter 8: Encountering Enemies and Running Away
Event systems
Exploring randomness
Basic Artificial Intelligence
State machines
Sensors
Setting up your battle scene
Going further
Summary
Chapter 9: Getting Ready to Fight
Setting up our battle state manager
Efficient RPG UI overlays
Bring on the GUI
Going further
Summary
Chapter 10: The Battle Begins
Designing an interesting battle system
Preparing to attack a single enemy
Beefing up the enemy AI
Selecting an attack
Selecting a target
Attack! Attack!
Using particle effects to represent an attack
Finishing up the battle
Going further
Summary
Chapter 11: Shopping for Items
Why do we shop?
The power of an item
Building your shop
Laying out your inventory
Creating a shop and inventory
Going further
Summary
Chapter 12: Sound and Music
Choosing the appropriate sound and music
Where to get sound and music for your game
Audio listeners and audio sources
Adding background music
Adding sound effects
Muting/unmuting audio
Going further
Summary
Chapter 13: Putting a Bow on It
Building in-game menu structures
Finishing our splash screen
Building our start screen
Extending the editor
Working with settings
Going further
Summary
Chapter 14: Deployment and Beyond
Handling platform differences
Pushing code from Unity
Building your assets
Packaging gotchas
Distributing to mobile
Social network integration
Monetization
Going further
Summary

What You Will Learn

  • Create a 2D game in Unity 5 by developing a complete retro 2D RPG framework.
  • Effectively manipulate and utilize 2D sprites.
  • Create 2D sprite animations and trigger them effectively with code.
  • Write beginning to advanced-level C# code using MonoDevelop.
  • Implement the new UI system effectively and beautifully.
  • Use state machines to trigger events within your game.

Authors

Table of Contents

Chapter 1: Overview
Getting assets
Unity's 2D features
Changes to Unity 5
Summary
Chapter 2: Building Your Project and Character
Project overview and structure
Creating the project
Creating a scene
Sprite system
GameObjects and components
Classes
Planning behaviors
Coding with components
Going further
Summary
Chapter 3: Getting Animated
Fundamentals of sprite animation
Animating the main character
Going further
Summary
Chapter 4: The Town View
Backgrounds and layers
Building the scene
Working with the camera
Transitioning and bounds
Going further
Summary
Chapter 5: Working with Unitys UI System
UI Canvas
UI Text and Images
UI Layout and Rect Transform
UI Buttons
Going further
Summary
Chapter 6: NPCs and Interactions
Considering an RPG
Advanced programming techniques
Communicating between GameObjects
Background tasks and coroutines
Serialization and scripting
Adding NPCs and a conversation system to our game
Going further
Summary
Chapter 7: The World Map
The larger view
Creating our game's map
Leaving town
Returning to town
Going further
Summary
Chapter 8: Encountering Enemies and Running Away
Event systems
Exploring randomness
Basic Artificial Intelligence
State machines
Sensors
Setting up your battle scene
Going further
Summary
Chapter 9: Getting Ready to Fight
Setting up our battle state manager
Efficient RPG UI overlays
Bring on the GUI
Going further
Summary
Chapter 10: The Battle Begins
Designing an interesting battle system
Preparing to attack a single enemy
Beefing up the enemy AI
Selecting an attack
Selecting a target
Attack! Attack!
Using particle effects to represent an attack
Finishing up the battle
Going further
Summary
Chapter 11: Shopping for Items
Why do we shop?
The power of an item
Building your shop
Laying out your inventory
Creating a shop and inventory
Going further
Summary
Chapter 12: Sound and Music
Choosing the appropriate sound and music
Where to get sound and music for your game
Audio listeners and audio sources
Adding background music
Adding sound effects
Muting/unmuting audio
Going further
Summary
Chapter 13: Putting a Bow on It
Building in-game menu structures
Finishing our splash screen
Building our start screen
Extending the editor
Working with settings
Going further
Summary
Chapter 14: Deployment and Beyond
Handling platform differences
Pushing code from Unity
Building your assets
Packaging gotchas
Distributing to mobile
Social network integration
Monetization
Going further
Summary

Book Details

ISBN 139781786463456
Paperback506 pages
Read More
From 2 reviews

Read More Reviews

Recommended for You

Mastering Unity 2D Game Development Book Cover
Mastering Unity 2D Game Development
$ 32.99
$ 6.60
Procedural Content Generation for Unity Game Development Book Cover
Procedural Content Generation for Unity Game Development
$ 39.99
$ 28.00
Unity 5.x Cookbook Book Cover
Unity 5.x Cookbook
$ 43.99
$ 30.80
Unity AI Game Programming - Second Edition Book Cover
Unity AI Game Programming - Second Edition
$ 39.99
$ 28.00
Unity 5.x By Example Book Cover
Unity 5.x By Example
$ 39.99
$ 28.00
Learning Unity 2D Game Development by Example Book Cover
Learning Unity 2D Game Development by Example
$ 26.99
$ 18.90