Intro to Airplane Physics in Unity 3D - 2017 & 2018
4.7 (403 ratings)
Course Ratings are calculated from individual students’ ratings and a variety of other signals, like age of rating and reliability, to ensure that they reflect course quality fairly and accurately.
2,375 students enrolled

Intro to Airplane Physics in Unity 3D - 2017 & 2018

Learn how to build your very own Custom Airplane Physics with Unity & C#
4.7 (403 ratings)
Course Ratings are calculated from individual students’ ratings and a variety of other signals, like age of rating and reliability, to ensure that they reflect course quality fairly and accurately.
2,374 students enrolled
Created by Indie - Pixel
Last updated 12/2019
English
English [Auto-generated]
Current price: $69.99 Original price: $99.99 Discount: 30% off
5 hours left at this price!
30-Day Money-Back Guarantee
This course includes
  • 20.5 hours on-demand video
  • 11 downloadable resources
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion
Training 5 or more people?

Get your team access to 4,000+ top Udemy courses anytime, anywhere.

Try Udemy for Business
What you'll learn
  • You will be able to create your own Airplane Physics for your own Flying Games in Unity 3D
  • You will have the confidence to work with Rigidbodies in Unity
  • You will understand the Basics of Weight and Force to produce belivable Aircraft Physics
  • You will understand how to put together a Modular set of scripts to make your Aircraft easy to manage in Unity
  • You will learn how to take advantage of C# inheritance to create Re-Usable code
  • You will Learn how to set up the UI for an Airplane and how to make them functional
Course content
Expand all 149 lectures 20:17:40
+ Introduction
2 lectures 07:03

Lets take a look at the final product that we will get when we finish this entire course!

Preview 02:38
+ Getting Set Up!
5 lectures 47:14

Lets get our Project setup and learn how to use a handy little tool that is included with te Indie-Pixel framework.

Preview 06:43

In order for us to test out our Airplane physics, we need a scene setup to test within.  In this video we are going to set up a scene that is for testing only, but will give us a clean environment to prove our flight physics.

Prepping the Development Scene
05:12

In order to begin our Airplane Physics setup, we need to make sure our GameObject structure is in place and our Airplane model is ready to go.

Prepping the Airplane - Part 1
09:17

With our Airplane model all setup, our prefab in place, and our GameObject structure completed, lets take a look at setting up the Colliders for our Airplane. 

Prepping the Airplane - Part 2
13:58

I always like to take a moment, before I dive into a new Controller and really think about the design of the code.  I rarely just start coding.  So lets walk through the process I use and hopefully itll inspire you and give you some ideas about how to go about designing your code.

Designing the Code
12:04
+ Building the Airplane Inputs
11 lectures 01:36:13

Lets discuss what we are going to do in this section and the different items we will cover with regards to user input.

Introduction
02:21

I wanted to show everyone how to install the completed Airplane Physics unity package, that can be downloaded in Lecture 8, into Unity 2018.3.1.

Installing the Completed Project
09:19

Now that we have a game plan in place for our Inputs, lets get our scripts stubbed in and ready for coding.

Stubbing in the Scripts
09:09

Namespaces and Variables are very important to our coding.  so lets take some time to learn how to use them in our Airplane system.

Keyboard Input - Variables & Namespaces
08:38

Properties give us a certain amount of protection from outside scripts accessing data.  So lets see how we can use them to pass the input data around.

Keyboard Input - C# Properties
06:23

Virtual methods, in C# are super powerful in that they let you override functional or extend functionality without having to re-write a bunch of code.  Lets take a look at how to use them in our Airplane system!

Keyboard Input - C# Virtual Methods
11:43

Unity's Input Manager is our one stop shop for adding custom input mappings.  This is especially important when supporting game controllers.  So lets take a look at working with the Input Manager.  

Keyboard Input - Using the Input Manager
16:48

I love creating Editors inside of Unity.  Not only are they fun to make but they are extremely powerful to end users.  Giving them a visual way to interact with the code you created.  It saves production time and repetitive tasks for your production team.  Lets walk through creating a basic inspector editor for our inputs. This will give us a visual display of what our input values look like.

Keyboard Input - Creating an Inspector Editor
13:47

Now lets take a look at how we can use our Virtual method in our base input class and override its functionality to support the xbox controls.

Xbox Input - Virtual Methods
06:50

Now that we have our Xbox controller input going, lets update the Inspector editor to support this new class.

Xbox Input - Updating the Editor
02:34

