MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / FindPolyModelName

Function FindPolyModelName

model/polymodel.cpp:2229–2237  ·  view source on GitHub ↗

Searches thru all polymodels for a specific name, returns -1 if not found or index of polymodel with name

Source from the content-addressed store, hash-verified

2227// Searches thru all polymodels for a specific name, returns -1 if not found
2228// or index of polymodel with name
2229int FindPolyModelName(const std::filesystem::path &name) {
2230 for (int i = 0; i < MAX_POLY_MODELS; i++) {
2231 if (Poly_models[i].used && !stricmp(Poly_models[i].name, name.u8string().c_str())) {
2232 return i;
2233 }
2234 }
2235
2236 return -1;
2237}
2238
2239// Sets a positional instance
2240void StartPolyModelPosInstance(vector *posvec) {

Callers 3

LoadPolyModelFunction · 0.85
OnGenericAddNewMethod · 0.85
OnGenericChangeModelMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected