mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Clean up econ stuff, don't need it
This commit is contained in:
parent
0f051def21
commit
57e2905e24
|
@ -200,15 +200,6 @@ sv_client_suggestion_bot "Your client has bots and can be remotely controlled!\n
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# EXTERNAL CONSOLE
|
|
||||||
# ----------------
|
|
||||||
|
|
||||||
ec_bindaddr localhost
|
|
||||||
ec_port 7303
|
|
||||||
ec_output_level 1
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# CUSTOM CONFIG
|
# CUSTOM CONFIG
|
||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
|
|
|
@ -182,7 +182,7 @@ MACRO_CONFIG_INT(SvHit, sv_hit, 1, 0, 1, CFGFLAG_SERVER|CFGFLAG_GAME, "Whether p
|
||||||
MACRO_CONFIG_INT(SvEndlessDrag, sv_endless_drag, 0, 0, 1, CFGFLAG_SERVER|CFGFLAG_GAME, "Turns endless hooking on/off")
|
MACRO_CONFIG_INT(SvEndlessDrag, sv_endless_drag, 0, 0, 1, CFGFLAG_SERVER|CFGFLAG_GAME, "Turns endless hooking on/off")
|
||||||
MACRO_CONFIG_INT(SvTestingCommands, sv_test_cmds, 0, 0, 1, CFGFLAG_SERVER, "Turns testing commands aka cheats on/off (setting only works in initial config)")
|
MACRO_CONFIG_INT(SvTestingCommands, sv_test_cmds, 0, 0, 1, CFGFLAG_SERVER, "Turns testing commands aka cheats on/off (setting only works in initial config)")
|
||||||
MACRO_CONFIG_INT(SvFreezeDelay, sv_freeze_delay, 3, 1, 30, CFGFLAG_SERVER|CFGFLAG_GAME, "How many seconds the players will remain frozen (applies to all except delayed freeze in switch layer & deepfreeze)")
|
MACRO_CONFIG_INT(SvFreezeDelay, sv_freeze_delay, 3, 1, 30, CFGFLAG_SERVER|CFGFLAG_GAME, "How many seconds the players will remain frozen (applies to all except delayed freeze in switch layer & deepfreeze)")
|
||||||
MACRO_CONFIG_INT(ClDDRaceBindsSet, cl_race_binds_set, 0, 0, 2, CFGFLAG_CLIENT|CFGFLAG_SAVE, "What level the DDRace binds are set to (this is automated, you don't need to use this)")
|
MACRO_CONFIG_INT(ClDDRaceBindsSet, cl_race_binds_set, 0, 0, 1, CFGFLAG_CLIENT|CFGFLAG_SAVE, "What level the DDRace binds are set to (this is automated, you don't need to use this)")
|
||||||
MACRO_CONFIG_INT(SvEndlessSuperHook, sv_endless_super_hook, 0, 0, 1, CFGFLAG_SERVER, "Endless hook for super players on/off")
|
MACRO_CONFIG_INT(SvEndlessSuperHook, sv_endless_super_hook, 0, 0, 1, CFGFLAG_SERVER, "Endless hook for super players on/off")
|
||||||
MACRO_CONFIG_INT(SvHideScore, sv_hide_score, 0, 0, 1, CFGFLAG_SERVER, "Whether players scores will be announced or not")
|
MACRO_CONFIG_INT(SvHideScore, sv_hide_score, 0, 0, 1, CFGFLAG_SERVER, "Whether players scores will be announced or not")
|
||||||
MACRO_CONFIG_INT(SvSaveWorseScores, sv_save_worse_scores, 1, 0, 1, CFGFLAG_SERVER|CFGFLAG_GAME, "Whether to save worse scores when you already have a better one")
|
MACRO_CONFIG_INT(SvSaveWorseScores, sv_save_worse_scores, 1, 0, 1, CFGFLAG_SERVER|CFGFLAG_GAME, "Whether to save worse scores when you already have a better one")
|
||||||
|
|
|
@ -445,9 +445,6 @@ void CBinds::ConfigSaveCallback(IConfig *pConfig, void *pUserData)
|
||||||
|
|
||||||
void CBinds::SetDDRaceBinds(bool FreeOnly)
|
void CBinds::SetDDRaceBinds(bool FreeOnly)
|
||||||
{
|
{
|
||||||
if(g_Config.m_ClDDRaceBindsSet < 2)
|
|
||||||
Bind(KEY_F7, "toggle_econ_console", FreeOnly);
|
|
||||||
|
|
||||||
if(g_Config.m_ClDDRaceBindsSet < 1)
|
if(g_Config.m_ClDDRaceBindsSet < 1)
|
||||||
{
|
{
|
||||||
Bind(KEY_KP_PLUS, "zoom+", FreeOnly);
|
Bind(KEY_KP_PLUS, "zoom+", FreeOnly);
|
||||||
|
@ -480,5 +477,5 @@ void CBinds::SetDDRaceBinds(bool FreeOnly)
|
||||||
Bind(KEY_EQUALS, "spectate_next", FreeOnly);
|
Bind(KEY_EQUALS, "spectate_next", FreeOnly);
|
||||||
}
|
}
|
||||||
|
|
||||||
g_Config.m_ClDDRaceBindsSet = 2;
|
g_Config.m_ClDDRaceBindsSet = 1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -355,7 +355,7 @@ void CGameConsole::CInstance::PrintLine(const char *pLine, bool Highlighted)
|
||||||
}
|
}
|
||||||
|
|
||||||
CGameConsole::CGameConsole()
|
CGameConsole::CGameConsole()
|
||||||
: m_LocalConsole(CONSOLETYPE_LOCAL), m_RemoteConsole(CONSOLETYPE_REMOTE), m_EconConsole(CONSOLETYPE_ECON)
|
: m_LocalConsole(CONSOLETYPE_LOCAL), m_RemoteConsole(CONSOLETYPE_REMOTE)
|
||||||
{
|
{
|
||||||
m_ConsoleType = CONSOLETYPE_LOCAL;
|
m_ConsoleType = CONSOLETYPE_LOCAL;
|
||||||
m_ConsoleState = CONSOLE_CLOSED;
|
m_ConsoleState = CONSOLE_CLOSED;
|
||||||
|
@ -373,8 +373,6 @@ CGameConsole::CInstance *CGameConsole::CurrentConsole()
|
||||||
{
|
{
|
||||||
if(m_ConsoleType == CONSOLETYPE_REMOTE)
|
if(m_ConsoleType == CONSOLETYPE_REMOTE)
|
||||||
return &m_RemoteConsole;
|
return &m_RemoteConsole;
|
||||||
if(m_ConsoleType == CONSOLETYPE_ECON)
|
|
||||||
return &m_EconConsole;
|
|
||||||
return &m_LocalConsole;
|
return &m_LocalConsole;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -505,8 +503,6 @@ void CGameConsole::OnRender()
|
||||||
Graphics()->SetColor(0.2f, 0.2f, 0.2f,0.9f);
|
Graphics()->SetColor(0.2f, 0.2f, 0.2f,0.9f);
|
||||||
if(m_ConsoleType == CONSOLETYPE_REMOTE)
|
if(m_ConsoleType == CONSOLETYPE_REMOTE)
|
||||||
Graphics()->SetColor(0.4f, 0.2f, 0.2f,0.9f);
|
Graphics()->SetColor(0.4f, 0.2f, 0.2f,0.9f);
|
||||||
else if(m_ConsoleType == CONSOLETYPE_ECON)
|
|
||||||
Graphics()->SetColor(0.2f, 0.2f, 0.4f,0.9f);
|
|
||||||
Graphics()->QuadsSetSubset(0,-ConsoleHeight*0.075f,Screen.w*0.075f*0.5f,0);
|
Graphics()->QuadsSetSubset(0,-ConsoleHeight*0.075f,Screen.w*0.075f*0.5f,0);
|
||||||
QuadItem = IGraphics::CQuadItem(0, 0, Screen.w, ConsoleHeight);
|
QuadItem = IGraphics::CQuadItem(0, 0, Screen.w, ConsoleHeight);
|
||||||
Graphics()->QuadsDrawTL(&QuadItem, 1);
|
Graphics()->QuadsDrawTL(&QuadItem, 1);
|
||||||
|
@ -786,7 +782,7 @@ void CGameConsole::Toggle(int Type)
|
||||||
|
|
||||||
void CGameConsole::Dump(int Type)
|
void CGameConsole::Dump(int Type)
|
||||||
{
|
{
|
||||||
CInstance *pConsole = Type == CONSOLETYPE_REMOTE ? &m_RemoteConsole : Type == CONSOLETYPE_ECON ? &m_EconConsole : &m_LocalConsole;
|
CInstance *pConsole = Type == CONSOLETYPE_REMOTE ? &m_RemoteConsole : &m_LocalConsole;
|
||||||
char aFilename[128];
|
char aFilename[128];
|
||||||
char aDate[20];
|
char aDate[20];
|
||||||
|
|
||||||
|
@ -814,11 +810,6 @@ void CGameConsole::ConToggleRemoteConsole(IConsole::IResult *pResult, void *pUse
|
||||||
((CGameConsole *)pUserData)->Toggle(CONSOLETYPE_REMOTE);
|
((CGameConsole *)pUserData)->Toggle(CONSOLETYPE_REMOTE);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CGameConsole::ConToggleEconConsole(IConsole::IResult *pResult, void *pUserData)
|
|
||||||
{
|
|
||||||
((CGameConsole *)pUserData)->Toggle(CONSOLETYPE_ECON);
|
|
||||||
}
|
|
||||||
|
|
||||||
void CGameConsole::ConClearLocalConsole(IConsole::IResult *pResult, void *pUserData)
|
void CGameConsole::ConClearLocalConsole(IConsole::IResult *pResult, void *pUserData)
|
||||||
{
|
{
|
||||||
((CGameConsole *)pUserData)->m_LocalConsole.ClearBacklog();
|
((CGameConsole *)pUserData)->m_LocalConsole.ClearBacklog();
|
||||||
|
@ -829,11 +820,6 @@ void CGameConsole::ConClearRemoteConsole(IConsole::IResult *pResult, void *pUser
|
||||||
((CGameConsole *)pUserData)->m_RemoteConsole.ClearBacklog();
|
((CGameConsole *)pUserData)->m_RemoteConsole.ClearBacklog();
|
||||||
}
|
}
|
||||||
|
|
||||||
void CGameConsole::ConClearEconConsole(IConsole::IResult *pResult, void *pUserData)
|
|
||||||
{
|
|
||||||
((CGameConsole *)pUserData)->m_EconConsole.ClearBacklog();
|
|
||||||
}
|
|
||||||
|
|
||||||
void CGameConsole::ConDumpLocalConsole(IConsole::IResult *pResult, void *pUserData)
|
void CGameConsole::ConDumpLocalConsole(IConsole::IResult *pResult, void *pUserData)
|
||||||
{
|
{
|
||||||
((CGameConsole *)pUserData)->Dump(CONSOLETYPE_LOCAL);
|
((CGameConsole *)pUserData)->Dump(CONSOLETYPE_LOCAL);
|
||||||
|
@ -844,11 +830,6 @@ void CGameConsole::ConDumpRemoteConsole(IConsole::IResult *pResult, void *pUserD
|
||||||
((CGameConsole *)pUserData)->Dump(CONSOLETYPE_REMOTE);
|
((CGameConsole *)pUserData)->Dump(CONSOLETYPE_REMOTE);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CGameConsole::ConDumpEconConsole(IConsole::IResult *pResult, void *pUserData)
|
|
||||||
{
|
|
||||||
((CGameConsole *)pUserData)->Dump(CONSOLETYPE_ECON);
|
|
||||||
}
|
|
||||||
|
|
||||||
void CGameConsole::ClientConsolePrintCallback(const char *pStr, void *pUserData, bool Highlighted)
|
void CGameConsole::ClientConsolePrintCallback(const char *pStr, void *pUserData, bool Highlighted)
|
||||||
{
|
{
|
||||||
((CGameConsole *)pUserData)->m_LocalConsole.PrintLine(pStr, Highlighted);
|
((CGameConsole *)pUserData)->m_LocalConsole.PrintLine(pStr, Highlighted);
|
||||||
|
@ -893,8 +874,6 @@ void CGameConsole::PrintLine(int Type, const char *pLine)
|
||||||
m_LocalConsole.PrintLine(pLine);
|
m_LocalConsole.PrintLine(pLine);
|
||||||
else if(Type == CONSOLETYPE_REMOTE)
|
else if(Type == CONSOLETYPE_REMOTE)
|
||||||
m_RemoteConsole.PrintLine(pLine);
|
m_RemoteConsole.PrintLine(pLine);
|
||||||
else if(Type == CONSOLETYPE_ECON)
|
|
||||||
m_EconConsole.PrintLine(pLine);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void CGameConsole::OnConsoleInit()
|
void CGameConsole::OnConsoleInit()
|
||||||
|
@ -902,7 +881,6 @@ void CGameConsole::OnConsoleInit()
|
||||||
// init console instances
|
// init console instances
|
||||||
m_LocalConsole.Init(this);
|
m_LocalConsole.Init(this);
|
||||||
m_RemoteConsole.Init(this);
|
m_RemoteConsole.Init(this);
|
||||||
m_EconConsole.Init(this);
|
|
||||||
|
|
||||||
m_pConsole = Kernel()->RequestInterface<IConsole>();
|
m_pConsole = Kernel()->RequestInterface<IConsole>();
|
||||||
|
|
||||||
|
@ -911,13 +889,10 @@ void CGameConsole::OnConsoleInit()
|
||||||
|
|
||||||
Console()->Register("toggle_local_console", "", CFGFLAG_CLIENT, ConToggleLocalConsole, this, "Toggle local console");
|
Console()->Register("toggle_local_console", "", CFGFLAG_CLIENT, ConToggleLocalConsole, this, "Toggle local console");
|
||||||
Console()->Register("toggle_remote_console", "", CFGFLAG_CLIENT, ConToggleRemoteConsole, this, "Toggle remote console");
|
Console()->Register("toggle_remote_console", "", CFGFLAG_CLIENT, ConToggleRemoteConsole, this, "Toggle remote console");
|
||||||
Console()->Register("toggle_econ_console", "", CFGFLAG_CLIENT, ConToggleEconConsole, this, "Toggle econ console");
|
|
||||||
Console()->Register("clear_local_console", "", CFGFLAG_CLIENT, ConClearLocalConsole, this, "Clear local console");
|
Console()->Register("clear_local_console", "", CFGFLAG_CLIENT, ConClearLocalConsole, this, "Clear local console");
|
||||||
Console()->Register("clear_remote_console", "", CFGFLAG_CLIENT, ConClearRemoteConsole, this, "Clear remote console");
|
Console()->Register("clear_remote_console", "", CFGFLAG_CLIENT, ConClearRemoteConsole, this, "Clear remote console");
|
||||||
Console()->Register("clear_econ_console", "", CFGFLAG_CLIENT, ConClearEconConsole, this, "Clear econ console");
|
|
||||||
Console()->Register("dump_local_console", "", CFGFLAG_CLIENT, ConDumpLocalConsole, this, "Dump local console");
|
Console()->Register("dump_local_console", "", CFGFLAG_CLIENT, ConDumpLocalConsole, this, "Dump local console");
|
||||||
Console()->Register("dump_remote_console", "", CFGFLAG_CLIENT, ConDumpRemoteConsole, this, "Dump remote console");
|
Console()->Register("dump_remote_console", "", CFGFLAG_CLIENT, ConDumpRemoteConsole, this, "Dump remote console");
|
||||||
Console()->Register("dump_econ_console", "", CFGFLAG_CLIENT, ConDumpEconConsole, this, "Dump econ console");
|
|
||||||
|
|
||||||
Console()->Register("console_page_up", "", CFGFLAG_CLIENT, ConConsolePageUp, this, "Previous page in console");
|
Console()->Register("console_page_up", "", CFGFLAG_CLIENT, ConConsolePageUp, this, "Previous page in console");
|
||||||
Console()->Register("console_page_down", "", CFGFLAG_CLIENT, ConConsolePageDown, this, "Next page in console");
|
Console()->Register("console_page_down", "", CFGFLAG_CLIENT, ConConsolePageDown, this, "Next page in console");
|
||||||
|
|
|
@ -71,7 +71,6 @@ class CGameConsole : public CComponent
|
||||||
|
|
||||||
CInstance m_LocalConsole;
|
CInstance m_LocalConsole;
|
||||||
CInstance m_RemoteConsole;
|
CInstance m_RemoteConsole;
|
||||||
CInstance m_EconConsole;
|
|
||||||
|
|
||||||
CInstance *CurrentConsole();
|
CInstance *CurrentConsole();
|
||||||
float TimeNow();
|
float TimeNow();
|
||||||
|
@ -89,13 +88,10 @@ class CGameConsole : public CComponent
|
||||||
static void ClientConsolePrintCallback(const char *pStr, void *pUserData, bool Highlighted);
|
static void ClientConsolePrintCallback(const char *pStr, void *pUserData, bool Highlighted);
|
||||||
static void ConToggleLocalConsole(IConsole::IResult *pResult, void *pUserData);
|
static void ConToggleLocalConsole(IConsole::IResult *pResult, void *pUserData);
|
||||||
static void ConToggleRemoteConsole(IConsole::IResult *pResult, void *pUserData);
|
static void ConToggleRemoteConsole(IConsole::IResult *pResult, void *pUserData);
|
||||||
static void ConToggleEconConsole(IConsole::IResult *pResult, void *pUserData);
|
|
||||||
static void ConClearLocalConsole(IConsole::IResult *pResult, void *pUserData);
|
static void ConClearLocalConsole(IConsole::IResult *pResult, void *pUserData);
|
||||||
static void ConClearRemoteConsole(IConsole::IResult *pResult, void *pUserData);
|
static void ConClearRemoteConsole(IConsole::IResult *pResult, void *pUserData);
|
||||||
static void ConClearEconConsole(IConsole::IResult *pResult, void *pUserData);
|
|
||||||
static void ConDumpLocalConsole(IConsole::IResult *pResult, void *pUserData);
|
static void ConDumpLocalConsole(IConsole::IResult *pResult, void *pUserData);
|
||||||
static void ConDumpRemoteConsole(IConsole::IResult *pResult, void *pUserData);
|
static void ConDumpRemoteConsole(IConsole::IResult *pResult, void *pUserData);
|
||||||
static void ConDumpEconConsole(IConsole::IResult *pResult, void *pUserData);
|
|
||||||
static void ConConsolePageUp(IConsole::IResult *pResult, void *pUserData);
|
static void ConConsolePageUp(IConsole::IResult *pResult, void *pUserData);
|
||||||
static void ConConsolePageDown(IConsole::IResult *pResult, void *pUserData);
|
static void ConConsolePageDown(IConsole::IResult *pResult, void *pUserData);
|
||||||
static void ConchainConsoleOutputLevelUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
|
static void ConchainConsoleOutputLevelUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
|
||||||
|
@ -105,7 +101,6 @@ public:
|
||||||
{
|
{
|
||||||
CONSOLETYPE_LOCAL=0,
|
CONSOLETYPE_LOCAL=0,
|
||||||
CONSOLETYPE_REMOTE,
|
CONSOLETYPE_REMOTE,
|
||||||
CONSOLETYPE_ECON,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
CGameConsole();
|
CGameConsole();
|
||||||
|
|
Loading…
Reference in a new issue