SHARE
TWEET

Untitled

Spirit13300 May 27th, 2020 1,164 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. calc = 0
  2. while true do
  3.  
  4.   id,mess = rednet.receive()
  5.  
  6.   if (id ==43) and (mess == "demande")then
  7.      
  8.     rep = turtle.suck()
  9.     obj = turtle.getItemDetail(1)
  10.     while (rep == true) do
  11.         print(obj.name)
  12.         cpt = turtle.getItemCount(1)
  13.         print(cpt)
  14.         if(obj.name == "minecraft:iron_ingot" ) then
  15.            calc = calc + (cpt * 1)
  16.            print(calc.."credit")
  17.            turtle.dropDown()
  18.         end
  19.         rep = turtle.suck()
  20.     end
  21.     print("il y a au final "..calc)
  22.   end
  23.  
  24.  
  25.  
  26.   sleep(1)
  27. end
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top