Index: cpp/frams/genetics/f4/f4_oper.cpp
===================================================================
--- cpp/frams/genetics/f4/f4_oper.cpp	(revision 934)
+++ cpp/frams/genetics/f4/f4_oper.cpp	(revision 935)
@@ -1,4 +1,4 @@
 // This file is a part of Framsticks SDK.  http://www.framsticks.com/
-// Copyright (C) 1999-2017  Maciej Komosinski and Szymon Ulatowski.
+// Copyright (C) 1999-2020  Maciej Komosinski and Szymon Ulatowski.
 // See LICENSE.txt for details.
 
@@ -164,5 +164,5 @@
 			{
 				// make neuron
-				NeuroClass *rndclass = GenoOperators::getRandomNeuroClass();
+				NeuroClass *rndclass = GenoOperators::getRandomNeuroClass(Model::SHAPE_BALL_AND_STICK);
 				if (rndclass == NULL)
 				{
@@ -434,5 +434,5 @@
 	{
 		// '*', 'G', 'T', or 'S', 1/4 chance each
-		nc = GenoOperators::getRandomNeuroClassWithOutputAndNoInputs();
+		nc = GenoOperators::getRandomNeuroClassWithOutputAndNoInputs(Model::SHAPE_BALL_AND_STICK);
 	}
 	if (nc != NULL)
@@ -470,5 +470,5 @@
 		if (rndDouble(1) < 0.2f)
 		{
-			cl = GenoOperators::getRandomNeuroClassWithOutputAndNoInputs();
+			cl = GenoOperators::getRandomNeuroClassWithOutputAndNoInputs(Model::SHAPE_BALL_AND_STICK);
 			if (cl != NULL)
 			{
Index: cpp/frams/genetics/fB/fB_oper.cpp
===================================================================
--- cpp/frams/genetics/fB/fB_oper.cpp	(revision 934)
+++ cpp/frams/genetics/fB/fB_oper.cpp	(revision 935)
@@ -1,4 +1,4 @@
 // This file is a part of Framsticks SDK.  http://www.framsticks.com/
-// Copyright (C) 1999-2019  Maciej Komosinski and Szymon Ulatowski.
+// Copyright (C) 1999-2020  Maciej Komosinski and Szymon Ulatowski.
 // See LICENSE.txt for details.
 
@@ -287,5 +287,5 @@
 		int rndid = rndUint(tokenized.size()); // select random insertion point
 		std::advance(it, rndid);
-		NeuroClass *cls = getRandomNeuroClass();
+		NeuroClass *cls = getRandomNeuroClass(Model::SHAPE_BALL_AND_STICK);
 		if (cls)
 		{
Index: cpp/frams/genetics/fH/fH_oper.cpp
===================================================================
--- cpp/frams/genetics/fH/fH_oper.cpp	(revision 934)
+++ cpp/frams/genetics/fH/fH_oper.cpp	(revision 935)
@@ -1,4 +1,4 @@
 // This file is a part of Framsticks SDK.  http://www.framsticks.com/
-// Copyright (C) 1999-2018  Maciej Komosinski and Szymon Ulatowski.
+// Copyright (C) 1999-2020  Maciej Komosinski and Szymon Ulatowski.
 // See LICENSE.txt for details.
 
@@ -255,5 +255,5 @@
 		fH_Handle *handle = NULL;
 		method = FH_OPCOUNT + roulette(addoperations, FH_ADD_OPCOUNT);
-		if (getActiveNeuroClassCount() == 0) method = FH_OPCOUNT + FH_ADD_STICK;
+		if (getActiveNeuroClassCount(Model::SHAPE_BALL_AND_STICK) == 0) method = FH_OPCOUNT + FH_ADD_STICK;
 		switch (method - FH_OPCOUNT)
 		{
@@ -466,5 +466,5 @@
 	if (userandomclass)
 	{
-		nc = getRandomNeuroClass();
+		nc = getRandomNeuroClass(Model::SHAPE_BALL_AND_STICK);
 		// checking of neuron class availability should be checked before
 	}
@@ -503,30 +503,31 @@
 uint32_t Geno_fH::style(const char *g, int pos)
 {
-   char ch=g[pos];
-   uint32_t style=GENSTYLE_CS(0,GENSTYLE_NONE); //default, should be changed below
-
-   int pp=pos; //detect comment line
-   while (pp>1 && g[pp-1]!='\n') pp--;
-   if (g[pp]=='#') return GENSTYLE_RGBS(0,220,0,GENSTYLE_NONE); //comment line
-
-   if (pos==0 || g[pos-1]=='\n' || ch==':' || ch==',') style=GENSTYLE_CS(0,GENSTYLE_BOLD); else
-     if (ch=='\"') style=GENSTYLE_RGBS(150,0,0,GENSTYLE_BOLD); else
-     {
-      int cudz=0,neuclass=1; //ile cudz. do poczatku linii; czy w nazwie neuroklasy?
-      while (pos>0)
-      {
-         pos--;
-         if (g[pos]=='\"') cudz++;
-         if (cudz==0 && (g[pos]==':' || g[pos]==',')) neuclass=0;
-         if (g[pos]=='\n') break;
-      }
-      if (cudz%2)
-      {
-         if (neuclass) style=GENSTYLE_RGBS(150,0,150,GENSTYLE_BOLD); else //neuroclass
-           if (isalpha(ch)) style=GENSTYLE_RGBS(255,140,0,GENSTYLE_BOLD); else //property
-             style=GENSTYLE_RGBS(200,0,0,GENSTYLE_NONE);
-      } else
-        if (isalpha(ch)) style=GENSTYLE_RGBS(0,0,200,GENSTYLE_BOLD);
-     }
-   return style;
-}
+	char ch = g[pos];
+	uint32_t style = GENSTYLE_CS(0, GENSTYLE_NONE); //default, should be changed below
+
+	int pp = pos; //detect comment line
+	while (pp > 1 && g[pp - 1] != '\n') pp--;
+	if (g[pp] == '#') return GENSTYLE_RGBS(0, 220, 0, GENSTYLE_NONE); //comment line
+
+	if (pos == 0 || g[pos - 1] == '\n' || ch == ':' || ch == ',') style = GENSTYLE_CS(0, GENSTYLE_BOLD); else
+		if (ch == '\"') style = GENSTYLE_RGBS(150, 0, 0, GENSTYLE_BOLD); else
+		{
+			int cudz = 0, neuclass = 1; //ile cudz. do poczatku linii; czy w nazwie neuroklasy?
+			while (pos > 0)
+			{
+				pos--;
+				if (g[pos] == '\"') cudz++;
+				if (cudz == 0 && (g[pos] == ':' || g[pos] == ',')) neuclass = 0;
+				if (g[pos] == '\n') break;
+			}
+			if (cudz % 2)
+			{
+				if (neuclass) style = GENSTYLE_RGBS(150, 0, 150, GENSTYLE_BOLD); else //neuroclass
+					if (isalpha(ch)) style = GENSTYLE_RGBS(255, 140, 0, GENSTYLE_BOLD); else //property
+						style = GENSTYLE_RGBS(200, 0, 0, GENSTYLE_NONE);
+			}
+			else
+				if (isalpha(ch)) style = GENSTYLE_RGBS(0, 0, 200, GENSTYLE_BOLD);
+		}
+	return style;
+}
Index: cpp/frams/genetics/fL/fL_oper.cpp
===================================================================
--- cpp/frams/genetics/fL/fL_oper.cpp	(revision 934)
+++ cpp/frams/genetics/fL/fL_oper.cpp	(revision 935)
@@ -1,4 +1,4 @@
 // This file is a part of Framsticks SDK.  http://www.framsticks.com/
-// Copyright (C) 1999-2019  Maciej Komosinski and Szymon Ulatowski.
+// Copyright (C) 1999-2020  Maciej Komosinski and Szymon Ulatowski.
 // See LICENSE.txt for details.
 
@@ -141,5 +141,5 @@
 		{
 			SString det;
-			NeuroClass *cls = getRandomNeuroClass();
+			NeuroClass *cls = getRandomNeuroClass(Model::SHAPE_BALL_AND_STICK);
 			det = cls->getName();
 			Geno_fH::mutateNeuronProperties(det);
@@ -201,5 +201,5 @@
 			return creature->words["S"];
 		case FL_ADD_NEURO:
-			if (getActiveNeuroClassCount() == 0)
+			if (getActiveNeuroClassCount(Model::SHAPE_BALL_AND_STICK) == 0)
 				return creature->words["S"];
 			else
Index: cpp/frams/genetics/genooperators.cpp
===================================================================
--- cpp/frams/genetics/genooperators.cpp	(revision 934)
+++ cpp/frams/genetics/genooperators.cpp	(revision 935)
@@ -1,4 +1,4 @@
 // This file is a part of Framsticks SDK.  http://www.framsticks.com/
-// Copyright (C) 1999-2018  Maciej Komosinski and Szymon Ulatowski.
+// Copyright (C) 1999-2020  Maciej Komosinski and Szymon Ulatowski.
 // See LICENSE.txt for details.
 
@@ -223,46 +223,61 @@
 }
 
-int GenoOperators::getActiveNeuroClassCount()
+int GenoOperators::getActiveNeuroClassCount(Model::ShapeType for_shape_type)
 {
 	int count = 0;
 	for (int i = 0; i < Neuro::getClassCount(); i++)
-		if (Neuro::getClass(i)->genactive)
+	{
+		NeuroClass *nc = Neuro::getClass(i);
+		if (nc->isShapeTypeSupported(for_shape_type) && nc->genactive)
 			count++;
+	}
 	return count;
 }
 
-NeuroClass *GenoOperators::getRandomNeuroClass()
+NeuroClass *GenoOperators::getRandomNeuroClass(Model::ShapeType for_shape_type)
 {
 	vector<NeuroClass *> active;
 	for (int i = 0; i < Neuro::getClassCount(); i++)
-		if (Neuro::getClass(i)->genactive)
-			active.push_back(Neuro::getClass(i));
+	{
+		NeuroClass *nc = Neuro::getClass(i);
+		if (nc->isShapeTypeSupported(for_shape_type) && nc->genactive)
+			active.push_back(nc);
+	}
 	if (active.size() == 0) return NULL; else return active[rndUint(active.size())];
 }
 
-NeuroClass *GenoOperators::getRandomNeuroClassWithOutput()
+NeuroClass *GenoOperators::getRandomNeuroClassWithOutput(Model::ShapeType for_shape_type)
 {
 	vector<NeuroClass *> active;
 	for (int i = 0; i < Neuro::getClassCount(); i++)
-		if (Neuro::getClass(i)->genactive && Neuro::getClass(i)->getPreferredOutput() != 0)
-			active.push_back(Neuro::getClass(i));
+	{
+		NeuroClass *nc = Neuro::getClass(i);
+		if (nc->isShapeTypeSupported(for_shape_type) && nc->genactive && nc->getPreferredOutput() != 0)
+			active.push_back(nc);
+	}
 	if (active.size() == 0) return NULL; else return active[rndUint(active.size())];
 }
 
-NeuroClass *GenoOperators::getRandomNeuroClassWithInput()
+NeuroClass *GenoOperators::getRandomNeuroClassWithInput(Model::ShapeType for_shape_type)
 {
 	vector<NeuroClass *> active;
 	for (int i = 0; i < Neuro::getClassCount(); i++)
-		if (Neuro::getClass(i)->genactive && Neuro::getClass(i)->getPreferredInputs() != 0)
-			active.push_back(Neuro::getClass(i));
+	{
+		NeuroClass *nc = Neuro::getClass(i);
+		if (nc->isShapeTypeSupported(for_shape_type) && nc->genactive && nc->getPreferredInputs() != 0)
+			active.push_back(nc);
+	}
 	if (active.size() == 0) return NULL; else return active[rndUint(active.size())];
 }
 
-NeuroClass *GenoOperators::getRandomNeuroClassWithOutputAndNoInputs()
+NeuroClass *GenoOperators::getRandomNeuroClassWithOutputAndNoInputs(Model::ShapeType for_shape_type)
 {
 	vector<NeuroClass *> active;
 	for (int i = 0; i < Neuro::getClassCount(); i++)
-		if (Neuro::getClass(i)->genactive && Neuro::getClass(i)->getPreferredOutput() != 0 && Neuro::getClass(i)->getPreferredInputs() == 0)
-			active.push_back(Neuro::getClass(i));
+	{
+		NeuroClass *nc = Neuro::getClass(i);
+		if (nc->isShapeTypeSupported(for_shape_type) && nc->genactive && nc->getPreferredOutput() != 0 && nc->getPreferredInputs() == 0)
+			active.push_back(nc);
+	}
 	if (active.size() == 0) return NULL; else return active[rndUint(active.size())];
 }
Index: cpp/frams/genetics/genooperators.h
===================================================================
--- cpp/frams/genetics/genooperators.h	(revision 934)
+++ cpp/frams/genetics/genooperators.h	(revision 935)
@@ -1,4 +1,4 @@
 // This file is a part of Framsticks SDK.  http://www.framsticks.com/
-// Copyright (C) 1999-2018  Maciej Komosinski and Szymon Ulatowski.
+// Copyright (C) 1999-2020  Maciej Komosinski and Szymon Ulatowski.
 // See LICENSE.txt for details.
 
@@ -193,11 +193,11 @@
 	static void linearMix(vector<double> &p1, vector<double> &p2, double proportion); ///<mixes two real-valued vectors; inherited proportion should be within [0,1]; 1.0 does not change values (all inherited), 0.5 causes both vectors to become their average, 0.0 swaps values (none inherited).
 	static void linearMix(ParamInterface &p1, int i1, ParamInterface &p2, int i2, double proportion); ///<mixes i1'th and i2'th properties of p1 and p2; inherited proportion should be within [0,1]; 1.0 does not change values (all inherited), 0.5 causes both properties to become their average, 0.0 swaps values (none inherited). For integer properties applies random "dithering" when necessary.
-	static int getActiveNeuroClassCount(); ///<returns active class count
-	static NeuroClass* getRandomNeuroClass(); ///<returns random neuroclass or NULL when no active classes.
-	static NeuroClass* getRandomNeuroClassWithOutput(); ///<returns random neuroclass with output or NULL when no active classes.
-	static NeuroClass* getRandomNeuroClassWithInput(); ///<returns random neuroclass with input or NULL when no active classes.
-	static NeuroClass* getRandomNeuroClassWithOutputAndNoInputs(); ///<returns random sensor or NULL when no active classes.
-	static int getRandomNeuroClassWithOutput(const vector<NeuroClass*>& NClist); ///<returns index of random NeuroClass from the NClist or -1 (no neurons on the list that provide output) \e NClist list of available neuron classes
-	static int getRandomNeuroClassWithInput(const vector<NeuroClass*>& NClist); ///<returns index of random NeuroClass from the NClist or -1 (no neurons on the list that want input(s)) \e NClist list of available neuron classes
+	static int getActiveNeuroClassCount(Model::ShapeType for_shape_type); ///<returns active class count
+	static NeuroClass* getRandomNeuroClass(Model::ShapeType for_shape_type); ///<returns random neuroclass or NULL when no active classes.
+	static NeuroClass* getRandomNeuroClassWithOutput(Model::ShapeType for_shape_type); ///<returns random neuroclass with output or NULL when no active classes.
+	static NeuroClass* getRandomNeuroClassWithInput(Model::ShapeType for_shape_type); ///<returns random neuroclass with input or NULL when no active classes.
+	static NeuroClass* getRandomNeuroClassWithOutputAndNoInputs(Model::ShapeType for_shape_type); ///<returns random sensor or NULL when no active classes.
+	static int getRandomNeuroClassWithOutput(const vector<NeuroClass*>& NClist); ///<returns index of random NeuroClass from the NClist or -1 when no neurons in the list provide output \e NClist list of available neuron classes
+	static int getRandomNeuroClassWithInput(const vector<NeuroClass*>& NClist); ///<returns index of random NeuroClass from the NClist or -1 when no neurons in the list want input(s) \e NClist list of available neuron classes
 	static int getRandomChar(const char *choices, const char *excluded); ///<returns index of a random character from 'choices' excluding 'excluded', or -1 when everything is excluded or 'choices' is empty.
 	static NeuroClass* parseNeuroClass(char *&s); ///<returns longest matching neuroclass or NULL if the string does not begin with a valid neuroclass name. Advances \e s pointer.
@@ -208,5 +208,5 @@
 	static bool areAlike(char*, char*); ///<compares two text strings skipping whitespaces. Returns 1 when equal, 0 when different.
 	static char* strchrn0(const char *str, char ch); ///<like strchr, but does not find zero char in \e str.
-	static bool canStartNeuroClassName(const char firstchar); ///<determines if \e firstchar may start NeuroClass name. If not, it may start NeuroClass' (or Neuro's) property name.
+	static bool canStartNeuroClassName(const char firstchar); ///<determines if \e firstchar may start NeuroClass name. If not, it might start NeuroClass' (or Neuro's) property name.
 	//@}
 };
Index: cpp/frams/model/model.h
===================================================================
--- cpp/frams/model/model.h	(revision 934)
+++ cpp/frams/model/model.h	(revision 935)
@@ -54,5 +54,5 @@
 	*/
 
-class Model : public DestrBase
+class Model : public DestrBase, public ModelEnum
 {
 protected:
@@ -93,5 +93,4 @@
 
 public:
-	enum ShapeType { SHAPE_BALL_AND_STICK = 0, SHAPE_SOLIDS = 1, SHAPE_UNKNOWN, SHAPE_ILLEGAL };
 	/// used in internalCheck()
 	enum CheckType {
@@ -407,7 +406,7 @@
 	///////////////////////////
 
-	static Part &getMinPart();
-	static Part &getMaxPart();
-	static Part &getDefPart();
+	static Part_MinMaxDef &getMinPart();
+	static Part_MinMaxDef &getMaxPart();
+	static Part_MinMaxDef &getDefPart();
 	static Joint &getMinJoint();
 	static Joint &getMaxJoint();
Index: cpp/frams/neuro/neurofactory.cpp
===================================================================
--- cpp/frams/neuro/neurofactory.cpp	(revision 934)
+++ cpp/frams/neuro/neurofactory.cpp	(revision 935)
@@ -26,5 +26,5 @@
 	if (!nc) return 0;
 	if (!nc->active) return 0;
-	if (!(nc->supported_shape_types & (1 << (int)shape_type)))
+	if (!(nc->isShapeTypeSupported(shape_type)))
 	{
 		logPrintf("NeuroFactory", "createNeuroImpl", LOG_WARN,
