Ignore:
Timestamp:
07/03/20 00:32:23 (4 years ago)
Author:
Maciej Komosinski
Message:
  • separate "0" and "0s" formats (for SHAPE_BALL_AND_STICK and SHAPE_SOLIDS, respectively)
  • converting to format list (Geno::F0_FORMAT_LIST = "0,0s")
  • (optional) declaring Model as SHAPE_BALL_AND_STICK or SHAPE_SOLIDS (or SHAPE_UNKNOWN)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/frams/model/modelobj.cpp

    r732 r972  
    5858void ModelObj::p_newfromstring(ExtValue *args, ExtValue *ret)
    5959{
    60         *ret = makeDynamicObject(new Model(Geno(args[0].getString())));
     60        *ret = makeDynamicObject(new Model(Geno(args[0].getString()), Model::SHAPE_UNKNOWN));
    6161}
    6262
     
    6565        Geno *g = GenoObj::fromObject(args[0].getObject());
    6666        if (g)
    67                 *ret = makeDynamicObject(new Model(*g));
     67                *ret = makeDynamicObject(new Model(*g, Model::SHAPE_UNKNOWN));
    6868        else
    6969                ret->setEmpty();
     
    7474        Model *m = NULL;
    7575        if (args[0].getType() == TString)
    76                 m = new Model(Geno(args[0].getString()), false, true);
     76                m = new Model(Geno(args[0].getString()), Model::SHAPE_UNKNOWN, false, true);
    7777        else
    7878        {
    7979                Geno *g = GenoObj::fromObject(args[0].getObject(), false);
    8080                if (g)
    81                         m = new Model(*g, false, true);
     81                        m = new Model(*g, Model::SHAPE_UNKNOWN, false, true);
    8282                else
    8383                        logPrintf("Model", "newWithCheckpoints", LOG_ERROR, "Geno or string expected, %s found", args[0].typeDescription().c_str());
Note: See TracChangeset for help on using the changeset viewer.