The plugin architecture doesn't really allow for that. You could do it, by doing something like:
OnOpen()
createtrigger ...
createtrigger ...
... etc.
in the main script file, but that is going to delay the client, since instead of just parsing the world file, or a plugin, its going to have to run the Lua/Jscript code *first*, to build the list of triggers, and other stuff (and its a lot harder to edit them, not the least because the functions for creating them don't directly support all options, and if you do it the easy way, with ParseXML, you *still* have to use XML). XML isn't that hard, and Mushclient has a plugin builder, so you can create all your script, aliases, triggers, and so on, then use the plugin builder to place all of them into a plugin. I.e., you don't have to write one manually. Editing it after it exists is still not as easy as I would like, but creation can be done by creating all the needed features, testing them, then simply exporting those to a plugin.
Note however, if you don't use plugins, then it still does have the old system. Under that system you only have access to a limited number of functions from the client, which you can see under the "scripting" settings, but all triggers, aliases and timers are saved in the "world" file, while your script is kept in a separate .lua or .js file. The only limitation is, as I said, *most* special callbacks are not supported in the old system. However, you are probably not going to be using any of those in the short term, in most cases.
|