STG ScriptsDocumentation
Maple Syrup

Configuration

Every option in STG Maple Syrup shared/config.lua, from the job lock and market to the forest zone, firewood, taps, evaporator and notifications.

All settings live in stg-maplesyrup/shared/config.lua. The file stays editable in the escrow version. Restart the resource after a change.

Language

Config.Language = 'en'

Available: en, de, fr, es, pt, it, nl, pl, sv, no, fi, cs, ar, he, jp, ko, zh. To change a text, edit the matching file in stg-maplesyrup/locales/. The item descriptions on the market screen come from these files too, for example stg_maple_drill_description.

Job lock

Config.RequiredJob = {
    Active = false,
    Job = 'maple',
}

Prop

Type

Market

Config.Market = {
    Coords = vec3(-567.35, 5253.21, 70.47),
    InteractDistance = 2.0,
    Ped = {
        Model = 'a_m_m_hillbilly_01',
        Heading = 90.0,
    },
    MaxPerItem = 50,
    Blip = {
        Enabled = true,
        Sprite = 478,
        Color = 47,
        Scale = 0.8,
    },
    Items = {
        { name = 'stg_maple_evaporator', label = 'Evaporator', price = 750 },
        { name = 'stg_maple_drill', label = 'Hand Drill', price = 150 },
        { name = 'stg_maple_tap', label = 'Maple Tap', price = 15 },
        { name = 'stg_maple_bucket', label = 'Sap Bucket', price = 25 },
        { name = 'stg_maple_wood', label = 'Firewood', price = 5 },
        { name = 'stg_maple_bottle', label = 'Empty Bottle', price = 3 },
    },
    SellItems = {
        { name = 'stg_maple_syrup', label = 'Maple Syrup', price = 100 },
    },
}

The market sits at the Paleto Bay sawmill by default. Players walk up to the shopkeeper and open a screen with a Buy and a Sell tab, and pay or get paid in cash or to the bank.

Prop

Type

Each entry in Items and SellItems has three values:

ValueMeaning
nameItem name, as registered in your inventory.
labelName shown on the market screen.
pricePrice for one item.

The picture on the market screen is loaded from web/assets/img/items/<name>.png.

Forest zone

Config.Zone = {
    Center = vec3(-620.0, 5420.0, 55.0),
    Radius = 220.0,
    Blip = true,
    RemoveMountainLions = true,
}

The zone is the only area where taps and evaporators can be placed, and where firewood spawns. The default covers the Paleto Forest.

Prop

Type

Firewood

Config.Wood = {
    Count = 70,
    Amount = 1,
    Respawn = 300,
}

Prop

Type

Tapping

Config.Tapping = {
    FillTime = 180,
    SapPerBucket = 5,
    MaxTaps = 10,
    MinSpacing = 1.5,
}

Placing a tap takes one stg_maple_tap and one stg_maple_bucket. The hand drill is kept. Removing a tap gives back the tap, the bucket and any sap inside it.

Prop

Type

Evaporator

Config.Evaporator = {
    FuelItem = 'stg_maple_wood',
    FuelAmount = 3,
    SapPerBatch = 10,
    BottlesPerBatch = 2,
    BoilTime = 60,
    CollectWindow = 120,
    MaxPerPlayer = 1,
}

Using the stg_maple_evaporator item lets the player place it on the ground inside the zone. Starting a batch takes the sap and the fuel, and collecting the syrup takes the empty bottles. An evaporator cannot be packed up while it is boiling.

Prop

Type

When a player disconnects or the resource stops, their taps and evaporators are removed from the world and the items go back to them on their next join. Taps return the tap, the bucket and the sap inside. An evaporator returns itself, plus the sap of a batch that had not burnt yet.

Notifications

Config.Functions = {
    Notify = function(type, message)
        lib.notify({ type = type, description = message })
    end,
}
  • Notify: replace the body to use your own notification system. type is success or error.

Still having trouble?

Open a ticket on our Discord. Our team answers around 15 hours a day.

Get help on Discord

On this page