Supporting our Community:
We’re making Learn Premium available to all users in perpetuity.
Start Learning.

Creating Objects

Tutorial
Beginner
30 Mins
Overview
Details
Your progress
Summary
You will create a new GameObject  that allows the player to destroy obstacles
Tutorial Outcome
By the end of this tutorial, you will be able to
  • Add a (trigger) Capsule Collider 2D to keep track of when objects touch or intersect
  • Add a Bullet attribute script to keep track of points
  • Create a prefab
  • Create an empty GameObject
  • Add the Object Shooter script
  • Insert a Prefab as a Prefab to Spawn for the Object Shooter script  
Key concepts:
  • Capsule Collider 2D
  • Trigger Colliders
  • Bullet Attribute script
  • Prefab
  • Object Shooter script
Challenge Ideas:
  • What would happen if the laser was not turned into a Prefab? Would the lasers still work in the same way? Why or not?
  • What would happen if the player could gain points for destroying asteroids? How would it change the way the game ends?
Select your Unity version
Last updated: February 13, 2020
2019.3
2019.2
2019.1
2018.4
2018.3
2018.2
2018.1
2017.4
Topics we'll cover
Industry
Language
English
Tutorial
Creating Objects
0
Creating Objects