This is the code repository for Learning-C-by-Developing-Games-with-Unity-Seventh-Edition, published by Packt.
Get to grips with coding in C# and build simple 3D games in Unity 2022 from the ground up
It's the ability to write custom C# scripts for behaviors and game mechanics that really takes Unity the extra mile. That's where this book can help you as a new programmer!
Harrison Ferrone, in this seventh edition of the bestselling series, will take you through the building blocks of programming and the C# language from scratch while building a fun and playable game prototype in Unity.
This book will teach you the fundamentals of OOPs, basic concepts of C#, and Unity engine with lots of code samples, exercises and tips to go beyond the book with your work.
You will write C# scripts for simple game mechanics, perform procedural programming, and add complexity to your games by introducing intelligent enemies and damage-dealing projectiles. You will explore the fundamentals of Unity game development, including game design, lighting basics, player movement, camera controls, collisions, and more with every passing chapter.
- Understanding programming fundamentals by breaking them down into their basic parts.
- Comprehensive explanations with sample codes of object-oriented programming and how it applies to C#.
- Follow simple steps and examples to create and implement C# scripts in Unity.
- Divide your code into pluggable building blocks using interfaces, abstract classes, and class extensions.
- Grasp the basics of a game design document and then move on to blocking out your level geometry, adding lighting and a simple object animation.
- Create basic game mechanics such as player controllers and shooting projectiles using C#.
- Become familiar with stacks, queues, exceptions, error handling, and other core C# concepts.
- Learn how to handle text, XML, and JSON data to save and load your game data.
- Getting to Know Your Environment
- The Building Blocks of Programming
- Diving into Variables, Types, and Methods
- Control Flow and Collection Types
- Working with Classes, Structs, and OOP
- Getting Your Hands Dirty with Unity
- Movement, Camera Controls, and Collisions
- Scripting Game Mechanics
- Basic AI and Enemy Behavior
- Revisiting Types, Methods, and Classes
- Specialized Collection Types and LINQ
- Saving, Loading, and Serializing Data
- Exploring Generics, Delegates, and Beyond
- The Journey Continues
If you feel this book is for you, get your copy today!
The only thing you need to get the most from your upcoming C# and Unity adventure is a curious mind and a willingness to learn. Having said that, doing all the code exercises, Hero’s trials, and Quiz sections is a must if you hope to cement the knowledge you’re learning. Lastly, revisiting topics and entire chapters to refresh or solidify your understanding before moving on is always a good idea. There is no sense in building a house on an unstable foundation.
You’ll also need a current version of Unity installed on your computer—2022 or later is recommended. All code examples have been tested with Unity 2022.1 and should work with future versions without issues.
With the following software and hardware list you can run all code files present in the book.
Software/Hardware required |
---|
Unity 2022.1 or later |
Visual Studio 2019 or later |
C# 8.0 or later |
Before starting, check that your computer setup meets the Unity system requirements here.
You can get more engaged on the discord server for more latest updates and discussions in the community at https://packt.link/csharpwithunity
If you have already purchased a print or Kindle version of this book, you can get a DRM-free PDF version at no cost. Simply click on the link to claim your free PDF.
https://packt.link/free-ebook/9781837636877
We also provide a PDF file that has color images of the screenshots/diagrams used in this book at "Shortened packt link for GraphicBundle to be added here"
Harrison Ferrone was born in Chicago, Illinois and was raised all over. He’s worked at Microsoft, PricewaterhouseCoopers, and a handful of small start-ups, but most days you can find him creating instructional content for LinkedIn Learning and Pluralsight or tech editing for the Ray Wenderlich website.
He holds various fancy looking pieces of paper from the University of Colorado at Boulder and Columbia College Chicago. Despite being a proud alumnus, these are stored in a basement somewhere.
After a few years as a full-time iOS and Unity developer, he fell into a teaching career and never looked back. Throughout all of this, he’s bought many books, been owned by several cats, worked abroad, and continually wondered why Neuromancer isn’t on more course syllabi.