diff options
author | madmaxoft <github@xoft.cz> | 2014-05-01 23:20:00 +0200 |
---|---|---|
committer | madmaxoft <github@xoft.cz> | 2014-05-01 23:20:00 +0200 |
commit | 6bdd3ee35e85768634e41af86a99bbdd933ffb3a (patch) | |
tree | 5481ae6b270a197f4a57341dfc42fb98343022b0 /src/BlockArea.cpp | |
parent | Merge branch 'master' into SslWebAdmin (diff) | |
parent | Fixed a warning in Noise. (diff) | |
download | cuberite-6bdd3ee35e85768634e41af86a99bbdd933ffb3a.tar cuberite-6bdd3ee35e85768634e41af86a99bbdd933ffb3a.tar.gz cuberite-6bdd3ee35e85768634e41af86a99bbdd933ffb3a.tar.bz2 cuberite-6bdd3ee35e85768634e41af86a99bbdd933ffb3a.tar.lz cuberite-6bdd3ee35e85768634e41af86a99bbdd933ffb3a.tar.xz cuberite-6bdd3ee35e85768634e41af86a99bbdd933ffb3a.tar.zst cuberite-6bdd3ee35e85768634e41af86a99bbdd933ffb3a.zip |
Diffstat (limited to 'src/BlockArea.cpp')
-rw-r--r-- | src/BlockArea.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/BlockArea.cpp b/src/BlockArea.cpp index 55e8d6849..e0ae2c5b6 100644 --- a/src/BlockArea.cpp +++ b/src/BlockArea.cpp @@ -2005,7 +2005,7 @@ void cBlockArea::ExpandBlockTypes(int a_SubMinX, int a_AddMaxX, int a_SubMinY, i int NewSizeX = m_Size.x + a_SubMinX + a_AddMaxX; int NewSizeY = m_Size.y + a_SubMinY + a_AddMaxY; int NewSizeZ = m_Size.z + a_SubMinZ + a_AddMaxZ; - size_t BlockCount = (size_t)NewSizeX * NewSizeY * NewSizeZ; + size_t BlockCount = (size_t)(NewSizeX * NewSizeY * NewSizeZ); BLOCKTYPE * NewBlockTypes = new BLOCKTYPE[BlockCount]; memset(NewBlockTypes, 0, BlockCount * sizeof(BLOCKTYPE)); int OldIndex = 0; @@ -2035,7 +2035,7 @@ void cBlockArea::ExpandNibbles(NIBBLEARRAY & a_Array, int a_SubMinX, int a_AddMa int NewSizeX = m_Size.x + a_SubMinX + a_AddMaxX; int NewSizeY = m_Size.y + a_SubMinY + a_AddMaxY; int NewSizeZ = m_Size.z + a_SubMinZ + a_AddMaxZ; - size_t BlockCount = (size_t)NewSizeX * NewSizeY * NewSizeZ; + size_t BlockCount = (size_t)(NewSizeX * NewSizeY * NewSizeZ); NIBBLETYPE * NewNibbles = new NIBBLETYPE[BlockCount]; memset(NewNibbles, 0, BlockCount * sizeof(NIBBLETYPE)); int OldIndex = 0; |