In order to get our Xbox controls completed, lets add a couple more inputs to our Input Manager in Unity.

Xbox Input - Setting the Input Manager
08:41
+ Creating the Airplane Controller Script
6 lectures 54:34

Ok, lets talk about what we are going to learn in this section.

Introduction
03:01

Lets get our scripts stubbed in and understand why we are setting up our scripts the way we are.

Stubbing in the Scripts & Code Design
06:39

One of the first glimpses at creating a re-usable system is going to be creating the Base Rigidbody Controller.  This will be a script you can use for just about any Rigidbody Controller inside of Unity.

Creating a Base Rigidbody Controller Class
11:24

With our core scripts in place lets continue and create the Airplane controller script.  This will begin to reveal the basics of inheritance in C#.

Creating the Airplane Controller Class
09:51

Weight plays a huge factor in Physics.  In order to move a Rigidbody we need to apply a force that counteracts the objects weight.  So knowing the weight of our airplane will help us create a more accurate Physics System.

Airplane Weight Calculation
09:07

I love to make my systems easy to use for other people, especially in a production environment.  In this lecture we are going to make it so the Airplane setup is simply created from a single menu option.

Creating a Menu Option for Automatic Setup
14:32
+ Building the Airplane Engine Component
6 lectures 56:59

The Airplane Engine is where everything begins in the Physics. In order for a plane to maintain flight it needs speed.  In order to create speed we need power created by an engine and propeller.  Lets quickly go over the topics we are going to cover in this section.

Introduction
01:23

Before we do a deeper dive into creating our engine script, lets learn how to apply forces to a rigidbody.

Applying Forces
16:54

Lets get our scripts stubbed in for our Airplane Engine system.

Stub in the Scripts
11:01

With everything in place lets hook up the meat of the engine code.

Hook up the Engine
12:45

In order for our Airplane to roll on the ground we will need to manipulate the wheel colliders, in Unity, directly.

Handling the Wheels
06:16

A great way to allow designers to quickly and easily test out different physics setups, we can create Animation Curves, instead of providing just float values to the Inspector.

Calculating Force with Animation Curves
08:40
+ Animating the Propeller
6 lectures 45:00

OK, so lets go over what we are going to learn in this section.

Introduction
02:00

Lets get our Propeller scripts all stubbed in and ready to go for coding.

Stubbing in the Script
06:03

In order to rotate our Propeller, we need to know how fast the engine is spinning.  Lets take a look at how to convert RPM's into Degrees Per Second.

Calculating Degrees Per Second from RPM's
09:46

Lets have a little fun and learn how to set up the graphics for our Propellers.

Propeller Graphics
13:18

A cool old school trick is to blend different blurred propellers based off of the rotation speed.  This gives the propellers a way more realistic look when in flight.

Blending the Propellers
06:54

Its always a good idea to learn how to manipulate materials inside of Unity.  It opens a whole new world of FX and tricks that save you time and get the job done.  lets learn how to swap textures in a material.

Material Swapping
06:59
+ Flight Characteristics
14 lectures 02:10:52

At the heart of the Airplane system, we have our Flight Characteristics.  Lets take a look at what we are going to learn in this section.

Introduction
03:15

As usual, lets get our scripts stubbed in before coding so we know everything is hook up correctly, from a high level.

Stubbing in the Script
11:07

In order for us to be able to calculate lift, drag and many other components of flight physics, we need to know how fast we are going.  So lets take a look at calculating our forward speed.

Calculating Forward Speed
07:44

Now that we are on our way to creating a full Physics system, lets take a moment to update our Throttle to a sticky throttle so it mimics more of how a real airplane throttle works.

Sticky Throttle
10:37

Lift is the first and one of the most important Forces that acts upon a plane.  So lets take a couple minutes to understand how lift is created in the real world.

Theory of Lift
04:51

Now that we have a better understanding of how lift is generated in the real world, lets take a look at how to create it in Unity using Rigidbodies and forces.

Creating Lift
09:52

Once again we will employ an Animation Curve property to control our lift power over the amount of speed we are generating from the engine. This makes it easy and visual for Designers to set up new flight models.

Refining Lift with Curves
14:24

Drag is a very important force when working with Rigidbodies and Physics in Unity.  This force keeps things relative,ly stable and controllable.  Without it we would simply spin out of control or float off into space.  Lets take a look at how drag is integral to our Airplane Physics.

Drag
09:58

