summaryrefslogtreecommitdiffstats
path: root/src/WorldStorage/WSSAnvil.h
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2017-06-21 07:47:26 +0200
committerLukas Pioch <lukas@zgow.de>2017-06-21 07:47:26 +0200
commit99b4c2bd09abb0c853e6c26f9b864172a0a049d1 (patch)
tree20be86809d7d557ba6610c4cfab1d2ae6d33e95a /src/WorldStorage/WSSAnvil.h
parentLighting Optimisations (#3785) (diff)
downloadcuberite-99b4c2bd09abb0c853e6c26f9b864172a0a049d1.tar
cuberite-99b4c2bd09abb0c853e6c26f9b864172a0a049d1.tar.gz
cuberite-99b4c2bd09abb0c853e6c26f9b864172a0a049d1.tar.bz2
cuberite-99b4c2bd09abb0c853e6c26f9b864172a0a049d1.tar.lz
cuberite-99b4c2bd09abb0c853e6c26f9b864172a0a049d1.tar.xz
cuberite-99b4c2bd09abb0c853e6c26f9b864172a0a049d1.tar.zst
cuberite-99b4c2bd09abb0c853e6c26f9b864172a0a049d1.zip
Diffstat (limited to '')
-rwxr-xr-xsrc/WorldStorage/WSSAnvil.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/WorldStorage/WSSAnvil.h b/src/WorldStorage/WSSAnvil.h
index f9f43305b..bda836a7a 100755
--- a/src/WorldStorage/WSSAnvil.h
+++ b/src/WorldStorage/WSSAnvil.h
@@ -145,10 +145,15 @@ protected:
Slots outside the ItemGrid range are ignored */
void LoadItemGridFromNBT(cItemGrid & a_ItemGrid, const cParsedNBT & a_NBT, int a_ItemsTagIdx, int s_SlotOffset = 0);
- /** Returns true iff the "id" child tag inside the specified tag equals the specified expected type.
+ /** Decodes the text contained within a sign.
+ Older versions used direct string representation, newer versions use JSON-formatted string.
+ This function extracts the text from either version. */
+ AString DecodeSignLine(const AString & a_Line);
+
+ /** Returns true iff the "id" child tag inside the specified tag equals (case-sensitive) any of the specified expected types.
Logs a warning to the console on mismatch.
The coordinates are used only for the log message. */
- bool CheckBlockEntityType(const cParsedNBT & a_NBT, int a_TagIdx, const char * a_ExpectedType, int a_BlockX, int a_BlockY, int a_BlockZ);
+ bool CheckBlockEntityType(const cParsedNBT & a_NBT, int a_TagIdx, const AStringVector & a_ExpectedTypes, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadBeaconFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadBrewingstandFromNBT(const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
@@ -158,10 +163,10 @@ protected:
cBlockEntity * LoadDropperFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadFlowerPotFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadFurnaceFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
- cBlockEntity * LoadMobSpawnerFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadHopperFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadJukeboxFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadMobHeadFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
+ cBlockEntity * LoadMobSpawnerFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadNoteBlockFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);
cBlockEntity * LoadSignFromNBT (const cParsedNBT & a_NBT, int a_TagIdx, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int a_BlockX, int a_BlockY, int a_BlockZ);