roflmuffin

Untitled

Sep 24th, 2019
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.19 KB | None | 0 0
  1. thresholdTicks = 20
  2.  
  3. machine = peripheral.wrap('left')
  4.  
  5. function getEnergyPercentage()
  6. return machine.getEnergyStored() / machine.getEnergyCapacity()
  7. end
  8.  
  9. print(getEnergyPercentage())
Add Comment
Please, Sign In to add comment