Merge pull request #463 from Henningstone/pr-ddnet-fix-top5

Forbid showing /top5 from rank 0 on
This commit is contained in:
Dennis Felsing 2016-05-05 01:41:42 +02:00
commit 056a00b478

View file

@ -396,7 +396,7 @@ void CGameContext::ConTeamTop5(IConsole::IResult *pResult, void *pUserData)
return;
}
if (pResult->NumArguments() > 0 && pResult->GetInteger(0) >= 0)
if (pResult->NumArguments() > 0 && pResult->GetInteger(0) > 0)
pSelf->Score()->ShowTeamTop5(pResult, pResult->m_ClientID, pUserData,
pResult->GetInteger(0));
else
@ -427,7 +427,7 @@ void CGameContext::ConTop5(IConsole::IResult *pResult, void *pUserData)
return;
}
if (pResult->NumArguments() > 0 && pResult->GetInteger(0) >= 0)
if (pResult->NumArguments() > 0 && pResult->GetInteger(0) > 0)
pSelf->Score()->ShowTop5(pResult, pResult->m_ClientID, pUserData,
pResult->GetInteger(0));
else