Difference between revisions of "GetQuest - Quest"
Jump to navigation
Jump to search
imported>CraftySentinel |
imported>CraftySentinel m (Spelling change) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
''' | '''Member of:''' [[Quest Script]] | ||
'''Type:''' [[:Category:SKSE|SKSE]] Global Function. | '''Type:''' [[:Category:SKSE|SKSE]] Global Function. | ||
Line 41: | Line 41: | ||
== See Also == | == See Also == | ||
*[[Quest Script]] | *[[Quest Script]] | ||
[[Category:Scripting]] | |||
[[Category:Papyrus]] | |||
[[Category:SKSE]] |
Latest revision as of 07:02, 2 November 2013
Member of: Quest Script
Type: SKSE Global Function.
Returns the quest of the specified editor id, or None if none match.
Syntax[edit | edit source]
Quest Function GetQuest(string editorId) global native
Parameters[edit | edit source]
editorId
- The editor id of the Quest you wish to get.
Return Value[edit | edit source]
The quest associated with the entered editorid, if no quest has the exact editor id this will return None.
Notes[edit | edit source]
- Quests do not have to be running to be collected.
- This can be a good alternative to using GetFormFromFile to return quests, or to check for a certain plugin to be present, as authors rarely change editor ids.
Examples[edit | edit source]
In this example a simple check is performed to check for Dragonborn.esm via a known quest:
;Check for a Dragonborn quest and implicitly cast the quest return to a boolean (None = False)
bool isDLC2Present = Quest.GetQuest("DLC2CultistAmbush")
If isDLC2Present
;Perform Logic dependent on Dragonborn being present.
Else ;If it is not installed only one other possibility.
Debug.Trace("Dragonborn.esm was not present.")
EndIf