Installation
1. Download resource
Download the purchased resource from keymaster - the official site of fivem with purchased resources.
2. Database
Add the required sql file to your database
1
Main Table:
If you use any of our resources that also use the vms_business
table, you can skip the section Main Table
CREATE TABLE IF NOT EXISTS `vms_business` (
`id` varchar(50) NOT NULL DEFAULT '',
`type` varchar(50) NOT NULL DEFAULT '',
`owner` mediumtext DEFAULT NULL,
`employees` longtext DEFAULT '{}',
`stock` longtext DEFAULT '{}',
`data` longtext DEFAULT '{}',
`announcements` longtext DEFAULT '{}',
`orders` longtext DEFAULT '{}',
`history` longtext DEFAULT '{}'
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
2
Items:
INSERT INTO `items` (`name`, `label`, `weight`, `rare`, `can_remove`) VALUES
("hair_clipper", "Hair Clipper", 10, 0, 1);
['hair_clipper'] = {
["name"] = 'hair_clipper',
["label"] = "Hair Clipper",
["weight"] = 10,
["type"] = "item",
["image"] = "hair_clipper.png",
["unique"] = false,
["useable"] = true,
["shouldClose"] = false,
["combinable"] = nil,
["description"] = ""
},
['hair_clipper'] = {
label = 'Hair Clipper',
weight = 1,
stack = true
},
3
Jobs:
INSERT INTO `jobs` (name, label) VALUES
('barber1', 'Barber (1)'),
('barber2', 'Barber (2)'),
('barber3', 'Barber (3)'),
('barber4', 'Barber (4)'),
('barber5', 'Barber (5)'),
('barber6', 'Barber (6)'),
('barber7', 'Barber (7)');
INSERT INTO `job_grades` (job_name, grade, name, label, salary, skin_male, skin_female) VALUES
('barber1', 0, 'trainee', 'Trainee', 150, '{}', '{}'),
('barber1', 1, 'employee', 'Employee', 200, '{}', '{}'),
('barber1', 2, 'manager', 'Manager', 300, '{}', '{}'),
('barber1', 3, 'boss', 'Boss', 350, '{}', '{}'),
('barber2', 0, 'trainee', 'Trainee', 150, '{}', '{}'),
('barber2', 1, 'employee', 'Employee', 200, '{}', '{}'),
('barber2', 2, 'manager', 'Manager', 300, '{}', '{}'),
('barber2', 3, 'boss', 'Boss', 350, '{}', '{}'),
('barber3', 0, 'trainee', 'Trainee', 150, '{}', '{}'),
('barber3', 1, 'employee', 'Employee', 200, '{}', '{}'),
('barber3', 2, 'manager', 'Manager', 300, '{}', '{}'),
('barber3', 3, 'boss', 'Boss', 350, '{}', '{}'),
('barber4', 0, 'trainee', 'Trainee', 150, '{}', '{}'),
('barber4', 1, 'employee', 'Employee', 200, '{}', '{}'),
('barber4', 2, 'manager', 'Manager', 300, '{}', '{}'),
('barber4', 3, 'boss', 'Boss', 350, '{}', '{}'),
('barber5', 0, 'trainee', 'Trainee', 150, '{}', '{}'),
('barber5', 1, 'employee', 'Employee', 200, '{}', '{}'),
('barber5', 2, 'manager', 'Manager', 300, '{}', '{}'),
('barber5', 3, 'boss', 'Boss', 350, '{}', '{}'),
('barber6', 0, 'trainee', 'Trainee', 150, '{}', '{}'),
('barber6', 1, 'employee', 'Employee', 200, '{}', '{}'),
('barber6', 2, 'manager', 'Manager', 300, '{}', '{}'),
('barber6', 3, 'boss', 'Boss', 350, '{}', '{}'),
('barber7', 0, 'trainee', 'Trainee', 150, '{}', '{}'),
('barber7', 1, 'employee', 'Employee', 200, '{}', '{}'),
('barber7', 2, 'manager', 'Manager', 300, '{}', '{}'),
('barber7', 3, 'boss', 'Boss', 350, '{}', '{}')
;
['barber1'] = {
label = 'Barber (1)',
defaultDuty = true,
offDutyPay = false,
grades = {
['0'] = {name = 'recruit', payment = 50},
['1'] = {name = 'employee', payment = 250},
['2'] = {name = 'manager', payment = 250},
['3'] = {name = 'boss', payment = 250},
},
},
['barber2'] = {
label = 'Barber (2)',
defaultDuty = true,
offDutyPay = false,
grades = {
['0'] = {name = 'recruit', payment = 50},
['1'] = {name = 'employee', payment = 250},
['2'] = {name = 'manager', payment = 250},
['3'] = {name = 'boss', payment = 250},
},
},
['barber3'] = {
label = 'Barber (3)',
defaultDuty = true,
offDutyPay = false,
grades = {
['0'] = {name = 'recruit', payment = 50},
['1'] = {name = 'employee', payment = 250},
['2'] = {name = 'manager', payment = 250},
['3'] = {name = 'boss', payment = 250},
},
},
['barber4'] = {
label = 'Barber (4)',
defaultDuty = true,
offDutyPay = false,
grades = {
['0'] = {name = 'recruit', payment = 50},
['1'] = {name = 'employee', payment = 250},
['2'] = {name = 'manager', payment = 250},
['3'] = {name = 'boss', payment = 250},
},
},
['barber5'] = {
label = 'Barber (5)',
defaultDuty = true,
offDutyPay = false,
grades = {
['0'] = {name = 'recruit', payment = 50},
['1'] = {name = 'employee', payment = 250},
['2'] = {name = 'manager', payment = 250},
['3'] = {name = 'boss', payment = 250},
},
},
['barber6'] = {
label = 'Barber (6)',
defaultDuty = true,
offDutyPay = false,
grades = {
['0'] = {name = 'recruit', payment = 50},
['1'] = {name = 'employee', payment = 250},
['2'] = {name = 'manager', payment = 250},
['3'] = {name = 'boss', payment = 250},
},
},
['barber7'] = {
label = 'Barber (7)',
defaultDuty = true,
offDutyPay = false,
grades = {
['0'] = {name = 'recruit', payment = 50},
['1'] = {name = 'employee', payment = 250},
['2'] = {name = 'manager', payment = 250},
['3'] = {name = 'boss', payment = 250},
},
},
3. Illenium-appearance
If you have encountered a problem with your character getting up while using the barber shop, you need to make a change in your illenium-appearance
Replace the setPlayerAppearance function, with the one below:
../game/util.lua
local function setPlayerAppearance(appearance)
if appearance then
if not IsPedUsingAnyScenario(PlayerPedId()) then
setPlayerModel(appearance.model)
end
setPedAppearance(cache.ped, appearance)
end
end
Last updated