My quest script uses a referencealias frequently throughout the script. This referencealias has a custom script on it that is very important to the quests functionality. Currently, I have it set up as a property within the script. However, I fill this reference multiple times with many different references. That is to say, I'm constantly swapping out the alias for different actors. It wouldn't be uncommon for the user of my mod to repeat this over 100 times. I worry about the whole "property persistence" issue that the wiki mentions.
When a script property is pointed at a reference in the editor, the target reference will be flagged as "permanently persistent". In other words, nothing you do during runtime will unload the object. This means that, if possible, you should not use properties to point at references directly. If you can, pull references in from events or other locations to avoid permanently keeping them around. Even if you reassign a value to your property while the game is running, the original reference will stick around.
And then Later,
Avoid properties to references if possible
Now, because I'm working with a referencealias, I wonder if this is still an issue. If I'm interpreting the wording correctly, the "ReferenceAlias Reference" will be persistent forever. However, the referencealias, by default, is just a "reference" to the quest alias within the quest, is it not? It's also not automatically filled with a reference (if that matters). But I
do end up filling it with multiple references. Does each reference I fill it with stay persistent? Or am I amble to keep my script as-is with no issues?
If this
does make all of the references persistent, then I think I need to change my script. This would mean that I need to fill my referencealias with the associated quest alias. How would I do this? referencealias's are kind of weird and confusing to me to be honest. I don't know how I'd be able to "assign it" to the quest alias, and then fill it without messing that up.