printer.getPaperLevel
From ComputerCraft Wiki
Revision as of 17:48, 10 April 2014 by MKlegoman357 (Talk | contribs)
| Returns the amount of paper in the printer. | |
| Syntax | printer.getPaperLevel() |
| Returns | number the amount of paper in the printer |
| Part of | ComputerCraft |
| API | printer |
Examples
| Prints how much paper there is in the printer (assuming there are 5 sheets of paper in the printer). | |
| Code |
local printer = peripheral.wrap("left") local paperAmount = printer.getPaperLevel() print("There is/are " .. paperAmount .. " sheet(s) of paper in the printer.") |
| Output | There is/are 5 sheet(s) of paper in the printer. |