summaryrefslogtreecommitdiffstats
path: root/src/Scoreboard.cpp
diff options
context:
space:
mode:
authortycho <work.tycho@gmail.com>2015-05-24 13:56:56 +0200
committertycho <work.tycho@gmail.com>2015-05-24 13:56:56 +0200
commitdae9e5792a4f030ae9e748548a16a89790fbd311 (patch)
tree2142b8c4deb9f2c7ad096b8b0ec93fefccd8d8f1 /src/Scoreboard.cpp
parentMerge branch 'master' into PreventNewWarnings (diff)
downloadcuberite-dae9e5792a4f030ae9e748548a16a89790fbd311.tar
cuberite-dae9e5792a4f030ae9e748548a16a89790fbd311.tar.gz
cuberite-dae9e5792a4f030ae9e748548a16a89790fbd311.tar.bz2
cuberite-dae9e5792a4f030ae9e748548a16a89790fbd311.tar.lz
cuberite-dae9e5792a4f030ae9e748548a16a89790fbd311.tar.xz
cuberite-dae9e5792a4f030ae9e748548a16a89790fbd311.tar.zst
cuberite-dae9e5792a4f030ae9e748548a16a89790fbd311.zip
Diffstat (limited to 'src/Scoreboard.cpp')
-rw-r--r--src/Scoreboard.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/Scoreboard.cpp b/src/Scoreboard.cpp
index a4a4c3391..9f251ab94 100644
--- a/src/Scoreboard.cpp
+++ b/src/Scoreboard.cpp
@@ -276,7 +276,7 @@ size_t cTeam::GetNumPlayers(void) const
cScoreboard::cScoreboard(cWorld * a_World) : m_World(a_World)
{
- for (int i = 0; i < (int) dsCount; ++i)
+ for (int i = 0; i < static_cast<int>(dsCount); ++i)
{
m_Display[i] = nullptr;
}
@@ -323,11 +323,11 @@ bool cScoreboard::RemoveObjective(const AString & a_Name)
ASSERT(m_World != nullptr);
m_World->BroadcastScoreboardObjective(it->second.GetName(), it->second.GetDisplayName(), 1);
- for (unsigned int i = 0; i < (unsigned int) dsCount; ++i)
+ for (unsigned int i = 0; i < static_cast<unsigned int>(dsCount); ++i)
{
if (m_Display[i] == &it->second)
{
- SetDisplay(nullptr, (eDisplaySlot) i);
+ SetDisplay(nullptr, static_cast<eDisplaySlot>(i));
}
}
@@ -557,14 +557,14 @@ void cScoreboard::SendTo(cClientHandle & a_Client)
it->second.SendTo(a_Client);
}
- for (int i = 0; i < (int) dsCount; ++i)
+ for (int i = 0; i < static_cast<int>(dsCount); ++i)
{
// Avoid race conditions
cObjective * Objective = m_Display[i];
if (Objective)
{
- a_Client.SendDisplayObjective(Objective->GetName(), (eDisplaySlot) i);
+ a_Client.SendDisplayObjective(Objective->GetName(), static_cast<eDisplaySlot>(i));
}
}
}