I've published a needs mod and am trying to improve its compatibility. For water sources in this mod, I made an activator with the vanilla nord well mesh and manually deleted and replaced each static well with the activator in the CS. The results are fine, but I can't help but wonder if it would be possible to dynamically replace each well using scripting at runtime, which would be a much more elegant solution for new lands mods like Tamriel Rebuilt and make the mod more compatible with town and settlement mods that move assets around in general. However, I have no idea how to implement this idea or even if it's entirely possible.
A few old forum threads I found...
http://creationkitten.tumblr.com/post/96604189758/statics-and-activators
http://www.gamesas.com/repairing-the-cogs-morrowind-t3063-175.html
http://www.mwmythicmods.com/Archives/CS/Comprehensive%20Animation%20for%20Morrowind%20-%20The%20How-To%20Thread.htm
http://www.fliggerty.com/phpBB3/viewtopic.php?f=22&t=4636
...seem to suggest that it's possible to reference and manipulate statics using scripts on other objects, possibly using MWSE, which is already required for my mod. However, I can't seem to find any information on how to declare or interact with objects in scripts that aren't directly attached to them.
Ideally, I would need to detect the wells in a loaded cell, get their XYZ coordinates and rotations, either disable/delete or offset them underneath the landscape, then place a scripted activator well in the original position.
I suspect this isn't possible via global script, but I was wondering if it would be possible to attach a local script to an item like a bucket that the player would carry around and manipulate the wells through a local script attached to such an object.
Does anyone know if this is possible, how to script it if so, or of any other mods that do something similar I could look to for a reference?
Thanks much!