From bda7c4ac13cf2ad621dee673a430cc43bb9e8e6b Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Sat, 9 Feb 2013 11:03:22 +0000 Subject: Added cBlockArea:Expand() API function (untested) git-svn-id: http://mc-server.googlecode.com/svn/trunk@1203 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/BlockArea.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'source/BlockArea.h') diff --git a/source/BlockArea.h b/source/BlockArea.h index e01eade69..b1a2d9053 100644 --- a/source/BlockArea.h +++ b/source/BlockArea.h @@ -77,6 +77,9 @@ public: /// Crops the internal contents by the specified amount of blocks from each border. void Crop(int a_AddMinX, int a_SubMaxX, int a_AddMinY, int a_SubMaxY, int a_AddMinZ, int a_SubMaxZ); + /// Expands the internal contents by the specified amount of blocks from each border + void Expand(int a_SubMinX, int a_AddMaxX, int a_SubMinY, int a_AddMaxY, int a_SubMinZ, int a_AddMaxZ); + // Setters: void SetRelBlockType (int a_RelX, int a_RelY, int a_RelZ, BLOCKTYPE a_BlockType); void SetBlockType (int a_BlockX, int a_BlockY, int a_BlockZ, BLOCKTYPE a_BlockType); @@ -186,6 +189,10 @@ protected: void CropBlockTypes(int a_AddMinX, int a_SubMaxX, int a_AddMinY, int a_SubMaxY, int a_AddMinZ, int a_SubMaxZ); void CropNibbles (NIBBLEARRAY & a_Array, int a_AddMinX, int a_SubMaxX, int a_AddMinY, int a_SubMaxY, int a_AddMinZ, int a_SubMaxZ); + // Expand helpers: + void ExpandBlockTypes(int a_SubMinX, int a_AddMaxX, int a_SubMinY, int a_AddMaxY, int a_SubMinZ, int a_AddMaxZ); + void ExpandNibbles (NIBBLEARRAY & a_Array, int a_SubMinX, int a_AddMaxX, int a_SubMinY, int a_AddMaxY, int a_SubMinZ, int a_AddMaxZ); + /// Loads the area from a schematic file uncompressed and parsed into a NBT tree. Returns true if successful. bool LoadFromSchematicNBT(cParsedNBT & a_NBT); -- cgit v1.2.3