Advertisement
Gayngel

Untitled

Mar 19th, 2017
456
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. integer switch;
  2.  
  3.  
  4. default
  5. {
  6.  
  7.  listen(integer channel, string name, key id, string message)
  8.     {
  9.            flightDirection = (string) message;
  10.          
  11.            
  12.             if (message == "up")
  13.  
  14.             {    
  15.                 switch = TRUE;  
  16.                 llSetTimerEvent(0.0);  
  17.                 llSetTimerEvent(0.02);              
  18.                
  19.  
  20.              }
  21.                
  22.             else if(message == "down")
  23.             {    
  24.                 switch = FALSE;  
  25.                 llSetTimerEvent(0.0);  
  26.                 llSetTimerEvent(0.02);            
  27.             }
  28.         }
  29.                
  30.                  timer()
  31.         {        
  32.  
  33.             if(switch == TRUE)  
  34.              llPushObject(llGetOwner(), <0,0,force>, ZERO_VECTOR, TRUE);
  35.  
  36.              else if(switch == FALSE)
  37.              llPushObject(llGetOwner(), <0,0,-force>, ZERO_VECTOR, TRUE);
  38.         }
  39.  
  40. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement