textutils.slowPrint

From ComputerCraft
Jump to: navigation, search

textutils.slowPrint
Function
Syntax
textutils.slowPrint()
Returns nil
API textutils
Source CC:Tweaked (source)

Slowly prints text, character-by-character, at the current cursor position in the current term. Accepts an optional rate parameter, in characters per second (default 20). This function is similar to textutils.slowWrite, however it automatically moves to the next line after writing.

  • ☑Y This function delegates to textutils.slowWrite, which in turn delegates to write, so they have the same behaviour.
  • ☑Y This function will insert a newline after printing.
  • ☒N This function does not support printing multiple objects. You will have to concatenate them together into a single string.
  • ☑Y This function supports writing newlines (e.g. via the \n character).
  • ☑Y This function will wrap the text when it is longer than the screen width.
  • If you don't want a trailing newline, consider using textutils.slowWrite instead.
ExampleExampleWith default rate
Slowly prints "Hello, world!" to the current term.
Code
textutils.slowPrint("Hello, world!")
ExampleExampleWith custom rate
Slowly prints "Hello, world!" to the current term, at 5 characters per second.
Code
textutils.slowPrint("Hello, world!", 5)