term.clear

From ComputerCraft Wiki
Revision as of 14:40, 4 June 2013 by SuicidalSTDz (Talk | contribs) (Cleaned up return value, code example description, and added a new example of possible uses with term.clear (there are no args for term.clear and by putting 'none' it could be misleading to new members))

Jump to: navigation, search


Grid Redstone.png  Function term.clear
Clears the screen
Syntax term.clear()
Returns nil
Part of ComputerCraft
API term

Examples

Grid paper.png  Example
Clears any text on the console or monitor, also sets the cursor to position (1, 1) on the screen.
Code
term.clear()
term.setCursorPos(1,1)



Grid paper.png  Example
Turns the screen a specified colour
Code
term.setBackgroundColor(colors.blue)
term.clear()