Godot Engine Game Development Projects
Build five cross-platform 2D and 3D games with Godot 3.0
Chris Bradfield
BIRMINGHAM - MUMBAI
Godot Engine Game Development Projects
Copyright 2018 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing or its dealers and distributors, will be held liable for any damages caused or alleged to have been caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
Acquisition Editor: Nigel Fernandes
Content Development Editor: Jason Pereira
Technical Editor: Rutuja Vaze
Copy Editor: Safis Editing
Project Coordinator: Sheejal Shah
Proofreader: Safis Editing
Indexer: Mariammal Chettiyar
Graphics: Disha Haria
Production Coordinator: Shraddha Falebhai
First published: June 2018
Production reference: 1270618
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham
B3 2PB, UK.
ISBN 978-1-78883-150-5
www.packtpub.com
To my son, Damian, and my daughter, Nadia, for being a constant source of love and pride.
To Priya for being a wonderful wife and mother.
mapt.io
Mapt is an online digital library that gives you full access to over 5,000 books and videos, as well as industry leading tools to help you plan your personal development and advance your career. For more information, please visit our website.
Why subscribe?
Spend less time learning and more time coding with practical eBooks and Videos from over 4,000 industry professionals
Improve your learning with Skill Plans built especially for you
Get a free eBook or video every month
Mapt is fully searchable
Copy and paste, print, and bookmark content
PacktPub.com
Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at www.PacktPub.com and as a print book customer, you are entitled to a discount on the eBook copy. Get in touch with us at service@packtpub.com for more details.
At www.PacktPub.com , you can also read a collection of free technical articles, sign up for a range of free newsletters, and receive exclusive discounts and offers on Packt books and eBooks.
Foreword
In December 2014, Godot Engine 1.0 was released. With this first public release, the feature-packed, free, and open source project delivered on its promise of a cross-platform, easy-to-use, and powerful game creation tool.
I fell in love with Godot's high-level features and its permissive license, so I jumped right in, with no prior game development experience. I felt a bit lost when I first opened the editor. I moved on to the online documentation and started reading the well-written, step-by-step introduction. It covered basic concepts, such as scenes and nodes and the GDScript programming language, and it showed how to create a Pong clone, and that was basically it, at that time. There were some more tutorials on advanced features, but there was a gap between them and the first guide. As a complete beginner, I was stuck with the following question: how do I make my first game? Yet, I kept exploring, and with the help of the Godot community, I could eventually build a simple 2D game with a local multiplayer. What a feeling to see your first game on the screen!
Fast-forward to 3 years from then, Godot has grown a lot as a project, a community, and an engine. Godot 3.0 was released in January 2018 after 18 months of work. It brought this free, community-driven project to the level of its proprietary counterparts for 2D and 3D game development. The beginner game developer that I was became a project manager, helping to organize and focus the work of hundreds of contributors revolving around the engine. Working together with people from all around the world improved all areas of the project: engine features, usability, localization, and, of course, documentation.
Thanks to many dedicated contributors, Godot's documentation became one of the most accessible technical resources that I have seen in free and open source projects. This is in great part thanks to Chris Bradfield, the author of this book, who spent countless hours writing new material and reviewing contributions to ensure their accuracy and quality of writing.
With this book, Chris goes one step further and provides a thorough answer to that question (how do I make my first game?), shared by many Godot beginners. Indeed, he goes beyond that, as Godot Engine Game Development Projects will lead you through the creation of five full-featured gamesfour in 2D and one in 3D. Each game introduces new features and concepts of Godot so that you can learn how and when to use them in your own creations. Advanced users with experience in other game development tools (or even Godot itself) will learn how to use Godot's unique architecture and features to write better, more maintainable code through Chris' showcase of best practices.
From setting up Godot for the first time on your computer to publishing your own games to a wide range of platforms, Chris runs you through all the steps in a concise yet thorough way. After the first lesson, you should already be able to see how straightforward and accessible game development can be with a tool such as Godot, even if you had no prior experience in game creation. You will also feel a great sense of accomplishment seeing your own creation playing on your computer or smartphone, with the power to implement new gameplay elements with just a few lines of code.
I wish you a lot of fun on your game development journey, and a warm welcome to the Godot community.
Rmi Verschelde
Godot Engine Project Manager
Contributors
About the author
Chris Bradfield has been working in the internet technology space for more than 25 years. He has worked in the online gaming space for a number of successful MMOs and social gaming publishers in South Korea and the United States. Throughout his game industry career, he has served as a game designer, developer, product manager, and business development executive.
In 2012, he discovered his love for teaching and founded KidsCanCode to provide programming instruction and curriculum to middle and high school students. He is also a member of the Godot Engine documentation team and works to provide learning resources for game development students around the world.
Next page