Turn simple locations into player‑owned, passive income businesses.
coLdStudio Passive Business System adds a lightweight but powerful business layer on top of QBCore, where admins place businesses on the map and players buy them to earn automatic hourly payouts.
🔥 Main Features
-
Player‑owned passive businesses
Players can buy configured businesses around the map and receive automatic hourly income directly into their bank account. -
Map integration (blips, markers, 3D text)
Each business has its own blip, world marker and 3D text showing ID, name, owner, price and earnings per hour. -
Admin business tools (commands)
Staff can create, edit, delete, clear and refresh businesses entirely through server commands, with QBCore permission checks. -
Safe ownership system
Owners are stored bycitizenidfrom the QBCore players table, fully compatible with the default framework. -
Config‑driven behavior
Staff permissions, notifications, okokChat usage and payout timing are all controlled fromconfig.lua, without touching core code. -
Optimized & escrow‑ready
Client only handles blips/markers/text; all logic is server‑side and structured to be protected via CFX Asset Escrow with config + SQL left open.
⚙️ Configuration
config.lua is fully open:
-
Config.StaffPermission
QBCore permission required for admin/business management features (e.g.admin,god). -
Config.Notify
Server‑side notification wrapper (by default usesQBCore:Notify, but you can swap to your own system). -
Config.Okok.Enabled/Config.Okok.Event
Toggle okokChat support and set the event name for styled chat messages. -
Config.OkokStyles
Pre‑defined styles for info, success, warning and error messages used by the script. -
Config.PayoutCheckInterval
How often the script checks if a payout should be made (in seconds). -
Config.PayoutInterval
How often each business pays its owner (in seconds, default 1 hour).
Everything that a server owner needs to tweak is centralized in config.lua, while the core logic stays untouched.
📦 Requirements
-
qb-core(QBCore framework). -
oxmysql(MySQL resource used for all database queries). - (Optional)
okokChatif you want styled informational messages in chat.
🗄️ Database
The script uses its own dedicated table:
-
businesses
Stores all configured businesses:-
id– auto‑increment ID -
name– business name -
description– short description shown in 3D text -
price– purchase price (taken from player bank) -
earnings– hourly income for the owner -
position– JSON with x, y, z position -
owner–citizenidof the owner (empty if unowned) -
last_payout– Unix timestamp of last payment
-
SQL file sql/businesses.sql is included for quick import.
🧰 Commands
All commands are protected by Config.StaffPermission.
-
/refreshbusiness
Re‑syncs all businesses to every online player. -
/createbusiness [name] [price] [earnings_per_hour] [short_description]
Creates a new business at your current position with the given settings. -
/deletebusiness [id]
Deletes a specific business by ID. -
/clearbusinesses
Deletes all businesses and resets the auto‑increment ID back to 1. -
/editbusiness [id] [name/price/earnings/description/owner] [value]
Edits a single field of a business (useowner noneto clear ownership).
Player side:
- Walk into the marker to see the business info and press E to buy if it is unowned and you have enough bank money.
🔧 Installation
- Place the resource in your
resourcesfolder (e.g.coldstudio-business). - Import
sql/businesses.sqlinto your database. - Configure
config.lua(staff permission, notifications, okokChat, payout settings). - Ensure
qb-coreandoxmysqlstart before this resource. - Add
ensure coldstudio-businessto yourserver.cfgand restart your server.
🔒 Asset Escrow
- Sold as a CFX Asset Escrow resource.
- The following files remain open:
-
config.lua -
sql/businesses.sql -
README.md
-
- Client and server logic are protected to prevent leaks while keeping all important configuration fully accessible to server owners.
🛠️ Support
Support via Discord: https://discord.gg/aSc68qzPHj
When opening a ticket, please include:
- Your FiveM build and QBCore version.
- Any server/client console errors.
- Your
config.luachanges (or screenshots).