summaryrefslogtreecommitdiffstats
path: root/source/World.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--source/World.cpp15
1 files changed, 2 insertions, 13 deletions
diff --git a/source/World.cpp b/source/World.cpp
index 6ec3825cf..606ef0787 100644
--- a/source/World.cpp
+++ b/source/World.cpp
@@ -1522,14 +1522,9 @@ void cWorld::SpawnItemPickups(const cItems & a_Pickups, double a_BlockX, double
float SpeedX = (float)(a_FlyAwaySpeed * (r1.randInt(1000) - 500));
float SpeedY = 1;
float SpeedZ = (float)(a_FlyAwaySpeed * (r1.randInt(1000) - 500));
-
- // Pickup doesn't spawn on client without a mid block position. Perhaps the doubles are causing issues?
- int MicroX = (int)(floor(a_BlockX) * 32) + 16;
- int MicroY = (int)(floor(a_BlockY) * 32) + 16;
- int MicroZ = (int)(floor(a_BlockZ) * 32) + 16;
cPickup * Pickup = new cPickup(
- MicroX, MicroY, MicroZ,
+ a_BlockX, a_BlockY, a_BlockZ,
*itr, SpeedX, SpeedY, SpeedZ
);
Pickup->Initialize(this);
@@ -1542,16 +1537,10 @@ void cWorld::SpawnItemPickups(const cItems & a_Pickups, double a_BlockX, double
void cWorld::SpawnItemPickups(const cItems & a_Pickups, double a_BlockX, double a_BlockY, double a_BlockZ, double a_SpeedX, double a_SpeedY, double a_SpeedZ)
{
- MTRand r1;
for (cItems::const_iterator itr = a_Pickups.begin(); itr != a_Pickups.end(); ++itr)
{
- // Pickup doesn't spawn on client without a mid block position. Perhaps the doubles are causing issues?
- int MicroX = (int)(floor(a_BlockX) * 32) + 16;
- int MicroY = (int)(floor(a_BlockY) * 32) + 16;
- int MicroZ = (int)(floor(a_BlockZ) * 32) + 16;
-
cPickup * Pickup = new cPickup(
- MicroX, MicroY, MicroZ,
+ a_BlockX, a_BlockY, a_BlockZ,
*itr, (float)a_SpeedX, (float)a_SpeedY, (float)a_SpeedZ
);
Pickup->Initialize(this);