summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2015-10-05 22:03:35 +0200
committerMattes D <github@xoft.cz>2015-10-05 22:03:35 +0200
commit7c6bad2192438e49bbe8cef6ce56aa17f0fc8d09 (patch)
tree36c4c289213f931fe076ee30cb9a020a45627a1b /src
parentMerge pull request #2525 from cuberite/StreamPerf (diff)
parentUpdated PlainsVillage prefabs. (diff)
downloadcuberite-7c6bad2192438e49bbe8cef6ce56aa17f0fc8d09.tar
cuberite-7c6bad2192438e49bbe8cef6ce56aa17f0fc8d09.tar.gz
cuberite-7c6bad2192438e49bbe8cef6ce56aa17f0fc8d09.tar.bz2
cuberite-7c6bad2192438e49bbe8cef6ce56aa17f0fc8d09.tar.lz
cuberite-7c6bad2192438e49bbe8cef6ce56aa17f0fc8d09.tar.xz
cuberite-7c6bad2192438e49bbe8cef6ce56aa17f0fc8d09.tar.zst
cuberite-7c6bad2192438e49bbe8cef6ce56aa17f0fc8d09.zip
Diffstat (limited to 'src')
-rw-r--r--src/Generating/Prefab.h3
-rw-r--r--src/Generating/PrefabPiecePool.cpp1
2 files changed, 4 insertions, 0 deletions
diff --git a/src/Generating/Prefab.h b/src/Generating/Prefab.h
index 45af4b282..c62a68f97 100644
--- a/src/Generating/Prefab.h
+++ b/src/Generating/Prefab.h
@@ -146,6 +146,9 @@ public:
/** Sets the flag whether the lowest layer of the prefab should be repeated downwards until it hits a solid block. */
void SetExtendFloor(bool a_ShouldExtendFloor) { m_ShouldExtendFloor = a_ShouldExtendFloor; }
+ /** Sets the internal hitbox to the specified value. */
+ void SetHitBox(const cCuboid & a_HitBox) { m_HitBox = a_HitBox; }
+
protected:
/** Packs complete definition of a single block, for per-letter assignment. */
struct sBlockTypeDef
diff --git a/src/Generating/PrefabPiecePool.cpp b/src/Generating/PrefabPiecePool.cpp
index e2273aed3..8431500ce 100644
--- a/src/Generating/PrefabPiecePool.cpp
+++ b/src/Generating/PrefabPiecePool.cpp
@@ -287,6 +287,7 @@ bool cPrefabPiecePool::LoadCubesetPieceVer1(const AString & a_FileName, cLuaStat
{
return false;
}
+ prefab->SetHitBox(Hitbox);
// Read the connectors
if (!ReadConnectorsCubesetVer1(a_FileName, a_LuaState, PieceName, prefab.get(), a_LogWarnings))