summaryrefslogtreecommitdiffstats
path: root/src/Generating/PieceGenerator.h
diff options
context:
space:
mode:
authormadmaxoft <github@xoft.cz>2014-05-22 21:47:56 +0200
committermadmaxoft <github@xoft.cz>2014-05-22 21:47:56 +0200
commit6aa7df367f8db7506a8a5ab853c26e3c9fd60253 (patch)
treed869d17b349aa2fffc676224f5aee2f9c17b59f1 /src/Generating/PieceGenerator.h
parentUpdated plains village prefabs. (diff)
downloadcuberite-6aa7df367f8db7506a8a5ab853c26e3c9fd60253.tar
cuberite-6aa7df367f8db7506a8a5ab853c26e3c9fd60253.tar.gz
cuberite-6aa7df367f8db7506a8a5ab853c26e3c9fd60253.tar.bz2
cuberite-6aa7df367f8db7506a8a5ab853c26e3c9fd60253.tar.lz
cuberite-6aa7df367f8db7506a8a5ab853c26e3c9fd60253.tar.xz
cuberite-6aa7df367f8db7506a8a5ab853c26e3c9fd60253.tar.zst
cuberite-6aa7df367f8db7506a8a5ab853c26e3c9fd60253.zip
Diffstat (limited to '')
-rw-r--r--src/Generating/PieceGenerator.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/Generating/PieceGenerator.h b/src/Generating/PieceGenerator.h
index 643ca58b6..e396643a9 100644
--- a/src/Generating/PieceGenerator.h
+++ b/src/Generating/PieceGenerator.h
@@ -110,6 +110,7 @@ public:
virtual cPieces GetStartingPieces(void) = 0;
/** Returns the relative weight with which the a_NewPiece is to be selected for placing under a_PlacedPiece through a_ExistingConnector.
+ a_ExistingConnector is the original connector, before any movement or rotation is applied to it.
This allows the pool to tweak the piece's chances, based on the previous pieces in the tree and the connector used.
The higher the number returned, the higher the chance the piece will be chosen. 0 means the piece will never be chosen.
*/
@@ -151,6 +152,10 @@ public:
Undefined behavior if a_Index is out of range. */
cPiece::cConnector GetRotatedConnector(size_t a_Index) const;
+ /** Returns a copy of the specified connector, modified to account for the translation and rotation for
+ this placement. */
+ cPiece::cConnector GetRotatedConnector(const cPiece::cConnector & a_Connector) const;
+
protected:
const cPlacedPiece * m_Parent;
const cPiece * m_Piece;