Advertisement
Guest User

TriggerShoot

a guest
Mar 28th, 2016
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.45 KB | None | 0 0
  1. using UnityEngine;
  2. using System.Collections;
  3.  
  4. public class TriggerShoot : MonoBehaviour {
  5.  
  6.     public MoveStateBehaviour.State stateChange;
  7.     public static bool isMissed = false;
  8.  
  9.     public void DestroyThis(){
  10.         GameObject toDestroy = Sensor.containTarget;
  11.         Debug.Log("ToDestroy : "+toDestroy);
  12.         if(toDestroy != null){
  13.             isMissed = true;
  14.         }
  15.         Destroy(toDestroy);
  16.         isMissed = false;
  17.     }
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement