diff --git a/Source/Menu-FN/colors.cpp b/Source/Menu-FN/colors.cpp index d65a8327..a91185db 100644 --- a/Source/Menu-FN/colors.cpp +++ b/Source/Menu-FN/colors.cpp @@ -16,6 +16,36 @@ vector col_refresh_title; vector col_refresh_text; vector col_refresh_bg; +string Colors_RGB8_to_HEX(vector color) +{ + string out = "^x"; + + for (int i = 0; i < 3; i++) { + string a; + float b = rint(color[i] * 15); + + switch (b) { + case 10: + a = "A"; + case 11: + a = "B"; + case 12: + a = "C"; + case 13: + a = "D"; + case 14: + a = "E"; + case 15: + a = "F"; + default: + a = ftos(b); + } + out = sprintf("%s%s", out, a); + } + + return out; +} + void Colors_Init(void) { int c; diff --git a/Source/Menu-FN/defs.h b/Source/Menu-FN/defs.h index 028a524c..c0660bf5 100644 --- a/Source/Menu-FN/defs.h +++ b/Source/Menu-FN/defs.h @@ -20,6 +20,7 @@ var int autocvar_menu_intro = FALSE; int g_vidsize[2]; int g_menuofs[2]; int g_mousepos[2]; +vector g_logosize; int g_lastmousepos[2]; int g_active; float g_btnofs; diff --git a/Source/Menu-FN/entry.cpp b/Source/Menu-FN/entry.cpp index 20ee6831..c8281550 100644 --- a/Source/Menu-FN/entry.cpp +++ b/Source/Menu-FN/entry.cpp @@ -15,6 +15,10 @@ void m_init(void) font_arial = loadfont( "label", "gfx/shell/arial.ttf", "14", -1 ); font_label_b = loadfont( "label_b", "gfx/shell/arialbd.ttf", "14 12 16", -1 ); + localcmd("plug_load ffmpeg\n"); + localcmd("con_textsize -12\n"); + shaderforname("logo_avi", "{\n{\nvideomap av:media/logo.avi\n}\n}"); + for (int i = 0; i < g_bmp.length; i++) { precache_pic(g_bmp[i]); } diff --git a/Source/Menu-FN/m_main.cpp b/Source/Menu-FN/m_main.cpp index ece89ba5..b58024fa 100644 --- a/Source/Menu-FN/m_main.cpp +++ b/Source/Menu-FN/m_main.cpp @@ -266,6 +266,10 @@ void menu_main_draw(void) WLabel_Static(235, 440, m_reslbl[IDS_MAIN_QUITHELP], 10, 10, col_help,1.0f, 0, font_label); } else { + drawpic([g_menuofs[0],g_menuofs[1] + 70], "logo_avi", + g_logosize, [1,1,1], 1.0f); + g_logosize = gecko_get_texture_extent("logo_avi"); + Widget_Draw(fn_main); WLabel_Static(235, 216, m_reslbl[IDS_MAIN_NEWGAMEHELP], 10, 10, col_help,1.0f, 0, font_label); diff --git a/Source/Menu-FN/w_label.cpp b/Source/Menu-FN/w_label.cpp index b96cd176..8df2d6bd 100644 --- a/Source/Menu-FN/w_label.cpp +++ b/Source/Menu-FN/w_label.cpp @@ -57,5 +57,6 @@ void WField_Static(int x, int y, string msg, int sx, int sy, vector col, drawfont = font; x += g_menuofs[0]; y += g_menuofs[1]; - drawtextfield([x,y], [sx,sy], flags, sprintf("^xAAA%s",msg)); + drawtextfield([x,y], [sx,sy], flags, sprintf("%s%s", + Colors_RGB8_to_HEX(col), msg)); } diff --git a/freecs/gfx.wad b/fn/gfx.wad similarity index 100% rename from freecs/gfx.wad rename to fn/gfx.wad diff --git a/fn/menu.dat b/fn/menu.dat index d520d500..79cfb1a7 100644 Binary files a/fn/menu.dat and b/fn/menu.dat differ