STG ScriptsDocumentation
Tower Blocks

Installation

Install STG Tower Blocks on your FiveM server in six steps, including the item for each inventory and the anticheat prop whitelist.

Tower Blocks

STG Tower Blocks

ESXQBCoreQBOX
View in store

Download the script

Sign in to the Cfx.re portal with the account you used at checkout and download stg-towerblocks from Granted Assets.

Move the resource

Extract the zip and place the stg-towerblocks folder inside the [STG] category folder in your resources directory.

resources/
└── [STG]/
    ├── stg_lib/
    └── stg-towerblocks/

Install the dependencies

Tower Blocks needs ox_lib, stg_lib and a target resource, ox_target or qb-target. Skip this step if your server already runs them.

Add the item

Players set up a tower with the stg_towerblocks item. The item is taken when the tower is built and given back when the owner packs it up. Add it to your inventory and copy stg_towerblocks.png from [SETUP]/item-images/ into your inventory's image folder, for example ox_inventory/web/images/ or qb-inventory/html/images/.

INSERT INTO items (name, label)
VALUES
    ('stg_towerblocks', 'Tower Blocks');

Add this to qb-core/shared/items.lua:

['stg_towerblocks'] = { name = 'stg_towerblocks', label = 'Tower Blocks', weight = 0, type = 'item', image = 'stg_towerblocks.png', unique = false, useable = true, shouldClose = true, description = 'Tower Blocks Set' },

Add this to ox_inventory/data/items.lua. The client.event line is what starts the tower placement, so keep it.

['stg_towerblocks'] = {
    label = 'Tower Blocks',
    weight = 0,
    stack = false,
    close = true,
    description = 'Tower Blocks Set',
    client = {
        event = 'stg-towerblocks:client:startPlacement'
    }
},

Whitelist the prop in your anticheat

Each tower is built from separate networked props, 54 with the default 18 layers. Some anticheats read this as prop spam and delete them. Add this model to your anticheat's prop or object whitelist:

stg_towerblocks

Start the script

Make sure [STG] starts after your framework, ox_lib and your target resource in server.cfg:

ensure ox_lib
# your framework: es_extended, qb-core or qbx_core
# your target: ox_target or qb-target
ensure stg_lib
ensure [STG]

Then restart the whole server.

Nothing happens or the console shows an error? See Common Errors.

Next steps

Still having trouble?

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

Get help on Discord

On this page