MCPcopy Create free account
hub / github.com/arx/ArxLibertatis / CleanScriptLoadedIO

Function CleanScriptLoadedIO

Sources/DANAE/ARX_Interactive.cpp:1229–1246  ·  view source on GitHub ↗

Removes an IO loaded by a script command

Source from the content-addressed store, hash-verified

1227// Removes an IO loaded by a script command
1228//*************************************************************************************
1229void CleanScriptLoadedIO()
1230{
1231 for (long i = 1; i < inter.nbmax; i++)
1232 {
1233 if (inter.iobj[i] != NULL)
1234 {
1235 INTERACTIVE_OBJ * io = inter.iobj[i];
1236
1237 if (io->scriptload)
1238 {
1239 RemoveFromAllInventories(io);
1240 ReleaseInter(inter.iobj[i]);
1241 inter.iobj[i] = NULL;
1242 }
1243 else inter.iobj[i]->show = SHOW_FLAG_IN_SCENE;
1244 }
1245 }
1246}
1247
1248//*************************************************************************************
1249// Restores an IO to its initial status (Game start Status)

Callers 3

ARX_GAME_ResetFunction · 0.85
FirstFrameProcFunction · 0.85

Calls 2

RemoveFromAllInventoriesFunction · 0.85
ReleaseInterFunction · 0.85

Tested by

no test coverage detected