Advertisement
Guest User

New DestroyCollision

a guest
Apr 24th, 2014
483
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.24 KB | None | 0 0
  1. public class OnCollisionEnter : MonoBehaviour {
  2.  
  3. bool isDead = false;
  4.  
  5. void Update() {
  6. Debug.Log(isDead);
  7. }
  8.  
  9. OnCollisionEnter(Collision collision) {
  10. if (collision.gameObject.tag == "Player") {
  11. isDead = true;
  12. }
  13. }
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement