Mortal Kombat Plus
Documentação gerada automaticamente com Doxygen
Carregando...
Procurando...
Nenhuma entrada encontrado
Referência do Arquivo typewriter_printer.c
#include "typewriter_printer.h"
Gráfico de dependência de inclusões para typewriter_printer.c:

Ir para o código-fonte desse arquivo.

Funções

void typewriterEffect (const char *text, u16 x, u16 y, u16 delay, VDPPlane plane, u16 numPal)
 
void typewriterWriteAllLines (const TextLine *lines, u16 numLines, VDPPlane plane, u16 numPal)
 

Funções

◆ typewriterEffect()

void typewriterEffect ( const char * text,
u16 x,
u16 y,
u16 delay,
VDPPlane plane,
u16 numPal )

Definição na linha 3 do arquivo typewriter_printer.c.

4{
5 u16 len = strlen(text);
6 for (u16 i = 0; i < len; i++)
7 {
8 VDP_setTileMapXY(plane, TILE_ATTR_FULL(numPal, TRUE, FALSE, FALSE, TILE_FONT_INDEX + text[i] - ' '), x + i, y);
9 SYS_doVBlankProcess(); // Espera o V-Blank
10
11 if (delay != 0)
12 {
13 for (u16 j = 0; j < delay; j++)
14 {
15 SYS_doVBlankProcess(); // Atraso adicional
16 }
17 }
18 }
19}
Esse é o diagrama das funções que utilizam essa função:

◆ typewriterWriteAllLines()

void typewriterWriteAllLines ( const TextLine * lines,
u16 numLines,
VDPPlane plane,
u16 numPal )

Definição na linha 22 do arquivo typewriter_printer.c.

23{
24 for (u16 i = 0; i < numLines; i++)
25 {
26 const char *text = lines[i].text;
27 u16 x = lines[i].x;
28 u16 y = lines[i].y;
29 u16 len = strlen(text);
30 for (u16 j = 0; j < len; j++)
31 {
32 VDP_setTileMapXY(plane, TILE_ATTR_FULL(numPal, TRUE, FALSE, FALSE, TILE_FONT_INDEX + text[j] - ' '), x + j, y);
33 }
34 }
35}
Esse é o diagrama das funções que utilizam essa função: