UNITY TUTORIAL | PROJECT | SPACE SHOOTER |8. Boundary

UNITY TUTORIAL | PROJECT | SPACE SHOOTER |8. Boundary

2
Creating “Cube” as Boundary with Collider
3
positioning and scaling “Boundary” along with BackGround
4
Adding a Script for “Boundary”
512.png
Deleting any components of Mesh from “Boundary”

 

6
OnTriggerExit() | Destroy()

 

ezgif.com-video-to-gif

UNITY TUTORIAL | PROJECT | SPACE SHOOTER |5. Moving Player

UNITY TUTORIAL | PROJECT | SPACE SHOOTER |5. Moving Player2
Creating “PlayerControl” script

 

3
GetComponent() | Input.GetAxis
ezgif.com-video-to-gif (1)
moving “Player” but too slow
5
Creating public float “speed” variable
ezgif.com-video-to-gif (2)
adding more speed to “Player” but no boundary
4
putting value into public variable
7
Creating “Boundary” Class as Public | [System.Serializable] | limiting Player field using Mathf.Clamp
6
using “Serialized” Class to limit “Player”‘s field
ezgif.com-video-to-gif (3)
Bondary limited
9
Giving tilt to “Player” using RigidBody.Rotation
8
Public Tilt variable
ezgif.com-video-to-gif (4)
Giving tilt to “Player” but the wrong rotation
ezgif.com-video-to-gif (5)
Giving “Player” tilt in the right rotation