Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Variables
- -- slots
- local slot = 0
- local slotActuel = 0
- -- bucket
- local bucketSlot = 0
- local bucketEmpty = "minecraft:bucket"
- local bucketFull = "minecraft:water_bucket"
- local bucketPlein = false;
- -- Fonctions
- -- Main
- function main()
- end
- -- Slot
- function selectSlot(a)
- turtle.select(a)
- majSlot()
- end
- function majSlot() -- A LANCER APRES CHAQUE DEPLACEMENT
- slotActuel = turtle.getSelectedSlot()
- slot = turtle.getDetailItem()
- end
- function firstSlot()
- turtle.select(1)
- majSlot()
- end
- function upSlot()
- turtle.select(slotActuel + 1)
- majSlot()
- end
- -- Bucket
- function findBucketSlot()
- end
- function bEtat()
- selectSlot(bucketSlot)
- if bIsEmpty() then
- bucketPlein = false;
- elseif bIsFull() then
- bucketPlein = true;
- end
- end
- function bIsEmpty()
- if slot.name == bucketEmpty then
- return true
- else
- return false
- end
- end
- function bIsFull()
- if slot.name == bucketFull then
- return true
- else
- return false
- end
- end
- --
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement