Installation and configuration
Guide on how to setup the script. Your Framework (esx/qb-core/qbox) is detected automatically.
The command to open the menu is in the top of the local file
1. Setup your Database
Don't worry about setting up the database yourself! If you have Config.CreateTables = true
in the config, they are created on script startup by theq script itself. You don't have to do anything.
2. Edit Config File
Now you have to edit the config.lua file to your liking. A full preview of the config file can be found here.
2.1 General
2.1.1 Language
Simply the language used in the script. Available are de and en. You can find the translations in the locales folder and edit the files. You can also create a new one, for example fr.lua, paste the english translations there and then translate it yourself to have your own locale file.
2.1.2 Currency
Here you can change from β¬ to $ or any other currency, depending on your server's setting. Only changes what is displayed in the notifications and UI.
2.1.3 Auto Create Tables
If this is set to true, the script will automatically create needed tables and columns depending on your config on startup. Recommended to keep to true.
2.1.4 Boss Grades
These are the ranks of each job, that are allowed to access their employees data. For example in this case, someone with the job police has to have at least grade 3 to access the employees data. So its always jobname = minimumgrade. Remember to use the jobs name, not label.
2.1.5 Jobswitches
Here you can specify players that are allowed to switch between two jobs, kind of like a multijob system. If a player is allowed to switch their job, they have a button in the top left corner of the menu to switch to their second job. The script will check for the players current job, if they are in job1 they go into job2 and vise versa. Remember to insert the right grade and to use the jobs name instead of its label. The identifier depends on your framework and multichar system. It is the same identifier, that is used in your users/players table to identify the user. On ESX with multi char scripts, this is most times something like char1:12345abcde
a few letters and a few numbers that are either the players license, or the steam identifier. In most cases it is the license. On QB this is the citizenid.
2.1.6 Paychecks
If you use this scripts paychecks, remember to turn off your frameworks paychecks to avoid double salarys!
The paycheck interval is the time in minutes between each paycheck. This is counted for each job seperately. Because every minute is tracked, players can also work for 20 minutes, go offline, work another 40 minutes the next day and get their paycheck as soons as 60 minutes is full. Config.PaycheckFromSociety
means that the money used to pay the players salary is deducted from the society account. Currently only works with ESX. You can implement your own logic for this for other company account systems with the custom function below.
2.1.7 Custom Function
This is an empty function that is called, after a player received their paycheck. You can use this for anything you need, like removing money from company accounts, inserting the paycheck data into banking scripts or whatever.
2.2 Notifications
2.2.1 Notification Script
This is the notification script used. Supported scripts are: okokNotify, esx, lib (Ox_Lib), RiP-Notify, qb, wasabi_notify, mythic_notify and sy_notify. If yours is not supported, you can add your own script with the custom function below.
2.2.2 Custom Notification Script
If your notification script is not supported, you can use this to add support for your own. type
is the type of notification. Possible types are info, success and error. msg
is just the notification message. heading
is the notification heading, if your script does not have notification headings, leave this out. source
is the player server id. Usually you just need to add your scripts event or export. Read their docs. If you need help with this, contact us on our discord.
If you have any questions, open a ticket on our discord. If your script is not supported, you can ask us and we will try to add native support for it. https://discord.gg/CfnuaArDBk
Last updated
Was this helpful?