CallFunctionNextFrame

From GECK
Jump to: navigation, search


A function added by the SUP NVSE Plugin.

Description

Calls specified UDF a specified number of frames later. The same UDF can be set to be called back multiple times.

Syntax

[help]
reference.CallFunctionNextFrame UDF:script inFrames:int iRemoveOnGameLoad:int

Example

CallFunctionNextFrame myUDF

Will Call function 1 frame later.

CallFunctionNextFrame myUDF 10

Will Call function 10 frames later.

ActorRef.CallFunctionNextFrame myUDF 10

Will Call function 10 frames later, function will be called by ActorRef(MyActor.call MyUDF).

CallFunctionNextFrame myUDF 500 0 0

Will Call function in 500 frames even if game is reloaded by that time.

Notes

  • inFrames parameter has Minimum value of 1, Maximum value of 1000. If the optional parameter is not passed it will default to 1.
  • UDF should take no arguments (empty braces {}).
  • RemoveOnGameLoad parameter is 1 by default. If this Parameter is true, then queued UDF call will be deleted if game is loaded before frame count is reached.
  • Be careful when calling this function on non-persistent references because they might not be available N frames later if they are unloaded.

See Also