summaryrefslogtreecommitdiffstats
path: root/src/Generating/Prefab.cpp
diff options
context:
space:
mode:
authormadmaxoft <github@xoft.cz>2014-03-30 19:17:33 +0200
committermadmaxoft <github@xoft.cz>2014-03-30 19:17:33 +0200
commit1bda9b042403bbc20c564a582435a083fc4dcc84 (patch)
tree8210ebddd8925889c31d3b4fb77e813b3aea6ec1 /src/Generating/Prefab.cpp
parentAPIDump: Added article: Setting up ZeroBrane Studio. (diff)
parentAdded all current NetherFort prefabs. (diff)
downloadcuberite-1bda9b042403bbc20c564a582435a083fc4dcc84.tar
cuberite-1bda9b042403bbc20c564a582435a083fc4dcc84.tar.gz
cuberite-1bda9b042403bbc20c564a582435a083fc4dcc84.tar.bz2
cuberite-1bda9b042403bbc20c564a582435a083fc4dcc84.tar.lz
cuberite-1bda9b042403bbc20c564a582435a083fc4dcc84.tar.xz
cuberite-1bda9b042403bbc20c564a582435a083fc4dcc84.tar.zst
cuberite-1bda9b042403bbc20c564a582435a083fc4dcc84.zip
Diffstat (limited to 'src/Generating/Prefab.cpp')
-rw-r--r--src/Generating/Prefab.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Generating/Prefab.cpp b/src/Generating/Prefab.cpp
index a9e0a839d..131b6acb2 100644
--- a/src/Generating/Prefab.cpp
+++ b/src/Generating/Prefab.cpp
@@ -172,6 +172,8 @@ bool cPrefab::HasConnectorType(int a_ConnectorType) const
void cPrefab::ParseCharMap(CharMap & a_CharMapOut, const char * a_CharMapDef)
{
+ ASSERT(a_CharMapDef != NULL);
+
// Initialize the charmap to all-invalid values:
for (size_t i = 0; i < ARRAYCOUNT(a_CharMapOut); i++)
{
@@ -231,6 +233,8 @@ void cPrefab::ParseBlockImage(const CharMap & a_CharMap, const char * a_BlockIma
void cPrefab::ParseConnectors(const char * a_ConnectorsDef)
{
+ ASSERT(a_ConnectorsDef != NULL);
+
AStringVector Lines = StringSplitAndTrim(a_ConnectorsDef, "\n");
for (AStringVector::const_iterator itr = Lines.begin(), end = Lines.end(); itr != end; ++itr)
{