Printer API

From ComputerCraft
Jump to navigation Jump to search

Printer.endPage Printer.getCursorPos

FunctionFunctionprinter.getInkLevel
Returns the amount of ink.
Syntax printer.getInkLevel()
Returns number inkAmount
Part of CC:Tweaked (source)
API printer
ExampleExampleGet ink level
Get ink level and print it.
Code
local printer = peripheral.find("printer")
print(printer.getInkLeve())
Output
5

Printer.getPageSize

FunctionFunctionprinter.getPaperLevel
Returns the amount of paper in the printer.
Syntax printer.getPaperLevel()
Returns number paperAmount
Part of CC:Tweaked (source)
API printer
ExampleExampleGet paper level
Get the paper level and print it.
Code
local printer = peripheral.find("printer")
print(printer.getPaperLevel())
Output
5

Printer.newPage Printer.setCursorPos Printer.setPageTitle Printer.write