LogoLogo
HomeGithub
2.0
2.0
  • Home
  • Scripting Reference
    • Introduction to Resources
    • Resource Manifest
    • Creating your first script
      • In JavaScript
      • In Python
      • In Lua
      • In Java
    • Events
  • API Guides
    • Terminology
    • Release Policy
  • Silica
    • Silica FAQ
Powered by GitBook
On this page

Was this helpful?

  1. Scripting Reference

Introduction to Resources

Servers run on a collection of resources. A resource is a collection of files - such as client scripts, server scripts, and assets - that can be started, stopped and restarted at any time.

PreviousHomeNextResource Manifest

Last updated 3 years ago

Was this helpful?

Resource Directories

In the server, resources are loaded from a folder called resources/ in the server data directory. Any folder in the resources/ folder is parsed as a resource, except folders between [brackets] which are categories, which can contain multiple resource folders.

Each resource folder also has to contain a called manifest.toml to be correctly parsed as a resource.

See this example directory tree:

server
└── resources
    ├── [category]
    │   ├── [another]
    │   │   └── resource-2
    │   │       └── manifest.toml
    │   └── resource-1
    │       └── manifest.toml
    └── main
        └── manifest.toml

In this tree, the following resources exist:

  • main

  • resource-1

  • resource-2

resource manifest reference
Resource Manifest
In JavaScript