update sc-script docs based on code spelunking

develop
myk002 2022-07-18 11:10:56 -07:00
parent 8173f6dd02
commit 019856883b
No known key found for this signature in database
GPG Key ID: 8A39CA0FA0C16E78
1 changed files with 14 additions and 3 deletions

@ -2,8 +2,19 @@ sc-script
--------- ---------
Runs commands when game state changes occur. This is similar to the static Runs commands when game state changes occur. This is similar to the static
`init-files` but can be set dynamically. `init-files` but is slightly more flexible since it can be set dynamically.
Usage:: Usage:
sc-script - ``sc-script [help]``
Show the list of valid event names.
- ``sc-script list [<event>]``
List the currently registered files for all events or the specified event.
- ``sc-script add|remove <event> <file> [<file> ...]``
Register or unregister a file to be run for the specified event.
Examples:
- ``sc-script add SC_MAP_LOADED spawn_extra_monsters.init``
Registers the ``spawn_extra_monsters.init`` file to be run whenever a new map
is loaded.