MCPcopy Create free account
hub / github.com/ddnet/ddnet / DummyName

Method DummyName

src/engine/client/client.cpp:1109–1130  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1107}
1108
1109const char *CClient::DummyName()
1110{
1111 if(g_Config.m_ClDummyName[0])
1112 {
1113 return g_Config.m_ClDummyName;
1114 }
1115 const char *pBase = nullptr;
1116 if(g_Config.m_PlayerName[0])
1117 {
1118 pBase = g_Config.m_PlayerName;
1119 }
1120 else if(g_Config.m_SteamName[0])
1121 {
1122 pBase = g_Config.m_SteamName;
1123 }
1124 if(pBase)
1125 {
1126 str_format(m_aAutomaticDummyName, sizeof(m_aAutomaticDummyName), "[D] %s", pBase);
1127 return m_aAutomaticDummyName;
1128 }
1129 return "brainless tee";
1130}
1131
1132const char *CClient::ErrorString() const
1133{

Callers 5

OnRenderMethod · 0.80
SendStartInfo7Method · 0.80
SendDummyInfoMethod · 0.80
RenderSettingsPlayerMethod · 0.80

Calls 1

str_formatFunction · 0.85

Tested by

no test coverage detected