π» Installation
Install devhub_lib
Download and install the required library and configure it according to your framework.
Download https://github.com/DEVHUB-GG/devhub_lib or use command
git clone https://github.com/DEVHUB-GG/devhub_lib.gitInstall resources from keymaster
Download the GYM V2 files from keymaster. The product ships three resources:
| Resource | What it is |
|---|---|
devhub_gym2 | The script itself. |
devhub_gym2_assets | Streamed gym props (the machines you place in the creator). |
devhub_gym2_assets_anim | Streamed animation props used by the exercises. |
All three are required. The two asset resources contain no code, only stream files.
Add the supplement items to your inventory
The resource ships an items/ folder with an items.lua file and the item images.
- Open
items/items.lua. It contains a ready-made block for qb-core (qb-core/shared/items.lua) and one for ox_inventory (ox_inventory/data/items.lua). Copy the block that matches your inventory. On ESX with a databaseitemstable, add the eight item names by hand. - Copy every
.pngfromitems/imgs/into your inventory's image folder (for exampleqb-inventory/html/imagesorox_inventory/web/images).
The eight supplements are gym_iron_surge, gym_pump_juice, gym_ripped_recovery, gym_hardcore_stack, gym_beast_mode_fuel, gym_apex_predator, gym_american_mass and gym_king_of_iron.
An item that does not exist on your server can never be sold or used. If you rename one, rename it in the Items page of the Gym Creator too, and in the gym's Warehouse if you run the business module.
Database
You do not have to do anything here. The script creates its own tables and inserts the default data the first time it starts.
If you prefer to run it yourself, import sql/install.sql. It is safe to run on a fresh or an existing database: every table uses CREATE TABLE IF NOT EXISTS and every seed row is only inserted when it is not already there, so running it twice never duplicates or overwrites anything.
The install creates a ready-to-play gym at Vespucci Beach with equipment, a map blip and interaction points already placed, so you can walk in and train the moment the server boots.
Start resources
Move the files to the resources folder on your server and add the following lines to your server.cfg in the correct order:
ensure devhub_lib
ensure devhub_gym2_assets
ensure devhub_gym2_assets_anim
ensure devhub_gym2If you also run devhub_skillTree, start it before devhub_gym2.
Restart your server
Open the creator in game
Log in as an admin and type /admindevhub, then pick Gym and Gym Creator.
Everything from here on is done in the interface. See gym-creator.
DO NOT CHANGE RESOURCE NAME
Who can open the admin menu
The Gym Creator and the business admin panel are gated by the ACE permission command, the same one the DevHub library uses everywhere. Give it to your admin group in server.cfg:
add_ace group.admin command allow
add_principal identifier.license:YOUR_LICENSE group.adminA player without that permission cannot open the creator, and the server rejects every creator action even if the interface is forced open.
Optional: an MLO gym instead of the default one
The resource ships ready-made layouts for five popular gym MLOs in maps_plug_and_play/. Each one is a small SQL file plus the map files it has to replace, so the whole gym appears already built inside that MLO.
Optional: the business module
Gym V2 can run as a player-owned business (employees, wages, a warehouse, a shop, taxes, company levels). That part is a separate DevHub license and is off by default. Nothing else in the script depends on it.
Businesses Devhub Lib Needed For Each Script Download Purchased Assets