add script commands to support texture and sound config menus
textureslotusagelist <what>
Return a list of 256 numbers representing the number of uses for every
texture slot. If <what> is "onlygeometry", uses as map model skin do
not count. If <what> is "onlymodels", the uses in map geometry do not
count.
gettextureorigin <path>
Returns the location where the texture actually can be found. The
possibilities are:
"official": texture was found in the working directory, which
indicates an official texture.
"custom": texture was found in the profile directory, which means,
the texture is either manually installed or downloaded.
"package dir #x": texture was found in a mod directory.
"<file not found>": that.
textureslotbyname <texture path>
Returns the list of numbers of all texture slots which use that texture
file.
edittexturestack <floor|wall|ceiling> <texture slot number>
Puts a texture slot in a "last used" list up front. The first
parameter picks the list, the second parameter is the texture
slot number to be used for the next edit
getautomapconfig
Returns "1" if automapconfig is already enabled, "0" otherwise.
getmapsoundorigin <path>
Returns the location where the map sound file actually can be found. The
possibilities are:
"official": the sound file was found in the working directory, which
indicates an official mapsound.
"custom": the file was found in the profile directory, which means,
the mapsound is either manually installed or downloaded.
"package dir #x": mapsound was found in a mod directory.
"<file not found>": that.
mapsoundslotbyname <mapsound path>
Returns the list of numbers of all mapsound slots which use that texture
file.
getmapsoundlist
Returns a list of all *.wav and *.ogg files below packages/audio/ambient.
DOCREF textureslotusagelist gettextureorigin textureslotbyname
DOCREF edittexturestack getautomapconfig
DOCREF getmapsoundorigin mapsoundslotbyname getmapsoundlist
This commit is contained in:
@@ -1754,9 +1754,9 @@ COMMAND(getscrext, "");
|
||||
|
||||
void listoptions(char *s)
|
||||
{
|
||||
extern const char *menufilesortorders[];
|
||||
const char *optionnames[] = { "entities", "ents", "weapons", "teamnames", "teamnames-abbrv", "punctuations", "crosshairnames", "menufilesortorders", "" };
|
||||
const char **optionlists[] = { optionnames, entnames + 1, entnames + 1, gunnames, teamnames, teamnames_s, punctnames, crosshairnames, menufilesortorders };
|
||||
extern const char *menufilesortorders[], *texturestacktypes[];
|
||||
const char *optionnames[] = { "entities", "ents", "weapons", "teamnames", "teamnames-abbrv", "punctuations", "crosshairnames", "menufilesortorders", "texturestacktypes", "" };
|
||||
const char **optionlists[] = { optionnames, entnames + 1, entnames + 1, gunnames, teamnames, teamnames_s, punctnames, crosshairnames, menufilesortorders, texturestacktypes };
|
||||
const char **listp = optionlists[getlistindex(s, optionnames, true, -1) + 1];
|
||||
commandret = conc(listp, -1, true);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user