Advertisement
GamerRO

Untitled

Aug 17th, 2017
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. using System.Collections;
  2. using UnityEngine;
  3.  
  4. public class deleteme : MonoBehaviour
  5. {
  6. void Start()
  7. {
  8. StartCoroutine(Main());
  9. }
  10.  
  11. public void Stop()
  12. {
  13. StopCoroutine(Main());
  14. Debug.Log(">>>>>>> STOP!");
  15. }
  16.  
  17. IEnumerator Main()
  18. {
  19. yield return null;
  20.  
  21. while (true)
  22. {
  23. Debug.Log("x");
  24. yield return null;
  25. }
  26. }
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement