diff options
author | madmaxoft <github@xoft.cz> | 2014-03-26 22:01:01 +0100 |
---|---|---|
committer | madmaxoft <github@xoft.cz> | 2014-03-26 22:01:01 +0100 |
commit | 8c2c4f2463fcc429d336019fa0fd39098eb7d97f (patch) | |
tree | c5fa07f03e864577c20cc08d955f1f8075bb1c9f /src/Generating/Prefab.h | |
parent | Ignoring the default GalExports folder. (diff) | |
download | cuberite-8c2c4f2463fcc429d336019fa0fd39098eb7d97f.tar cuberite-8c2c4f2463fcc429d336019fa0fd39098eb7d97f.tar.gz cuberite-8c2c4f2463fcc429d336019fa0fd39098eb7d97f.tar.bz2 cuberite-8c2c4f2463fcc429d336019fa0fd39098eb7d97f.tar.lz cuberite-8c2c4f2463fcc429d336019fa0fd39098eb7d97f.tar.xz cuberite-8c2c4f2463fcc429d336019fa0fd39098eb7d97f.tar.zst cuberite-8c2c4f2463fcc429d336019fa0fd39098eb7d97f.zip |
Diffstat (limited to 'src/Generating/Prefab.h')
-rw-r--r-- | src/Generating/Prefab.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/Generating/Prefab.h b/src/Generating/Prefab.h index 6596b906b..3733166ab 100644 --- a/src/Generating/Prefab.h +++ b/src/Generating/Prefab.h @@ -33,13 +33,18 @@ public: int m_SizeZ; const char * m_CharMap; const char * m_Image; - // TODO: Connectors + const char * m_Connectors; + int m_AllowedRotations; + cBlockArea::eMergeStrategy m_MergeStrategy; }; cPrefab(const sDef & a_Def); /** Draws the prefab into the specified block area, according to the placement stored in the PlacedPiece. */ void Draw(cBlockArea & a_Dest, const cPlacedPiece * a_Placement); + + /** Returns true if the prefab has any connector of the specified type. */ + bool HasConnectorType(int a_ConnectorType) const; protected: /** Maps letters in the sDef::m_Image onto a number, BlockType * 16 | BlockMeta */ @@ -76,6 +81,9 @@ protected: /** Parses the Image in the definition into m_BlockArea's block types and metas, using the specified CharMap. */ void ParseBlockImage(const CharMap & a_CharMap, const char * a_BlockImage); + + /** Parses the connectors definition text into m_Connectors member. */ + void ParseConnectors(const char * a_ConnectorsDef); }; |