Advertisement
MadScience2728

Melee car

Jan 11th, 2014
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.46 KB | None | 0 0
  1. while true do
  2.  
  3.   event, param1, param2 = os.pullEvent()
  4.  
  5.   if event == "rednet_message" then
  6.     local message = param2
  7.     if message == "You are authorised to proceed" then
  8.      
  9.       print ("Message Received")
  10.       print ("Going FORWARD")
  11.      
  12.       turtle.attack()
  13.       turtle.attack()
  14.       turtle.forward()
  15.       sleep(1)
  16.       turtle.attack()
  17.       turtle.attack()
  18.       turtle.forward()
  19.      
  20.     else
  21.    
  22.     end
  23.   end    
  24.  
  25. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement