SetJohnnyOnCompleteQuestEventHandler

From GECK
Jump to: navigation, search


A function added by the JohnnyGuitar NVSE Plugin.

Description

Sets/removes the specified UDF Script as a handler that will be invoked when a specified Quest (or any Quest) is completed. Formlists are also accepted as filters. When invoked, the script is passed with a single argument: a Quest that was completed.

Syntax

[help]
SetJohnnyOnCompleteQuestEventHandler setORremove:1/0 handlerScript:ref flag:int quest:filter 

Or:

SetOnCompleteQuestEventHandler setORremove:1/0 handlerScript:ref flag:int quest:filter

Example

SetJohnnyOnCompleteQuestEventHandler 1 OnCompleteQuestUDF 0 MyQuest

Sets the OnCompleteQuestUDF script as a handler to be invoked when MyQuest is completed.

SetJohnnyOnCompleteQuestEventHandler 0 OnCompleteQuestUDF 0 MyQuest

Removes the OnCompleteQuestUDF script as a handler of the above.

Handler Script

A skeleton handler script for this event:

scn OnCompleteQuestUDF

ref rQuest

begin Function {rQuest} 

...

end

Notes

  • Flag argument is reserved for future use and should always be 0.

See Also