Compile a Script

13 November 2018

  • C10 - add the entity parameter and allow reading a script from the filesystem.

8 April 2017

  • Release 9.161 - added.
compilescript (Commands)
TypeCorrade progressive command
Commandcompilescript
DescriptionThe compilescript command compiles a script passed to the command as a string or reads a script from the filesystem and returns any reported syntax errors in case the compilation failed.
Permissionsinventory
Parametersgroup, password, entity
Last ChangesC10 - add the entity parameter and allow reading a script from the filesystem.

The compilescript command compiles a script passed to the command as a string or reads a script from the filesystem and returns any reported syntax errors in case the compilation failed.

Command Required Parameters Required Corrade Permissions Example
compilescript group, password, entity inventory
llInstantMessage(CORRADE,
    wasKeyValueEncode(
        [
            "command", "compilescript",
            "group", wasURLEscape(GROUP),
            "password", wasURLEscape(PASSWORD),
            "entity", "text",
            "data", wasURLEscape(
"default {
    state_entry() {
        llSay(0, \"yaaay\");
    }
}
"),
            "callback", wasURLEscape(URL)
        ]
    )
);
Parameter Possible Value Second Parameter Possible Value Description
entity text Compile a script passed to the data parameter and return the success status and any outstanding compilation errors.
file path The path to a file on the filesystem that Corrade runs on. Compiles a script from the filesystem and returns any outstanding compilation errors.
Optional Parameter Possible Value Description
mono True (default) or False Whether to compile the script to Mono.

Notes

  • When entity is set to text, the data value containing the script body should be escaped using wasURLEscape (or similar) to avoid collisions with reserved symbols - however, in case LSL is used to sent the commands, the quotation marks should be escaped such that they do not collide with the quotation marks of the script sending the command.
  • This command does not update any in-world script and is not able to create a script within the avatar's inventory. Instead the command can be used in various scenarios where Corrade is used as a script compiler for LSL scripts.
    • In order to create or update a script, please refer to the updatescript command,
    • In order to recompile a script within an in-world primitive, please refer to the recompilescript command.
    • In order to reset an in-world script, please refer to the scriptreset command.

secondlife/scripted_agents/corrade/api/commands/compilescript.txt ยท Last modified: 2023/08/03 01:38 by office

Access website using Tor Access website using i2p Wizardry and Steamworks PGP Key


For the contact, copyright, license, warranty and privacy terms for the usage of this website please see the contact, license, privacy, copyright.