Changeset 999 for cpp/frams/model/model.h
- Timestamp:
- 07/13/20 13:51:43 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/frams/model/model.h
r972 r999 101 101 }; 102 102 protected: 103 ShapeType shape ;104 ShapeType declared_shape ;103 ShapeType shapetype; 104 ShapeType declared_shapetype; 105 105 106 106 SString nameForErrors() const; … … 134 134 int isValid() const { return buildstatus == valid; } 135 135 int getErrorPosition(bool includingwarnings = false); 136 ShapeType getShapeType() const { return shape ; }136 ShapeType getShapeType() const { return shapetype; } 137 137 bool isUsingCheckpoints() const { return using_checkpoints; } 138 138 bool isCheckpoint() const { return is_checkpoint; } … … 155 155 156 156 /// Create empty model with invalid empty genotype, declaring the shape type for later operations 157 Model(ShapeType sh = SHAPE _UNKNOWN);157 Model(ShapeType sh = SHAPETYPE_UNKNOWN); 158 158 159 159 /// Change the declared shape type of the Model … … 333 333 334 334 /** create new Part and add it to the model. @see addPart() */ 335 Part *addNewPart(Part::Shape shape = Part::SHAPE_BALL _AND_STICK) { return addPart(new Part(shape)); }335 Part *addNewPart(Part::Shape shape = Part::SHAPE_BALL) { return addPart(new Part(shape)); } 336 336 /** create new Joint and add it to the model. @see addJoint() */ 337 Joint *addNewJoint(Part *p1 = NULL, Part *p2 = NULL, Joint::Shape shape = Joint::SHAPE_ BALL_AND_STICK) { Joint *j = addJoint(new Joint()); j->shape = shape; if ((p1 != NULL) && (p2 != NULL)) j->attachToParts(p1, p2); return j; }337 Joint *addNewJoint(Part *p1 = NULL, Part *p2 = NULL, Joint::Shape shape = Joint::SHAPE_STICK) { Joint *j = addJoint(new Joint()); j->shape = shape; if ((p1 != NULL) && (p2 != NULL)) j->attachToParts(p1, p2); return j; } 338 338 /** create new Neuro and add it to the model. @see addNeuro() */ 339 339 Neuro *addNewNeuro() { return addNeuro(new Neuro()); }
Note: See TracChangeset
for help on using the changeset viewer.