QBESX
Agency-Vending التثبيت
سكربت لآلات البيع مع 4 أنواع من الآلات (مشروبات غازية، قهوة، وجبات خفيفة، مبرّد ماء) وكشف تلقائي لمجسّمات البيع في GTA.
v1.1.0مدفوع4 صفحات

01التثبيت
- 1انسخ agency-vending إلى مجلد resources
- 2أضف ensure agency-vending إلى server.cfg
- 3نفّذ installation/database.sql في قاعدة البيانات
- 4سجّل العناصر حسب إطار العمل (ESX/QBCore/ox_inventory)
- 5انسخ صور الحقيبة من installation/inventory-images/
- 6اضبط config.lua
02المتطلبات
oxmysql (مطلوب)ESX أو QBCore (اختياري، يعمل مستقلًا أيضًا)ox_target / qb-target (اختياري)agency-phone (اختياري، لأجل AgencyPay)
03ملف SQL
استورد ملف SQL هذا إلى قاعدة بياناتك قبل تشغيل المورد:
-- =============================================
-- Agency Vending - Database Setup
-- =============================================
-- Execute this SQL in your database
-- The tables are required for the player-owned machines system
--
-- NOTE: The tables are also created automatically on first
-- resource start. This SQL is optional for manual setup.
-- =============================================
CREATE TABLE IF NOT EXISTS `agency_vending_machines` (
`id` INT AUTO_INCREMENT PRIMARY KEY,
`owner` VARCHAR(50) NOT NULL,
`type` VARCHAR(50) NOT NULL,
`coords` TEXT NOT NULL,
`heading` FLOAT NOT NULL DEFAULT 0,
`earnings` FLOAT NOT NULL DEFAULT 0
);
CREATE TABLE IF NOT EXISTS `agency_vending_stock` (
`machine_id` INT NOT NULL,
`slot` VARCHAR(10) NOT NULL,
`stock` INT NOT NULL DEFAULT 0,
`price` FLOAT NOT NULL DEFAULT 0,
PRIMARY KEY (`machine_id`, `slot`)
);
CREATE TABLE IF NOT EXISTS `agency_vending_spawned` (
`id` INT AUTO_INCREMENT PRIMARY KEY,
`type` VARCHAR(50) NOT NULL,
`model` VARCHAR(100) NOT NULL,
`coords` TEXT NOT NULL,
`heading` FLOAT NOT NULL DEFAULT 0,
`spawned_by` VARCHAR(50) NOT NULL,
`created_at` TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);