Interface IRuntimeQuestFactory
- Namespace
- SkyrimForge.Quests
- Assembly
- SkyrimForge.dll
Creates quests that the journal lists, at runtime and without an .esp file.
public interface IRuntimeQuestFactory
Remarks
Each quest's progress is stored in the co-save and applied again after every load. Call members on the game's thread.
Methods
Create(string, string, IEnumerable<QuestStage>?, Type, IEnumerable<QuestScene>?, IEnumerable<QuestAlias>?, bool)
Creates a quest that the journal lists once it displays an objective.
IRuntimeQuest Create(string key, string name, IEnumerable<QuestStage>? stages = null, QUEST_DATA.Type type = Type.kSideQuest, IEnumerable<QuestScene>? scenes = null, IEnumerable<QuestAlias>? aliases = null, bool activeOnStart = false)
Parameters
keystringThe name the quest's progress is stored under, unique among this plugin's quests and the same in every version of the plugin.
namestringThe name the journal shows.
stagesIEnumerable<QuestStage>The stages SetAsync() sets.
typeQUEST_DATA.TypeThe journal's category for the quest.
scenesIEnumerable<QuestScene>The scenes Start(int) starts. A scene a stage starts is declared without being passed here.
aliasesIEnumerable<QuestAlias>The aliases no objective targets and no scene action uses, such as one that gives an actor a package or one written only as a token into text. An alias an objective targets or a scene action uses is declared without being passed here.
activeOnStartboolWhether the quest becomes the journal's active quest as it displays its first objective, including after RemoveFromJournalAndReset().
Returns
Remarks
Callable from a plugin's start, before the game has data or a save.
Exceptions
- ArgumentNullException
keyornameisnull.- FileNotFoundException
A scene line's fixed response specifies a voice file that does not exist.
- ArgumentException
This plugin created a quest with
keyalready, or two of the quest's stages or objectives share an index, or two of its aliases or scenes share a name, or a stage both completes and fails one objective, or completes or fails an objective created with no index that no stage displays, or a scene or phase sets a stage the quest does not declare, or an alias, a scene, a stage, or an objective belongs to another quest.