Functions | |
NIL | screen.print (NUMBER x, NUMBER y, STRING txt) |
Prints text on the screen ( default values ). More... | |
NIL | screen.print (FONT fnt, NUMBER x, NUMBER y, STRING txt) |
Prints text on the screen ( custom font ). More... | |
NIL | screen.print (NUMBER x, NUMBER y, STRING txt, NUMBER size) |
Prints text on the screen ( custom size ). More... | |
NIL | screen.print (FONT fnt, NUMBER x, NUMBER y, STRING txt, NUMBER size) |
Prints text on the screen ( custom font and size ). More... | |
NIL | screen.print (NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face) |
Prints text on the screen (custom size and color, default font). More... | |
NIL | screen.print (FONT fnt, NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face) |
Prints text on the screen (custom font, size and color). More... | |
NIL | screen.print (NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face, COLOR shadow) |
Prints text on the screen (default font, size, colors). More... | |
NIL | screen.print (FONT fnt, NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face, COLOR shadow) |
Prints text on the screen (custom font, size and color). More... | |
NIL | screen.print (NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face, COLOR shadow, NUMBER align) |
Prints text on the screen (default font, size, colors, and custom alignment). More... | |
NIL | screen.print (FONT fnt, NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face, COLOR shadow, NUMBER align) |
Prints text on the screen (font, size, colors, and custom alignment). More... | |
NIL | screen.print (NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face, COLOR shadow, NUMBER align, NUMBER w) |
Prints text on the screen, limiting the width that can occupy (default font, size, colors, and custom alignment). More... | |
NIL | screen.print (FONT fnt, NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face, COLOR shadow, NUMBER align, NUMBER w) |
Prints text on the screen, limiting the width that can occupy (font, size, colors, and custom alignment). More... | |
NUMBER | screen.print (NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face, COLOR shadow, NUMBER scroll, NUMBER w) |
Prints text on the screen, limiting the width that can occupy (default font, size, colors, and custom scroll). More... | |
NUMBER | screen.print (FONT fnt, NUMBER x, NUMBER y, STRING txt, NUMBER size, COLOR face, COLOR shadow, NUMBER scroll, NUMBER w) |
Prints text on the screen, limiting the width that can occupy (font, size, colors, and custom scroll). More... | |
NIL | screen.clip (NUMBER x, NUMBER y, NUMBER w, NUMBER h) |
Limiting the drawing area. More... | |
NIL | screen.clip () |
Removes the limitation of the drawing area. More... | |
NUMBER | screen.textwidth (STRING txt) |
Gets the text width in pixels (using the default values). More... | |
NUMBER | screen.textwidth (STRING txt, NUMBER size) |
Gets the text width in pixels (using the default font, and custom text size). More... | |
NUMBER | screen.textwidth (FONT fnt, STRING txt) |
Gets the text width in pixels (using custom font, and 0.7 as text size). More... | |
NUMBER | screen.textwidth (FONT fnt, STRING txt, NUMBER size) |
Gets the text width in pixels (using custom font and text size). More... | |
NUMBER | screen.textheight () |
Gets the text height in pixels (using the default values). More... | |
NUMBER | screen.textheight (NUMBER size) |
Gets the text height in pixels (using the default font, and custom text size). More... | |
NUMBER | screen.textheight (FONT fnt) |
Gets the text height in pixels (using custom font). More... | |
NUMBER | screen.textheight (FONT fnt, NUMBER size) |
Gets the text height in pixels (using custom font and text size). More... | |
NIL | screen.clear (COLOR bkg) |
Clears the screen with the specified color. More... | |
IMAGE | screen.toimage () |
Makes an image with the screen content. More... | |
IMAGE | screen.buffertoimage () |
Makes an image with the draw buffer content. More... | |
NIL | screen.shot () |
Takes a screenshot and save it in the same homebrew folder with the name "screenshot.png" (if exists, it will be overwrite). More... | |
NIL | screen.shot (STRING path) |
Takes a screenshot and save it in the specified folder with Toma una captura de pantalla, y la guarda en la ruta y con el nombre especificados. More... | |
NIL | screen.consoleprint (STRING txt) |
Basic routine for printing text, use a monospaced font and start printing from the top left corner (the primary use of this function is debug). More... | |
NIL | screen.txtcolor (COLOR txtColor) |
Change the color of the text printed with screen.consoleprint(). More... | |
NIL | screen.txtbgcolor (COLOR bgColor) |
Change the background color of the text printed with screen.consoleprint(). More... | |
NUMBER | screen.consolexy () |
Gets the cursor position used by screen.consoleprint() (column and row). More... | |
NIL | screen.consolexy (NUMBER x, NUMBER y) |
Sets the cursor position used by screen.consoleprint() (column and row). More... | |
NUMBER | screen.fps () |
Computes the screen frames per second (fps). More... | |
NIL | screen.bilinear (NUMBER state) |
Enables the bilinear filter (smoothing). More... | |
NUMBER | screen.brightness () |
Gets the screen brightness. More... | |
NIL | screen.brightness (NUMBER bright) |
Sets the screen brightness. More... | |
NIL | screen.display (NUMBER mode) |
Enable or Disable the screen. More... | |
NIL | screen.flip () |
Refresh the screen. Any modifications made to it (display pictures, drawn shapes or text) will not be visible until this function is called . More... | |
Screen managing.
NIL screen.print | ( | NUMBER | x, |
NUMBER | y, | ||
STRING | txt | ||
) |
Prints text on the screen ( default values ).
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
NIL screen.print | ( | FONT | fnt, |
NUMBER | x, | ||
NUMBER | y, | ||
STRING | txt | ||
) |
Prints text on the screen ( custom font ).
fnt | A font previously loaded. |
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
NIL screen.print | ( | NUMBER | x, |
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size | ||
) |
Prints text on the screen ( custom size ).
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
NIL screen.print | ( | FONT | fnt, |
NUMBER | x, | ||
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size | ||
) |
Prints text on the screen ( custom font and size ).
fnt | A font previously loaded. |
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
NIL screen.print | ( | NUMBER | x, |
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face | ||
) |
Prints text on the screen (custom size and color, default font).
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color. |
NIL screen.print | ( | FONT | fnt, |
NUMBER | x, | ||
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face | ||
) |
Prints text on the screen (custom font, size and color).
fnt | A font previously loaded. |
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
NIL screen.print | ( | NUMBER | x, |
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face, | ||
COLOR | shadow | ||
) |
Prints text on the screen (default font, size, colors).
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
shadow | Shadow color. |
NIL screen.print | ( | FONT | fnt, |
NUMBER | x, | ||
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face, | ||
COLOR | shadow | ||
) |
Prints text on the screen (custom font, size and color).
fnt | A font previously loaded. |
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
shadow | Shadow color. |
NIL screen.print | ( | NUMBER | x, |
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face, | ||
COLOR | shadow, | ||
NUMBER | align | ||
) |
Prints text on the screen (default font, size, colors, and custom alignment).
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
shadow | Shadow color. |
align | Alignment of text, one of the following constants:
|
NIL screen.print | ( | FONT | fnt, |
NUMBER | x, | ||
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face, | ||
COLOR | shadow, | ||
NUMBER | align | ||
) |
Prints text on the screen (font, size, colors, and custom alignment).
fnt | A font previously loaded. |
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
shadow | Shadow color. |
align | Alignment of text, one of the following constants:
|
NIL screen.print | ( | NUMBER | x, |
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face, | ||
COLOR | shadow, | ||
NUMBER | align, | ||
NUMBER | w | ||
) |
Prints text on the screen, limiting the width that can occupy (default font, size, colors, and custom alignment).
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
shadow | Shadow color. |
align | Alignment of text, one of the following constants:
|
w | Width in pixels. If the text pass, will be trimmed and will continue on the next line. |
NIL screen.print | ( | FONT | fnt, |
NUMBER | x, | ||
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face, | ||
COLOR | shadow, | ||
NUMBER | align, | ||
NUMBER | w | ||
) |
Prints text on the screen, limiting the width that can occupy (font, size, colors, and custom alignment).
fnt | A font previously loaded. |
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
shadow | Shadow color. |
align | Alignment of text, one of the following constants:
|
w | Width in pixels. If the text pass, will be trimmed and will continue on the next line. |
NUMBER screen.print | ( | NUMBER | x, |
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face, | ||
COLOR | shadow, | ||
NUMBER | scroll, | ||
NUMBER | w | ||
) |
Prints text on the screen, limiting the width that can occupy (default font, size, colors, and custom scroll).
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
shadow | Shadow color. |
scroll | Scroll of text, one of the following constants:
|
w | Width in pixels. If the text pass, will be trimmed and will continue on the next line. |
Consult the following sample for more details.
NUMBER screen.print | ( | FONT | fnt, |
NUMBER | x, | ||
NUMBER | y, | ||
STRING | txt, | ||
NUMBER | size, | ||
COLOR | face, | ||
COLOR | shadow, | ||
NUMBER | scroll, | ||
NUMBER | w | ||
) |
Prints text on the screen, limiting the width that can occupy (font, size, colors, and custom scroll).
fnt | A font previously loaded. |
x | X coordinate where the text is printed. |
y | Y coordinate where the text is printed. |
txt | Text to print. |
size | Size of the text. There is no restriction, but are preferable sizes close to 1. |
face | Text color |
shadow | Shadow color. |
scroll | Scroll of text, one of the following constants:
|
w | Width in pixels. If the text pass, will be trimmed and will continue on the next line. |
Consult the following sample for more details.
NIL screen.clip | ( | NUMBER | x, |
NUMBER | y, | ||
NUMBER | w, | ||
NUMBER | h | ||
) |
Limiting the drawing area.
x | Coordinate X of the top left corner. |
y | Coordinate Y of the top left corner. |
w | Width. |
h | Height. |
NIL screen.clip | ( | ) |
Removes the limitation of the drawing area.
NUMBER screen.textwidth | ( | STRING | txt | ) |
Gets the text width in pixels (using the default values).
txt | Text to get its width. |
NUMBER screen.textwidth | ( | STRING | txt, |
NUMBER | size | ||
) |
Gets the text width in pixels (using the default font, and custom text size).
txt | Text to get its width. |
size | Text size. |
NUMBER screen.textwidth | ( | FONT | fnt, |
STRING | txt | ||
) |
Gets the text width in pixels (using custom font, and 0.7 as text size).
fnt | A loaded font. |
txt | Text to get its width. |
NUMBER screen.textwidth | ( | FONT | fnt, |
STRING | txt, | ||
NUMBER | size | ||
) |
Gets the text width in pixels (using custom font and text size).
fnt | A loaded font. |
txt | Text to get its width. |
size | Text size. |
NUMBER screen.textheight | ( | ) |
Gets the text height in pixels (using the default values).
NUMBER screen.textheight | ( | NUMBER | size | ) |
Gets the text height in pixels (using the default font, and custom text size).
size | Text size. |
NUMBER screen.textheight | ( | FONT | fnt | ) |
Gets the text height in pixels (using custom font).
fnt | A loaded font. |
NUMBER screen.textheight | ( | FONT | fnt, |
NUMBER | size | ||
) |
Gets the text height in pixels (using custom font and text size).
fnt | A loaded font. |
size | Text size. |
NIL screen.clear | ( | COLOR | bkg | ) |
Clears the screen with the specified color.
bkg | Color to use. |
IMAGE screen.toimage | ( | ) |
Makes an image with the screen content.
IMAGE screen.buffertoimage | ( | ) |
Makes an image with the draw buffer content.
NIL screen.shot | ( | ) |
Takes a screenshot and save it in the same homebrew folder with the name "screenshot.png" (if exists, it will be overwrite).
NIL screen.shot | ( | STRING | path | ) |
Takes a screenshot and save it in the specified folder with Toma una captura de pantalla, y la guarda en la ruta y con el nombre especificados.
path | Path and name where the screenshot will be saved (only PNG format). |
NIL screen.consoleprint | ( | STRING | txt | ) |
Basic routine for printing text, use a monospaced font and start printing from the top left corner (the primary use of this function is debug).
txt | Text to print. |
NIL screen.txtcolor | ( | COLOR | txtColor | ) |
Change the color of the text printed with screen.consoleprint().
txtColor | New text color. |
NIL screen.txtbgcolor | ( | COLOR | bgColor | ) |
Change the background color of the text printed with screen.consoleprint().
bgColor | El nuevo color del fondo del texto. Ignorar este argumento, o establecer un color completamente transparente (alpha = 0) desactiva el fondo del texto impreso. |
NUMBER screen.consolexy | ( | ) |
Gets the cursor position used by screen.consoleprint() (column and row).
NIL screen.consolexy | ( | NUMBER | x, |
NUMBER | y | ||
) |
Sets the cursor position used by screen.consoleprint() (column and row).
x | The new cursor horizontal position (column). |
y | The new cursor vertical position (row). |
NUMBER screen.fps | ( | ) |
Computes the screen frames per second (fps).
NIL screen.bilinear | ( | NUMBER | state | ) |
Enables the bilinear filter (smoothing).
state | One of these values:
|
NUMBER screen.brightness | ( | ) |
Gets the screen brightness.
NIL screen.brightness | ( | NUMBER | bright | ) |
Sets the screen brightness.
bright | The new value for the screen brightness. |
NIL screen.display | ( | NUMBER | mode | ) |
Enable or Disable the screen.
mode | Any of the following values:
|
NIL screen.flip | ( | ) |
Refresh the screen. Any modifications made to it (display pictures, drawn shapes or text) will not be visible until this function is called .