Learning C# by Developing Games with Unity 2021: Kickstart your C# programming and Unity journey by building 3D games from scratch, 6th Edition
- Length: 487 pages
- Edition: 6
- Language: English
- Publisher: Packt Publishing
- Publication Date: 2021-11-09
- ISBN-10: 1801813949
- ISBN-13: 9781801813945
- Sales Rank: #386466 (See Top 100 Books)
Learn C# programming from scratch using Unity as a fun and accessible entry point with this updated edition of the bestselling series
Key Features
- Learn C# programming basics, terminology, and coding best practices
- Become confident with Unity fundamentals and features in line with Unity 2021
- Apply your C# knowledge in practice and build a working first-person shooter game prototype in Unity
Book Description
The Learning C# by Developing Games with Unity series has established itself as a popular choice for getting up to speed with C#, a powerful and versatile programming language with a wide array of applications in various domains. This bestselling franchise presents a clear path for learning C# programming from the ground up through the world of Unity game development.
This sixth edition has been updated to introduce modern C# features with Unity 2021, including the new Unity Input Manager and animating with code. A new chapter has also been added that covers reading and writing binary data from files, which will help you become proficient in handling errors and asynchronous operations.
The book acquaints you with the core concepts of programming in C#, including variables, classes, and object-oriented programming. You will explore the fundamentals of Unity game development including game design, lighting basics, player movement, camera controls, and collisions. You will write C# scripts for simple game mechanics, perform procedural programming, and add complexity to your games by introducing smart enemies and damage-causing projectiles.
By the end of the book, you will have developed the skills to become proficient in C# programming and built a playable game prototype with the Unity game engine.
What you will learn
- Follow simple steps and examples to create and implement C# scripts in Unity
- Develop a 3D mindset to build games that come to life
- Create basic game mechanics such as player controllers and shooting projectiles using C#
- Divide your code into pluggable building blocks using interfaces, abstract classes, and class extensions
- 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
- Explore the basics of AI for games and implement them to control enemy behavior
Who This Book Is For
If you’re a developer, programmer, hobbyist, or anyone who wants to get started with C# programming in a fun and engaging manner, this book is for you. Prospective Unity game developers will also find this title useful. No prior experience in programming or Unity required.
Table of Contents
- 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
- Introducing Stacks, Queues, and HashSets
- Saving, Loading, and Serializing Data
- Exploring Generics, Delegates, and Beyond
- The Journey Continues