Advertisement
Guest User

Untitled

a guest
Dec 19th, 2014
159
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function OnGUI () {
  2. if (gui_alert==true){
  3.     GUI.Label(gui_alert_position,"ok!!!!",hit_desc_style);
  4.     pause_gui();
  5.    
  6. }
  7.  
  8. }
  9.  
  10. function pause_gui() {
  11. Debug.Log("iniziata: "+gui_alert);
  12.     while (ttime<=5)
  13.     {
  14.     ttime=ttime+1;
  15.     Debug.Log("tick "+ttime);
  16.     yield WaitForSeconds(1);
  17.     }
  18.     ttime=0;
  19.     gui_alert=false;
  20. Debug.Log("Iniziata: "+gui_alert);
  21.  
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement