mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-20 15:08:19 +00:00
Add explicit button for current map as BG
This commit is contained in:
parent
74550e2c45
commit
0f177bad46
|
@ -2013,7 +2013,7 @@ void CMenus::RenderSettingsDDNet(CUIRect MainView)
|
|||
}
|
||||
}
|
||||
|
||||
MainView.HSplitTop(310.0f, &Gameplay, &MainView);
|
||||
MainView.HSplitTop(330.0f, &Gameplay, &MainView);
|
||||
|
||||
Gameplay.HSplitTop(30.0f, &Label, &Gameplay);
|
||||
UI()->DoLabelScaled(&Label, Localize("Gameplay"), 20.0f, -1);
|
||||
|
@ -2177,6 +2177,16 @@ void CMenus::RenderSettingsDDNet(CUIRect MainView)
|
|||
UI()->DoLabelScaled(&Label, Localize("Map"), 14.0f, -1);
|
||||
DoEditBox(g_Config.m_ClBackgroundEntities, &Left, g_Config.m_ClBackgroundEntities, sizeof(g_Config.m_ClBackgroundEntities), 14.0f, &s_Map);
|
||||
|
||||
aRects[1].HSplitTop(20.0f, &Button, &aRects[1]);
|
||||
bool UseCurrentMap = str_comp(g_Config.m_ClBackgroundEntities, CURRENT) == 0;
|
||||
if(DoButton_CheckBox(&UseCurrentMap, Localize("Use current map as background"), UseCurrentMap, &Button))
|
||||
{
|
||||
if(UseCurrentMap)
|
||||
g_Config.m_ClBackgroundEntities[0] = '\0';
|
||||
else
|
||||
str_copy(g_Config.m_ClBackgroundEntities, CURRENT, sizeof(g_Config.m_ClBackgroundEntities));
|
||||
}
|
||||
|
||||
aRects[1].HSplitTop(20.0f, &Button, 0);
|
||||
if(DoButton_CheckBox(&g_Config.m_ClBackgroundShowTilesLayers, Localize("Show tiles layers from BG map"), g_Config.m_ClBackgroundShowTilesLayers, &Button))
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue