> For the complete documentation index, see [llms.txt](https://code-after-sex.gitbook.io/script-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://code-after-sex.gitbook.io/script-documentation/cas-advanced-loading-screen/content.md).

# Content

config/content.lua of Advanced Loading Screen. News and patch notes, rules, keybinds, tips, music, the event poster, socials and the loading stage names.

Everything players read on the screen lives in `config/content.lua`. Text is shown as written; titles are set in a display font, so keep them short.

## Frontier News (`Config.News`)

```lua
{
    id = "n1",
    date = "OCT 12",
    category = "FEATURE",                 -- FEATURE, ECONOMY, FIX, EVENT ...
    title = "WEAPON AND BOW UPGRADES",
    summary = "Pelts, predators and a sharper blade.",
    body = "Gather pristine pelts with your bow ...",
    image = "assets/news/weapons.webp",   -- photo in the news room
    printImage = "assets/art/gazette_street.webp", -- optional engraving for the Gazette front page
    patch = "1.4",
    author = "BY THE GUNSMITH OF SILVER CREEK",
    isNew = true,                         -- counts in "N NEW SINCE YOUR LAST RIDE"
    changes = {
        { type = "added", text = "Three new bows with their own draw weight" },
        { type = "changed", text = "..." },
        { type = "fixed", text = "..." },
    },
    facts = { title = "AT THE GUNSMITH", subtitle = "...", icon = "revolver", rows = { { label = "NEW BOWS", value = "3" } } }, -- or nil
}
```

The first item is the featured story on Outlaw and the Gazette headline. Filters in the news room use the category: anything with "FIX" is a fix, "EVENT" an event, the rest features.

## The Code (`Config.Rules`)

```lua
Config.Rules = {
    amended = "OCT 12",
    appeals = "DISCORD.GG/SILVERCREEK",
    oath = "I have read the code of Silver Creek and I will ride by it.",
    chapters = {
        { title = "GENERAL", rules = {
            { title = "VALUE YOUR LIFE", text = "...", penalty = "WARNING", severity = 1 },
        } },
    },
}
```

`severity` 1 to 5 colours the penalty (1 gold, 2 paper, 3 or more red) and fills the severity bar. The first chapter's rules show on the Outlaw and Gazette plates. The oath is remembered on the player's PC until `amended` changes.

## Keybinds (`Config.Keys`)

```lua
{ id = "horse", label = "HORSE", icon = "horse", tip = "...", binds = {
    { key = "H", action = "Whistle for your horse", mode = "tap", detail = "..." },
} }
```

`icon`: `user`, `horse`, `ember`, `drop`, `chat`, `gear`, `keys`. `mode`: `tap`, `hold`, `double`. Key names match the keyboard map: letters, digits, `F1` to `F12`, `SHIFT`, `CTRL`, `ALT`, `SPACE`, `TAB`, `ENTER`, `ESC`, `CAPS`, `BACK`.

## Tips (`Config.Tips`)

```lua
{ key = "H", title = "A HORSE LEFT ALONE WILL WANDER.", text = "Hold H to whistle and your horse will come running." }
```

Tips rotate every 9 seconds; a click shows the next one.

## Music (`Config.Music`)

```lua
Config.Music = {
    defaults = { volume = 70, playOnStart = true, shuffle = false, ambience = true, ambienceVolume = 35, fadeOnSpawn = true },
    tracks = {
        { title = "DUST ON THE SADDLE", artist = "THE PRAIRIE BAND", src = "assets/audio/dust_on_the_saddle.ogg" },
    },
    ambience = "assets/audio/ambience.ogg",
}
```

Players change volume, shuffle, ambience and fade in the jukebox; their choices are saved on their PC. With no tracks the jukebox and the MUSIC button hide. `.ogg` and `.mp3` both work.

## The event poster (`Config.Event`)

```lua
Config.Event = { enabled = true, label = "TONIGHT", title = "NIGHT TRAIN ROBBERY", day = "SATURDAY", time = "21:00 CET", text = "..." }
```

## Socials (`Config.Socials`)

```lua
{ id = "discord", label = "DISCORD", url = "https://discord.gg/yourserver", caption = "JOIN THE POSSE" },
```

QR codes are generated from `url`. The first two become WANTED posters on the Territory plate; `discord` is also the Gazette telegraph ad.

## Stage names (`Config.Stages`)

The six loading stages are named three ways: `frontier` (Outlaw and Sundown), `places` and `placeText` (the Territory map stops) and `press` (the Gazette). `short` is used by the railroad loader.
