CompileScript(string, string, int, int)
From NWN Lexicon
Jump to navigationJump to searchCompile a script and place it in the server's CURRENTGAME: folder.
Parameters
- sScriptName
- The name of the script to compile.
- sScriptData
- The script.
- bWrapIntoMain
- if TRUE, the "void main() {}" wrapper will be added to the script for you.
- bGenerateNDB
- if TRUE, the .ndb debug file will be generated for the script.
Description
Compile a script and place it in the server's CURRENTGAME: folder.
Note: Scripts will persist for as long as the module is running.
SinglePlayer / Saves: Scripts that overwrite existing module scripts will persist to the save file. New scripts, unknown to the module, will have to be re-compiled on module load when loading a save. Returns "" on success or the error on failure.
Returns "" on success or the error on failure.
Remarks
This can be used to dynamically compile a brand new script, which may be useful for advanced cases where a new dynamic script contents is required.
Version
This function was added in 1.87.8193.35 of NWN:EE.
Example
See Also
functions: |
author: Shadguy