Guest User

Untitled

a guest
Feb 12th, 2017
231
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4.  
  5. public class Projectile : MonoBehaviour {
  6.  
  7.     void OnCollisionEnter(Collision collision)
  8.     {
  9.         if (collision.gameObject.tag == "Block")
  10.         {
  11.             GameObject.Destroy(collision.gameObject);
  12.             GameObject.Destroy(gameObject);
  13.         }
  14.     }
  15. }
RAW Paste Data