The Ctrl + V Game

VinsCool

Persona Secretiva Felineus
Global Moderator
Joined
Jan 7, 2014
Messages
14,600
Trophies
4
Location
Another World
Website
www.gbatemp.net
XP
25,217
Country
Canada
C++:
void TextXYFull(const char* txt, int& x, int& y)
{
    int color = TEXT_COLOR_WHITE << 4, ori_x = x, ori_y = y;

    for (int i = 0; char charToDraw = (txt[i]); i++)
    {
        switch (charToDraw)
        {
        case '\n': x = ori_x; y += 16; continue;
        case '\x80': color = TEXT_COLOR_WHITE << 4; continue;
        case '\x82': color = TEXT_COLOR_YELLOW << 4; continue;
        case '\x85': color = TEXT_COLOR_CYAN << 4; continue;
        case '\x86': color = TEXT_COLOR_RED << 4; continue;
        case '\x8B': color = TEXT_COLOR_GREEN << 4; continue;
        case '\x8C': color = TEXT_COLOR_DARK_GRAY << 4; continue;
        case '\x8D': color = TEXT_COLOR_BLUE << 4; continue;
        }

        g_mem_dc->StretchBlt(SCALE(x), SCALE(y), SCALE(8), SCALE(16), g_gfx_dc, (charToDraw & 0x7f) << 3, color, 8, 16, SRCCOPY);
        x += 8;
    }
}
 
  • Like
Reactions: SylverReZ

SylverReZ

The planet is fine. The people are crazy.
Member
GBAtemp Patron
Joined
Sep 13, 2022
Messages
7,234
Trophies
3
Location
The Wired
Website
m4x1mumrez87.neocities.org
XP
22,178
Country
United Kingdom
C++:
void TextXYFull(const char* txt, int& x, int& y)
{
    int color = TEXT_COLOR_WHITE << 4, ori_x = x, ori_y = y;

    for (int i = 0; char charToDraw = (txt[i]); i++)
    {
        switch (charToDraw)
        {
        case '\n': x = ori_x; y += 16; continue;
        case '\x80': color = TEXT_COLOR_WHITE << 4; continue;
        case '\x82': color = TEXT_COLOR_YELLOW << 4; continue;
        case '\x85': color = TEXT_COLOR_CYAN << 4; continue;
        case '\x86': color = TEXT_COLOR_RED << 4; continue;
        case '\x8B': color = TEXT_COLOR_GREEN << 4; continue;
        case '\x8C': color = TEXT_COLOR_DARK_GRAY << 4; continue;
        case '\x8D': color = TEXT_COLOR_BLUE << 4; continue;
        }

        g_mem_dc->StretchBlt(SCALE(x), SCALE(y), SCALE(8), SCALE(16), g_gfx_dc, (charToDraw & 0x7f) << 3, color, 8, 16, SRCCOPY);
        x += 8;
    }
}
👀
 
  • Like
Reactions: jeffyTheHomebrewer

banjo2

gamer
Member
Joined
May 31, 2016
Messages
2,344
Trophies
1
Location
society
Website
youtube.com
XP
5,125
Country
United States
26270BF6-834E-4762-9B3B-FC2E3C6537A4.gif
 
  • Like
Reactions: jeffyTheHomebrewer

VinsCool

Persona Secretiva Felineus
Global Moderator
Joined
Jan 7, 2014
Messages
14,600
Trophies
4
Location
Another World
Website
www.gbatemp.net
XP
25,217
Country
Canada

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    D @ dadadad: блядь