mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-19 22:48:18 +00:00
Added an option to turn it on/off
This commit is contained in:
parent
c19c60012c
commit
8f14070996
|
@ -953,6 +953,12 @@ void CMenus::RenderSettingsGeneral(CUIRect MainView)
|
|||
if(DoButton_CheckBox(&s_Showsocial, Localize("Show social"), g_Config.m_ClShowsocial, &Button))
|
||||
g_Config.m_ClShowsocial ^= 1;
|
||||
|
||||
GameRight.HSplitTop(Spacing, 0, &GameRight);
|
||||
GameRight.HSplitTop(ButtonHeight, &Button, &GameRight);
|
||||
static int s_ShowUserId = 0;
|
||||
if(DoButton_CheckBox(&s_ShowUserId, Localize("Show user IDs"), g_Config.m_ClShowUserId, &Button))
|
||||
g_Config.m_ClShowUserId ^= 1;
|
||||
|
||||
// show chat messages button
|
||||
if(g_Config.m_ClShowsocial)
|
||||
{
|
||||
|
|
|
@ -598,6 +598,8 @@ void CRenderTools::RenderTilemapGenerateSkip(class CLayers *pLayers)
|
|||
void CRenderTools::DrawClientID(ITextRender* pTextRender, CTextCursor* pCursor, int ID,
|
||||
const vec4& BgColor, const vec4& TextColor)
|
||||
{
|
||||
if(!g_Config.m_ClShowUserId) return;
|
||||
|
||||
char aBuff[4];
|
||||
str_format(aBuff, sizeof(aBuff), "%2d ", ID);
|
||||
|
||||
|
@ -627,5 +629,6 @@ void CRenderTools::DrawClientID(ITextRender* pTextRender, CTextCursor* pCursor,
|
|||
|
||||
float CRenderTools::GetClientIdRectSize(float FontSize)
|
||||
{
|
||||
if(!g_Config.m_ClShowUserId) return 0;
|
||||
return 1.4f * FontSize + 0.2f * FontSize;
|
||||
}
|
||||
|
|
|
@ -31,6 +31,8 @@ MACRO_CONFIG_INT(ClMouseMaxDistanceStatic, cl_mouse_max_distance_static, 400, 0,
|
|||
|
||||
MACRO_CONFIG_INT(ClCustomizeSkin, cl_customize_skin, 0, 0, 1, CFGFLAG_CLIENT|CFGFLAG_SAVE, "")
|
||||
|
||||
MACRO_CONFIG_INT(ClShowUserId, cl_show_user_id, 0, 0, 1, CFGFLAG_CLIENT|CFGFLAG_SAVE, "")
|
||||
|
||||
MACRO_CONFIG_INT(EdZoomTarget, ed_zoom_target, 1, 0, 1, CFGFLAG_CLIENT|CFGFLAG_SAVE, "Zoom to the current mouse target")
|
||||
MACRO_CONFIG_INT(EdShowkeys, ed_showkeys, 0, 0, 1, CFGFLAG_CLIENT|CFGFLAG_SAVE, "")
|
||||
MACRO_CONFIG_INT(EdColorGridInner, ed_color_grid_inner, 0xFFFFFF26, 0, 0, CFGFLAG_CLIENT|CFGFLAG_SAVE, "")
|
||||
|
|
Loading…
Reference in a new issue