Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Functions
- function main()
- print("Welcome to Alchemy Turtle by kd8lvt!")
- print("Type the number of the recipe you want to preform, then press eneter!")
- print("1. Rubies (ProjectRed) -> Emeralds (Requires Forbidden Magic and that you have is researched!)")
- choice = tonumber(io.read())
- if choice == 1 then
- rubiesToEmeralds()
- end
- end
- function rubiesToEmeralds()
- print("How many times would you like me to do this recipe? (Must be at LEAST 4 times!)")
- i = tonumber(io.read())
- if i >= 4 then
- if turtle.getItemCount(1) > 0 then
- if turtle.getItemCount(2) > 0 then
- for i > 0 do
- turtle.select(2)
- turtle.drop(1)
- sleep(0.5)
- turtle.select(1)
- turtle.drop(1)
- turtle.suckDown()
- fragmentCount = turtle.getItemCount(1)
- if fragmentCount >= 10
- turtle.craft()
- else
- print("Not enough Emerald Fragments to craft, doing another alchemy phase.")
- end
- else
- print("I need at least ".. i .." rubies from Project Red in slot two (Slot to the right of slot one (top left))")
- else
- print("I need at least ".. i .." emerald fragments in slot one (Top left)")
- end
- end
- main()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement