# Set-Up

## Installation

Once you've decided to use Skript, the first step is to install it on your server. To install Skript, place the `.jar` file in your server's plugins folder.

{% hint style="info" %}
The server host Aternos does not allow you to upload files. Aternos does not support new Skript versions and is not recommended.
{% endhint %}

{% hint style="info" %}
The `.jar` file should have a name following this format: `Skript-%version%.jar`, where `%version%` is replaced with numbers. If you were downloading version 8.0.8, the file would be named `Skript-8.0.8.jar`. You can rename this file (although there is no reason to), but make sure you do not modify the file extension!

The latest release of Skript can be downloaded off of the GitHub page: <https://github.com/SkriptLang/Skript/releases/>.

If you do not want to install the latest version of Skript (which is not recommended!), join the [skUnity Discord server](https://discord.gg/skript), head to the `#bot-palace` channel, and use the `/download` command. An embed will provide links to Skript versions for pre-1.13 or 1.8 Minecraft.

{% hint style="warning" %}
Note that installing **outdated** versions (and addons) means features, components, and compatibility will be different or even non-existent, and possibly buggy or completely broken. These are not recommended or endorsed. Use at your own risk.
{% endhint %}
{% endhint %}

Once the `.jar` file is in the plugins folder, restart your server. **Do not attempt to use a `/reload` command, it will not work correctly.** If everything went smoothly, your plugins folder should have a new subfolder titled "Skript". This is where everything relating to Skript will be stored.

{% hint style="warning" %}
When updating Skript versions, replace the `.jar` **ONLY**. Preserve the Skript folder. Deleting the Skript folder will wipe your configuration settings, as well as deleting saved variables and all of your scripts!
{% endhint %}

Do your best to keep Skript (and any addons) up-to-date to ensure everything works smoothly.

{% hint style="info" %}
Note that sometimes new releases may contain bugs for the first while. If you encounter one, feel free to report it on the GitHub page.
{% endhint %}

***

## Creating & organising scripts

The only thing in the Skript folder you need to touch right now is the subfolder named "scripts". This will house all your scripts, where your code will be written. For files to be recognised as scripts, they must have the `.sk` file extension.

Once you start creating more scripts, you'll need a system to organise them with. Properly sorting your scripts will let you quickly find sections of code to update or remove, lower parse times, and just simply be neater.

Sub-folders (created folders within the scripts folder) can also be used to sort scripts. For example, instead of storing custom items in `Skript/scripts`, store them in `Skript/scripts/customItems`. Folders can also be used to reload and enable or disable all held scripts at once.

Inside the scripts folder, create a new file named `welcome.sk`. This is the script this category will walk you through creating.

***

## Script maintenance

Once Skript is installed, the `/skript` command (with the alias `/sk`) should be useable in-game and through the console. This is how you will be able to reload, enable, and disable scripts.

Once you've written some code, (which will be on the next page), save the script file, and then use the `/skript reload %script name%` command.\
-> `%script name%` should be replaced with the file name, such as `/skript reload welcome.sk`.

{% hint style="info" %}
Want to disable a script without deleting it? Add a hyphen (`-`) to the start of the file name to disable it. The `/skript (enable|disable) %script name%` command can also be used.
{% endhint %}

{% hint style="info" %}
You should be creating more scripts instead of adding new code to the same file. Related code may be located in the same file, but a completely different project should be in its own file.

This allows you to jump into a (smaller) script and start editing code rather than having to spend what feels like an eternity scrolling through one massive file. Having separate files also allows you to reload them separately, which is much easier on your server than reloading and parsing one massive file all the time.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://x8ight.gitbook.io/syntask/beginners-corner/set-up.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