When flying a plane your angle of attack is very important to the performance of your airplane.  The steeper your angle of attack is the less lift your produce.  Menaing you cant just pull the plane up 90 degrees or it would fall into a spin and possibly end up in the ground.  So lets take a look at how we can further add some realism to our flight physics by incorporating the angle of attack.

Angle of Attack
08:16

When working with rigidbodies in Unity,  we almost always want to give more direct control over the final simulation of the physics.  Unity's Rigidbody gives us ways in which we can interact with it almost like directly working with the Transform class.  So lets take a look at that.

Handling the Rigidbody
12:01

Pitch is how we get an airplane to go up and down.  Very important in flying a plane.  So lets get our Pitch control in place.

Pitch
12:17

Roll is also very important to flight as it is one of the main ways we get the airplane to turn. Lets get it hooked up in our system.

Roll
07:49

The rudder of the plane creates a force called Yaw.  It allows us to make small or large direction changes but is used very sparingly when flying a plane.  So lets get it hooked up to our system.

Yaw
06:24

To close out this section we will make the plane turn slightly when we roll.  This will add the final level of realism to our plane that really makes it feel like you are flying a real world airplane.

Banking
12:17
+ Building the Airplane Camera
4 lectures 31:48

One of the more important components to a controller system, inside of Unity, is the camera.  This is how the player views the world and controls the vehicle.  So lets talk about what we are going to do for our Airplane camera.

Introduction
01:52

Lets get our Camera scripts stubbed in and ready for the code.

Stub in Scripts
04:32

To begin our camera system, lets take a look at how to create a basic but useful follow camera.

Preview 14:50

when I was first developing the camera for the Airplane, I noticed that I really needed to have the camera adjust its height when it got closer to the ground.  Mostly when the Airplane was on the ground.  So lets take a look at how to do that.

Ground Height
10:34
+ Animating the Control Surfaces
5 lectures 33:52

The control Surfaces of an Airplane determine how the airplane navigates through the air.  Since we have the physics working, lets get our control surfaces working so it looks like the graphical representation of a control surface is actually manipulating the Airplane.

Introduction
01:53

As usual, lets get our Script stubbed in so we know that it is working with the entire system.

Stub in the Script
09:43

With our Scripts stubbed in, lets put in the meat of the Control Surface Script.

Coding the Control Surface Script
13:52

Now that we have our script all coded up, lets hook up the rudder and test out the scripts modularity!

Hooking up the Rudder
02:56

Lets get the ailerons hooked up now and finish out this section! :-)

Preview 05:28
+ Completing the Wheels
4 lectures 28:09

Lets quickly go over the items we are going to cover in this Wheel section.

Introduction
01:48

To add some more realism and control over our Airplane, lets rol and position the wheels according to speed and the Suspension distance.

Rolling and Positiong the Wheels
08:44

If we didn't have brakes we would be in real trouble!  So lets learn how to add braking to our wheels.

Braking
08:58

Steering is also very important, in the sky and on the ground.  Lets learn how to steer our airplane on the ground using the wheel collider.

Steering
08:39
Requirements
  • Basic understanding of Unity 3D and how to build simple games with it.
  • Beginning Understanding of C# and the Unity API.
  • Basic Knowledge of using Rigidbodies within Unity.
  • Basic Knowledge of using Unity 3D's UI system
  • Basic Knowledge of Photoshop to Create UI elements.
Description

Have you ever wanted to build your own Airplane Physics using the Rigidbody component in Unity 3D?  Do you want to know more about setting up modular code to make your workflows faster and more re-usable?  If so, this course is for you!  Throughout the contents of this course you will learn how to create a fully functional Airplane Physics model.  

In the course you will learn to build the full physics flight model, how to animate the propeller, how to setup inputs, how to build a dynamic airplane camera, how to animate all the control surfaces of the plane, and more!

By the end of this course you will have your very own Flight Physics System that you can use for your own flying games.

By Purchasing the Course you get the Following:

  • The Complete Airplane Physics Code

  • Two Airplane Models, the Indie-Pixel Plane and the F4U Corsair

  • Complete UI kit to create the Instrument UI for the Airplane



Who this course is for:
  • Anyone interested in creating their own Aircraft physics for games.
  • Someone who is looking to take their Unity skills up a notch and begin to utilize modular code and setups.
  • A Beginner Unity user who wants to learn more about how to create vehicles, specfically aircraft, with Unity's Rigidbodies.
  • A unity user who would like to learn how to create more advanced UI for vehicles