diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/linearextrude.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/linearextrude.cc b/src/linearextrude.cc index 4f5fd14..ccaa238 100644 --- a/src/linearextrude.cc +++ b/src/linearextrude.cc @@ -75,6 +75,14 @@ AbstractNode *LinearExtrudeModule::evaluate(const Context *ctx, const ModuleInst node->filename = c.getAbsolutePath(file.text); } + // if height not given, and first argument is a number, + // then assume it should be the height. + if ( c.lookup_variable("height").type == Value::UNDEFINED ) + if ( inst->argnames.size()>0 ) + if ( inst->argnames[0] == "" ) + if ( inst->argvalues[0].type == Value::NUMBER ) + height = Value(inst->argvalues[0]); + node->layername = layer.text; node->height = height.num; node->convexity = (int)convexity.num; |