fix code style

This commit is contained in:
archimede67 2019-06-05 19:49:00 +02:00
parent 65353c2030
commit 0e62b4b9b9
2 changed files with 25 additions and 29 deletions

View file

@ -3306,14 +3306,10 @@ void CClient::Con_SaveReplay(IConsole::IResult *pResult, void *pUserData)
{
int Length = pResult->GetInteger(0);
if(Length <= 0)
{
pSelf->m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "Error: length must be greater than 0 second.");
}
else
{
pSelf->SaveReplay(Length);
}
}
else
pSelf->SaveReplay(g_Config.m_ClReplayLength);
}
@ -3324,9 +3320,9 @@ void CClient::SaveReplay(const int Length)
{
m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "Feature is disabled. Please enable it via configuration.");
GameClient()->Echo(Localize("Replay feature is disabled!"));
return;
}
else
{
if(!DemoRecorder(RECORDER_REPLAYS)->IsRecording())
m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "Error: demorecorder isn't recording. Try to rejoin to fix that.");
else if(DemoRecorder(RECORDER_REPLAYS)->Length() < 1)
@ -3357,7 +3353,7 @@ void CClient::SaveReplay(const int Length)
// And we restart the recorder
DemoRecorder_StartReplayRecorder();
}
}
}
void CClient::DemoSlice(const char *pDstPath, CLIENTFUNC_FILTER pfnFilter, void *pUser)

View file

@ -554,7 +554,7 @@ void CScoreboard::RenderRecordingNotification(float x)
str_format(aBuf2, sizeof(aBuf2), Localize("Auto %3d:%02d "), Seconds/60, Seconds%60);
str_append(aBuf, aBuf2, sizeof(aBuf));
}
if (m_pClient->DemoRecorder(RECORDER_REPLAYS)->IsRecording())
if(m_pClient->DemoRecorder(RECORDER_REPLAYS)->IsRecording())
{
Seconds = m_pClient->DemoRecorder(RECORDER_REPLAYS)->Length();
str_format(aBuf2, sizeof(aBuf2), Localize("Replay %3d:%02d "), Seconds / 60, Seconds % 60);