I wonder
- Is the premise wrong? That is, to contradict it, is there virtually always an alternative to modifying base scripts such as Actor.psc, ObjectReference.psc, etc.?
- If not, what system could we device to render base-script edits compatible?
- What mods do you know which presently edit base scripts?
Spoiler
Synopsis in place, I have to admit - I have never before written a mod for TES; I may be greatly mistaken in this topic and if so, I apologize for jumping to conclusions.
My own motivation for this post was a dialogue-driven disposition system for Skyrim with multiple variables (affection, respect etc.). To this end, I aimed to add to every NPC a number of ActorValues accessible through in particular dialogues. Memory concerns besides the topic, I researched thoroughly for a way to achieve this and eventually gave up in lieu of modifying Actor.psc directly. This worked splendidly but I could find no apparent way to do so while maintaining compatibility with other scripts taking the same approach, unless we coordinate a system. Unfortunately you cannot `alias' a class. How would you do this?
For completeness sake, the (efficient) approaches I've so far seen in scripts modifying objects universally, e.g., all NPC's, guards, books, or the like, exploit one of the following four methods. Please correct me if you've seen more.
For those who wonder what I mean by modifying `base scripts': if you download the Creation Kit, you will find Actor, ObjectReference, Book, and other base Papyrus classes in the Creation Kit (Gameplay>Papyrus Script Manager), as well as text files in the/scripts/source directory which may be compiled to pex files with the papyrus compiler. Modifying these scripts indeed affect all in-game objects instantiating these classes or extending classes thereof.
Enough blabbering. It seems to me that there is sometimes no other viable option but to modify base scripts. Am I wrong and if not, how can we do this while maintaining script compatibility?
Thanks for reading.
Synopsis in place, I have to admit - I have never before written a mod for TES; I may be greatly mistaken in this topic and if so, I apologize for jumping to conclusions.
My own motivation for this post was a dialogue-driven disposition system for Skyrim with multiple variables (affection, respect etc.). To this end, I aimed to add to every NPC a number of ActorValues accessible through in particular dialogues. Memory concerns besides the topic, I researched thoroughly for a way to achieve this and eventually gave up in lieu of modifying Actor.psc directly. This worked splendidly but I could find no apparent way to do so while maintaining compatibility with other scripts taking the same approach, unless we coordinate a system. Unfortunately you cannot `alias' a class. How would you do this?
For completeness sake, the (efficient) approaches I've so far seen in scripts modifying objects universally, e.g., all NPC's, guards, books, or the like, exploit one of the following four methods. Please correct me if you've seen more.
- Quests processing: possibly through aliases, one can run a script repeatedly on a set of objects, but as far as I'm aware, it does not offer efficient and persistent object-specific variables.
- Active (magic) effects: attaches to an actor and permits adding new variables as well as to process actor events. However, I know of no (simple) way to make newly-added properties accessible in universal dialogues. (Granted, one could force an event on the magic effect which causes it to store its variables in global properties, modify the same, and cause a new event to store them back.) Might also be feasible if SKSE were to provide additional enumeration methods.
- ScriptDragon: also runs continuously and permits new variables. With e.g. hashes, also object-specific ones. However, I can not figure out how to hook such variables up to e.g. dialogues.
- Attach an actor script to every X: does not work with X's added by new mods, causes incompatibilities, and involves a ton of work.
For those who wonder what I mean by modifying `base scripts': if you download the Creation Kit, you will find Actor, ObjectReference, Book, and other base Papyrus classes in the Creation Kit (Gameplay>Papyrus Script Manager), as well as text files in the
Enough blabbering. It seems to me that there is sometimes no other viable option but to modify base scripts. Am I wrong and if not, how can we do this while maintaining script compatibility?
Thanks for reading.
http://forums.nexusmods.com/index.php?/topic/632637-editting-papyrus-base-scripts-actorpsc-objectreferencepsc-etc