diff --git a/config/menus_edit.cfg b/config/menus_edit.cfg index a932e094..f896bb59 100644 --- a/config/menus_edit.cfg +++ b/config/menus_edit.cfg @@ -355,7 +355,7 @@ tempalias __rebuildmapmodelmenus [ push idxs "" push mpath "" looplist $__mapmodelcategories [key menu] [delmenu $menu] - looplist (getmapmodelattributes explodekeywords sortby: keywords sortby: desc usage defaults distribution) [path keyword desc usage dflts dist] [ + looplist (listallmapmodelattributes explodekeywords sortby: keywords sortby: desc usage defaults distribution) [path keyword desc usage dflts dist] [ mpath = (concatword "mapmodels/" $path) dflts = (concat $dflts "0 0 0 0") dflts = (concat (at $dflts 0) (at $dflts 1) (at $dflts 2) (at $dflts 3)) // fix missing/incomplete default slot parameters diff --git a/source/src/rendermodel.cpp b/source/src/rendermodel.cpp index 2712e3c5..8f57687b 100644 --- a/source/src/rendermodel.cpp +++ b/source/src/rendermodel.cpp @@ -303,7 +303,7 @@ void cleanupmodels() enumerate(mdllookup, model *, m, m->cleanup()); } -void mapmodelattributes_(char *name, char *attr) // mostly for debugging purposes... +void getmapmodelattributes(char *name, char *attr) { const char *res = NULL; mapmodelattributes **ap = mdlregistry.access(name), *a = ap ? *ap : NULL; @@ -320,7 +320,7 @@ void mapmodelattributes_(char *name, char *attr) // mostly for debugging purp } result(res ? res : ""); } -COMMANDN(mapmodelattributes, mapmodelattributes_, "is"); +COMMAND(getmapmodelattributes, "ss"); static int mmasortorder = 0; int mmasort(mapmodelattributes **a, mapmodelattributes **b) { return strcmp((*a)->name, (*b)->name); } @@ -347,7 +347,7 @@ void writemapmodelattributes() delete f; } -void getmapmodelattributes(char **args, int numargs) // create a list of mapmodel paths and selected attributes +void listallmapmodelattributes(char **args, int numargs) // create a list of mapmodel paths and selected attributes { // parse argument list vector opts; @@ -396,7 +396,7 @@ void getmapmodelattributes(char **args, int numargs) // create a list of mapmode loopv(emmas) { delstring(emmas[i]->n[MMA_KEYWORDS]); delete emmas[i]; } // only delete what was exploded result(res.getbuf()); } -COMMAND(getmapmodelattributes, "v"); +COMMAND(listallmapmodelattributes, "v"); VARP(dynshadow, 0, 40, 100); VARP(dynshadowdecay, 0, 1000, 3000);