

Do not modify them with xmlSaveFile, FileSave etc. Files listed in the meta.xml should be considered read-only by your scripts.If the resource does any file saving, the file names used should not be listed in the meta.xml.This allows directories to be used for testing and developing of maps/scripts while zip files used by end-users. In the case of both existing, the directory has precedence over the zip file, as such files can be placed in the directory to over-ride the files in the zip file. Mods/deathmatch/resources/ (for dedicated server installations)Įach resource can have a zip file, a directory or both. Server/mods/deathmatch/resources/ (if you've installed your server with the client) Resource files can either be stored in a zip or a directory. If a resource is included more than once, the same instance will be used by each resource that includes it. They can also read and write to other resources but must have ACL access.Įach resource can only be loaded once, the server will ensure this. Scripts are able to read and write to their own resource folder with functions such as xmlCreateFile and fileCreate.

Scripts sent to clients are started as soon as all the scripts have been downloaded. This will enable other resources to fire this function using the call scripting function. The best way to communicate with other resources is by using the export tag and exporting a function. This means that variables are not shared with other resources. This contains every script in the resource. In other words, if your resource is dependent on another, you can include it so that the other resource is started first.Įach resource has its own virtual machine (VM). The include tag specifies other resources that should be started before this resource is started. Script/type, Config/type, and File/type attributes specify if the script/resource should be sent to clients or not, and defaults to "server". While a CTF map may have a meta.xml that looks like: The following is an example that covers every option there is, your metafiles can have as many or as few of these tags as you require: It describes exactly what files in the resource should be used, and how. The Metafile is the core of each the resource.
