aboutsummaryrefslogtreecommitdiff
path: root/src/server
diff options
context:
space:
mode:
Diffstat (limited to 'src/server')
-rw-r--r--src/server/game/DataStores/M2Stores.cpp8
-rw-r--r--src/server/game/Entities/GameObject/GameObject.cpp1
-rw-r--r--src/server/game/Movement/Spline/MoveSplineFlag.h1
-rw-r--r--src/server/scripts/Northrend/zone_sholazar_basin.cpp5
-rw-r--r--src/server/shared/Dynamic/LinkedList.h6
5 files changed, 4 insertions, 17 deletions
diff --git a/src/server/game/DataStores/M2Stores.cpp b/src/server/game/DataStores/M2Stores.cpp
index a30cd1ae124..d8caf1b340d 100644
--- a/src/server/game/DataStores/M2Stores.cpp
+++ b/src/server/game/DataStores/M2Stores.cpp
@@ -155,10 +155,8 @@ bool readCamera(M2Camera const* cam, uint32 buffSize, M2Header const* header, Ci
uint32 timeDiffThis = posTimestamps[i] - lastTarget.timeStamp;
float xDiff = nextTarget.locations.GetPositionX() - lastTarget.locations.GetPositionX();
float yDiff = nextTarget.locations.GetPositionY() - lastTarget.locations.GetPositionY();
- float zDiff = nextTarget.locations.GetPositionZ() - lastTarget.locations.GetPositionZ();
x = lastTarget.locations.GetPositionX() + (xDiff * (float(timeDiffThis) / float(timeDiffTarget)));
y = lastTarget.locations.GetPositionY() + (yDiff * (float(timeDiffThis) / float(timeDiffTarget)));
- z = lastTarget.locations.GetPositionZ() + (zDiff * (float(timeDiffThis) / float(timeDiffTarget)));
}
float xDiff = x - thisCam.locations.GetPositionX();
float yDiff = y - thisCam.locations.GetPositionY();
@@ -203,10 +201,10 @@ void LoadM2Cameras(std::string const& dataPath)
// Get file size
m2file.seekg(0, std::ios::end);
- std::streamoff const fileSize = m2file.tellg();
+ std::streamoff fileSize = m2file.tellg();
// Reject if not at least the size of the header
- if (static_cast<uint32 const>(fileSize) < sizeof(M2Header))
+ if (static_cast<uint32>(fileSize) < sizeof(M2Header))
{
TC_LOG_ERROR("server.loading", "Camera file %s is damaged. File is smaller than header size", filename.string().c_str());
m2file.close();
@@ -240,7 +238,7 @@ void LoadM2Cameras(std::string const& dataPath)
// Read header
M2Header const* header = reinterpret_cast<M2Header const*>(buffer.data());
- if (header->ofsCameras + sizeof(M2Camera) > static_cast<uint32 const>(fileSize))
+ if (header->ofsCameras + sizeof(M2Camera) > static_cast<uint32>(fileSize))
{
TC_LOG_ERROR("server.loading", "Camera file %s is damaged. Camera references position beyond file end", filename.string().c_str());
continue;
diff --git a/src/server/game/Entities/GameObject/GameObject.cpp b/src/server/game/Entities/GameObject/GameObject.cpp
index 69ab6c7a4cb..7a5fd4106c7 100644
--- a/src/server/game/Entities/GameObject/GameObject.cpp
+++ b/src/server/game/Entities/GameObject/GameObject.cpp
@@ -532,7 +532,6 @@ void GameObject::Update(uint32 diff)
m_lootState = GO_READY; // for other GOis same switched without delay to GO_READY
break;
}
- // NO BREAK for switch (m_lootState)
}
/* fallthrough */
case GO_READY:
diff --git a/src/server/game/Movement/Spline/MoveSplineFlag.h b/src/server/game/Movement/Spline/MoveSplineFlag.h
index 21aa1ada38b..199baf53ea3 100644
--- a/src/server/game/Movement/Spline/MoveSplineFlag.h
+++ b/src/server/game/Movement/Spline/MoveSplineFlag.h
@@ -73,7 +73,6 @@ namespace Movement
MoveSplineFlag() { raw() = 0; }
MoveSplineFlag(uint32 f) { raw() = f; }
- MoveSplineFlag(MoveSplineFlag const& f) { raw() = f.raw(); }
// Constant interface
diff --git a/src/server/scripts/Northrend/zone_sholazar_basin.cpp b/src/server/scripts/Northrend/zone_sholazar_basin.cpp
index 9cf48336457..137b6de5296 100644
--- a/src/server/scripts/Northrend/zone_sholazar_basin.cpp
+++ b/src/server/scripts/Northrend/zone_sholazar_basin.cpp
@@ -504,9 +504,7 @@ public:
Creature* crunchy = shooter->FindNearestCreature(NPC_CRUNCHY, 30);
Creature* bird = shooter->FindNearestCreature(NPC_THICKBIRD, 30);
- if (!bird || !crunchy)
- ; // fall to EVENT_MISS
- else
+ if (bird && crunchy)
{
shooter->CastSpell(bird, SPELL_MISS_BIRD_APPLE);
bird->CastSpell(bird, SPELL_BIRD_FALL);
@@ -517,7 +515,6 @@ public:
crunchy->GetMotionMaster()->MovePoint(0, bird->GetPositionX(), bird->GetPositionY(),
bird->GetMap()->GetWaterOrGroundLevel(bird->GetPhaseMask(), bird->GetPositionX(), bird->GetPositionY(), bird->GetPositionZ()));
/// @todo Make crunchy perform emote eat when he reaches the bird
-
break;
}
}
diff --git a/src/server/shared/Dynamic/LinkedList.h b/src/server/shared/Dynamic/LinkedList.h
index 071f7ae5740..0e9e44a2da4 100644
--- a/src/server/shared/Dynamic/LinkedList.h
+++ b/src/server/shared/Dynamic/LinkedList.h
@@ -164,12 +164,6 @@ class LinkedListHead
{ // construct with node pointer _Pnode
}
- Iterator& operator=(Iterator const& _Right)
- {
- _Ptr = _Right._Ptr;
- return *this;
- }
-
Iterator& operator=(const_pointer const& _Right)
{
_Ptr = pointer(_Right);