Advertisement
Guest User

moeda

a guest
Nov 13th, 2019
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4.  
  5. public class MoedaScript : MonoBehaviour
  6. {
  7. public static int _totalMoedas = 0;
  8. void Start()
  9. {
  10.  
  11. _totalMoedas++;
  12. }
  13.  
  14. // Update is called once per frame
  15. void OnDestroy()
  16. {
  17. _totalMoedas++;
  18.  
  19. }
  20.  
  21. private void OnTriggerEnter(Collider other)
  22. {
  23. Debug.Log("Esbarrou!");
  24.  
  25.  
  26.  
  27. }
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement