The idea is this: A method guaranteed to execute a given script from a given library, regardless of what other scripts/libraries happen to be loaded at the same time.
The general idea is to have something like this in ACS that let's you specify the library name in addition to the script number:
- Code: Select all • Expand view
ACS_ExecuteEX(str Library, int Script, bool Always, int arg1, int arg2, int arg3, int arg4, int arg5)
Obviously this would have to be a built-in function as it takes a string. Note that I've removed the unnecessary Map argument and replaced it with a flag that determines whether to execute the script as normal or as if it was called with ACS_ExecuteAlways. If desired this could be done in a different way (with a separate function entirely, perhaps)
This becomes tricky at this point because the primary location for this to be useful, namely Decorate lumps, does not support built-in functions. To remedy that, I propose that A_ExecuteEX could be added and made to work the same way.
ExecuteWithResult could be added/extended in much the same way as above.
So why is this useful? It would let you specify that you want to execute script 1 from the MYLIB library, not the script 1 that happens to be on the current map, or the script 1 that belongs to the YOURLIB library. Currently this is gotten around by sticking scripts into libraries with hopefully obscure numbers that won't be reused -- however such a system is not guaranteed, especially when you start tacking on libraries. If it's desirable for mods to be made that are generic-use, as is commonly the aim of weapon mods or replacement mods, it would behoove us to have a solid way of ensuring there's no "cross-talk" between these add-ons.
