From a9498b15cba3e28535b1295030a2667d10fe09ac Mon Sep 17 00:00:00 2001 From: def Date: Mon, 24 Jul 2017 23:48:26 +0200 Subject: [PATCH] Fat skins --- src/game/client/components/menus_settings.cpp | 9 ++++++++- src/game/client/render.cpp | 3 ++- src/game/variables.h | 1 + 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/src/game/client/components/menus_settings.cpp b/src/game/client/components/menus_settings.cpp index 6b0da6afc..a04d7f2c4 100644 --- a/src/game/client/components/menus_settings.cpp +++ b/src/game/client/components/menus_settings.cpp @@ -425,12 +425,19 @@ void CMenus::RenderSettingsTee(CUIRect MainView) Dummy.HSplitTop(20.0f, &DummyLabel, &Dummy); - if(DoButton_CheckBox(&g_Config.m_ClVanillaSkinsOnly, Localize("Vanilla Skins only"), g_Config.m_ClVanillaSkinsOnly, &DummyLabel)) + if(DoButton_CheckBox(&g_Config.m_ClVanillaSkinsOnly, Localize("Vanilla skins only"), g_Config.m_ClVanillaSkinsOnly, &DummyLabel)) { g_Config.m_ClVanillaSkinsOnly ^= 1; CheckSettings = true; } + Dummy.HSplitTop(20.0f, &DummyLabel, &Dummy); + + if(DoButton_CheckBox(&g_Config.m_ClFatSkins, Localize("Fat skins"), g_Config.m_ClFatSkins, &DummyLabel)) + { + g_Config.m_ClFatSkins ^= 1; + } + if(CheckSettings) { if(s_ClVanillaSkinsOnly == g_Config.m_ClVanillaSkinsOnly) diff --git a/src/game/client/render.cpp b/src/game/client/render.cpp index f1c8fc4c0..12e71deef 100644 --- a/src/game/client/render.cpp +++ b/src/game/client/render.cpp @@ -231,7 +231,8 @@ void CRenderTools::RenderTee(CAnimState *pAnim, CTeeRenderInfo *pInfo, int Emote vec2 BodyPos = Position + vec2(pAnim->GetBody()->m_X, pAnim->GetBody()->m_Y)*AnimScale; SelectSprite(OutLine?SPRITE_TEE_BODY_OUTLINE:SPRITE_TEE_BODY, 0, 0, 0); - IGraphics::CQuadItem QuadItem(BodyPos.x, BodyPos.y, BaseSize, BaseSize); + float BodySize = g_Config.m_ClFatSkins ? BaseSize * 1.3 : BaseSize; + IGraphics::CQuadItem QuadItem(BodyPos.x, BodyPos.y, BodySize, BodySize); Graphics()->QuadsDraw(&QuadItem, 1); // draw eyes diff --git a/src/game/variables.h b/src/game/variables.h index e671b2c3a..4652709b4 100644 --- a/src/game/variables.h +++ b/src/game/variables.h @@ -86,6 +86,7 @@ MACRO_CONFIG_INT(ClPlayerUseCustomColor, player_use_custom_color, 0, 0, 1, CFGFL MACRO_CONFIG_INT(ClPlayerColorBody, player_color_body, 65408, 0, 0xFFFFFF, CFGFLAG_CLIENT|CFGFLAG_SAVE, "Player body color") MACRO_CONFIG_INT(ClPlayerColorFeet, player_color_feet, 65408, 0, 0xFFFFFF, CFGFLAG_CLIENT|CFGFLAG_SAVE, "Player feet color") MACRO_CONFIG_STR(ClPlayerSkin, player_skin, 24, "default", CFGFLAG_CLIENT|CFGFLAG_SAVE, "Player skin") +MACRO_CONFIG_INT(ClFatSkins, cl_fat_skins, 0, 0, 1, CFGFLAG_CLIENT|CFGFLAG_SAVE, "Enable fat skins") MACRO_CONFIG_INT(UiPage, ui_page, 6, 0, 11, CFGFLAG_CLIENT|CFGFLAG_SAVE, "Interface page") MACRO_CONFIG_INT(UiToolboxPage, ui_toolbox_page, 0, 0, 2, CFGFLAG_CLIENT|CFGFLAG_SAVE, "Toolbox page")