Training Center

Unity Scripting 2D Space Shooter

Unity Scripting 2D Space Shooter

Create a top-down space shooter from scratch! You'll make a fully-functioning arcade game and learn about collision, player movement, instantiation, health and score systems, dynamic level creation and enemy spawning, creating weapon power-ups, using particle systems and sound effects, automating enemy movement, and creating a homing missile.

A quick playthrough of the space shooter game we're going to create in this module. We'll also get you set up with custom assets to use during its creation.

Tagged under

Additional Info

  • Runtime 03 min 53 sec
  • Software Unity
Login to download project files

Learn how to create a scrolling background texture to simulate movement in your game. We'll also use 2D parallax to simulate depth among the stars.

Additional Info

  • Runtime 11 min 35 sec
  • Software Unity

We create a player ship object and tie that ship's movement to player input. We also limit the movement to two dimensions and keep the ship within the confines of the visible screen area.

Additional Info

  • Runtime 12 min 06 sec
  • Software Unity

We create a laser for the player to fire.

Tagged under

Additional Info

  • Runtime 14 min 29 sec
  • Software Unity

We create a static enemy to oppose the player. We also set up collision detection so we can destroy it if a player hits it with a laser.

Additional Info

  • Runtime 08 min 28 sec
  • Software Unity

A successful enemy hit is so much more satisfying with some pyrotechnics. We add a sound effect and one-shot explosion particle effect when the enemy is hit.

Additional Info

  • Runtime 07 min 42 sec
  • Software Unity

We create a self-propelled laser for the enemy to fire. We also tell the enemy to fire the laser on its own at regular intervals.

Tagged under

Additional Info

  • Runtime 09 min 44 sec
  • Software Unity

Set up collision detection on the player ship and destroy it if hit by an enemy laser. We also add explosion particle effects and sound.

Additional Info

  • Runtime 05 min 02 sec
  • Software Unity

This game would be no fun if the enemy ship simply hovered in one spot. We create a basic movement pattern to evade player lasers.

Additional Info

  • Runtime 07 min 15 sec
  • Software Unity

We create a power-up object for pickup by the player and set up collision detection for it. We also create a function to handle the power-up in the player's Fire script.

Additional Info

  • Runtime 07 min 02 sec
  • Software Unity

We implement the laser power up in this chapter, letting the player shoot more lasers at varying rotations after picking up the power-up object.

Tagged under

Additional Info

  • Runtime 07 min 09 sec
  • Software Unity

Here we let the player power-up either one or two levels and instantiate more or less lasers based on the current power-up level. We also build in a cooldown period to reset the power-up level.

Tagged under

Additional Info

  • Runtime 07 min 46 sec
  • Software Unity

Chapter List

Questions? ¿Preguntas? 有问题吗? Domande? Вопросы? 質問はありますか? सवाल? الأسئلة؟
This email address is being protected from spambots. You need JavaScript enabled to view it.

About design3

design3 is THE game production web portal. Whether you’re an industry veteran keeping up with new tools and trends or an aspiring developer searching for professional training, expert advice and career tips – design3.com is where you need to be.

Sign-up for our newsletter!

:

Copyright © 2006 - 2012 design3. All rights reserved.

Sign In or Become a member

Facebook user?

You can use your Facebook account to sign into our site.

Log in with Facebook

LOG IN