Mastering Unity 4 Scripting

Master Unity 4 gameplay scripting with this dynamic video course
0.0 (0 ratings)
Instead of using a simple lifetime average, Udemy calculates a
course's star rating by considering a number of different factors
such as the number of ratings, the age of ratings, and the
likelihood of fraudulent ratings.
29 students enrolled
82% off
Take This Course
  • Lectures 24
  • Length 1.5 hours
  • Skill Level All Levels
  • Languages English
  • Includes Lifetime access
    30 day money back guarantee!
    Available on iOS and Android
    Certificate of Completion
Wishlisted Wishlist

How taking a course works


Find online courses made by experts from around the world.


Take your courses with you and learn anywhere, anytime.


Learn and practice real-world skills and achieve your goals.

About This Course

Published 12/2014 English

Course Description

Mastering Unity 4 Scripting will show you the ropes for all the tools you'll need to make just about any game. Whether it's 2D or 3D, a first-person shooter or puzzle game, everything you need to know, will be covered in this course.

Mastering Unity 4 Scripting will teach you everything you need to know in order to make a wide variety of games. This course covers valuable topics such as audio, animation, saving and loading data, as well as scripting behavioral artificial intelligence - all of which will be discussed in a systematic and simple series of videos.

This course begins by demonstrating how to program audio, then delves into AI scripting, and then wraps up with how to save and load data.

Beginning with handling audio and sound effects, you then get into handling parallax backgrounds. After that, you will learn how to create an AI and character controller for a generic enemy. The course then wraps up by learning how to change levels and save/load data.

Mastering Unity 4 Scripting is a great course to learn all you need to get started with making your own games.

About the Author

Kyle D'Aoust has been programming for about 10 years. In 2004, at the age of 14, he taught himself the C++ language. By the end of high school, he had learned Visual Basic and JavaScript as well. In college, he majored in game production and specialized in the Unity engine using C#.

After graduating from college, Kyle started his career with gamifying software. He is currently working as a Serious Games Developer at Quicken Loans, creating games used as training material.

What are the requirements?

  • Anyone with a basic knowledge of programming and/or experience with Unity programming will find this course handy. Beginning with handling audio and sound effects, you will then get into handling parallax backgrounds. After that, you will learn how to create an AI and character controller for a generic enemy. The course then wraps up by teaching you how to change levels and save/load data - everything you need to get started with making your own games.

What am I going to get from this course?

  • Create a background audio controller
  • Incorporate directional and conditional sound effects
  • Make 2D and 3D parallax backgrounds
  • Create an enemy character controller
  • Script an enemy AI
  • Create level changing systems
  • Save and load data

Who is the target audience?

  • This video course is for anyone who has at least a basic knowledge of programming and/or experience with Unity programming. If you have programming experience but haven't used Unity before, or if you have Unity programming skills and are looking to expand them, then this course is perfect for you.

What you get with this course?

Not for you? No problem.
30 day money back guarantee.

Forever yours.
Lifetime access.

Learn on the go.
Desktop, iOS and Android.

Get rewarded.
Certificate of completion.


Section 1: Creating a Background Audio Controller

Keep things simple and straightforward.


Play a different song depending on which zone you enter. To do this you assign a song for each tagged object you collide with.


Play a song depending on which situation the player enters such as a battle or a storm. When this happens, play a song in accordance to the situation.

Section 2: Incorporating Sound Effects

Play a sound effect when the user presses a key or a button on the mouse.


Play a random sound effect to enhance a game's realism.


Adjust the volume according to how loud you want the background music to be compared to your sound effects.

Section 3: Making 2D Parallax Backgrounds

Figure out how to move the background texture by setting it to offset as time goes on.


Figure out how to move the background texture by moving it only when the player goes left or right.


Figure out how to spawn independent background objects randomly by spawning them at random time intervals.

Section 4: Making 3D Parallax Backgrounds

Figure out how to create a 2D sidescroller look to a 3D game by adjusting your level, camera, and character.


Think about moving in a 3D space with the camera locked on a single axis.


Jumping in a 3D parallax is essentially the same as in a non parallax

Section 5: Creating an Enemy Character Controller

Think of a way to handle different types of AI by creating states to order and cleanly run AI systems.


Figure out not just how to write the code to play animations, but control them as well by setting a speed variable and controlling the wrap mode.


Make the enemy character come to life by assigning the script we wrote.

Section 6: Creating Enemy AI

Figure out how to create a “lively” enemy by making it look at a target


Figure out how to make the enemy follow a path by using waypoints.


Implement some common behaviors to the AI

Section 7: Creating Level Changing Systems

Instead of changing levels with everything you collide with, select only a specific object to tag and use that object.


Manage level selection by creating GUI buttons to change levels.


Make use of the Random Range function to randomize what level is next.

Section 8: Creating an Item Carry-Over System

Figure out how to use your PlayerPrefs by giving them local variables.


Learn how to save your PlayerPrefs by assigning your local variables to them.


Figure out how to use your PlayerPrefs by loading them into your local variables.

Students Who Viewed This Course Also Viewed

  • Loading
  • Loading
  • Loading

Instructor Biography

Packt Publishing, Tech Knowledge in Motion

Packt has been committed to developer learning since 2004. A lot has changed in software since then - but Packt has remained responsive to these changes, continuing to look forward at the trends and tools defining the way we work and live. And how to put them to work.

With an extensive library of content - more than 4000 books and video courses -Packt's mission is to help developers stay relevant in a rapidly changing world. From new web frameworks and programming languages, to cutting edge data analytics, and DevOps, Packt takes software professionals in every field to what's important to them now.

From skills that will help you to develop and future proof your career to immediate solutions to every day tech challenges, Packt is a go-to resource to make you a better, smarter developer.

Packt Udemy courses continue this tradition, bringing you comprehensive yet concise video courses straight from the experts.

Ready to start learning?
Take This Course