Agency Docs
QBESXStandalone

Agency-Housing 安装

基于数据库的 FiveM 住房系统,自动识别 ESX、QBCore 与 QBox。房屋在游戏内通过液态玻璃风格的创建界面完成,而不是写配置文件:在你所站的位置放置入口,从空中标出地界,选择 18.

v1.79.0付费5 页面

01安装

  1. 1将 sql/install.sql 导入你的数据库
  2. 2Extract Agency-Housing into your resources folder
  3. 3Install PolyZone if you do not have it yet
  4. 4Add ensure PolyZone and ensure Agency-Housing to server.cfg, after oxmysql
  5. 5Optional: add_ace group.admin agency.housing allow to grant creator access

02依赖项

  • oxmysql(必需)
  • PolyZone (required, property borders are built from it)
  • ESX / QBCore / QBox (optional, runs standalone with ACE permissions)

03SQL 文件

在启动资源之前,将此SQL文件导入数据库:

-- ===================================================================== -- Agency Housing - Database -- -- Two tables. `agency_houses` holds the houses themselves, one row each. -- `agency_house_inside` remembers who was inside which house, so a player -- who disconnects indoors is put back where they were on the next join -- instead of on the pavement outside. -- -- The resource adds later columns by itself on every start -- (ALTER TABLE ... ADD COLUMN IF NOT EXISTS), so an existing install only -- ever needs the two CREATE statements below. Running this file twice is -- harmless: every statement is IF NOT EXISTS. -- -- The table name follows Config.TableName. Rename it here too if you -- change it there. -- ===================================================================== CREATE TABLE IF NOT EXISTS `agency_houses` ( `id` INT AUTO_INCREMENT PRIMARY KEY, -- What the house is and what it costs. `name` VARCHAR(64) NOT NULL, `shell` VARCHAR(64) DEFAULT NULL, -- interior | shell | mlo. Decides whether the house is entered through a -- marker or walked into through its own front door. `kind` VARCHAR(16) NOT NULL DEFAULT interior, `price` INT NOT NULL DEFAULT 0, -- Positions, each stored as JSON. `interior` is only set when the house -- carries its own recorded coordinates; otherwise the shell entry in -- config.lua applies. `entrance` LONGTEXT DEFAULT NULL, `interior` LONGTEXT DEFAULT NULL, `exit_point` LONGTEXT DEFAULT NULL, `stash_point` LONGTEXT DEFAULT NULL, `wardrobe_point` LONGTEXT DEFAULT NULL, `garage` LONGTEXT DEFAULT NULL, -- The property border: the corners walked in the creator, handed to -- PolyZone on start. Required for houses created since borders exist. `zone` LONGTEXT DEFAULT NULL, -- The MLO doors this house owns, for kind = mlo. `doors` LONGTEXT DEFAULT NULL, -- Per-house map blip override: {"name":"Villa","color":5,"scale":0.9} -- Any field may be absent; what is missing follows the state styles in -- Config.Blips (for sale / owned / keyholder). `blip` LONGTEXT DEFAULT NULL, -- Ownership. `owner` is the framework identifier, NULL while the house -- is unsold. `owner` VARCHAR(64) DEFAULT NULL, `owner_name` VARCHAR(64) DEFAULT NULL, `keys` LONGTEXT DEFAULT NULL, -- State flags. `locked` TINYINT(1) NOT NULL DEFAULT 1, `for_sale` TINYINT(1) NOT NULL DEFAULT 1, `show_blip` TINYINT(1) NOT NULL DEFAULT 1, -- What the owner did with the place. `furniture` LONGTEXT DEFAULT NULL, `upgrades` LONGTEXT DEFAULT NULL, `cameras` LONGTEXT DEFAULT NULL, `created_by` VARCHAR(64) DEFAULT NULL, INDEX `owner` (`owner`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; -- Who is inside which house. One row per player at most, hence the -- identifier as primary key: the resource writes with ON DUPLICATE KEY. CREATE TABLE IF NOT EXISTS `agency_house_inside` ( `identifier` VARCHAR(64) NOT NULL PRIMARY KEY, `house_id` INT NOT NULL, `since` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, INDEX `house_id` (`house_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

看完本页仍未解决?接下来由我们的支持团队接手。