[QBCORE/ESX] Liberty Skills - Skill Levelling System
A full skills system for FiveM including 5 default GTA skills, support for Core Crafting’s levels and a simple yet detailed config to modify the script or add/remove skill types to your liking.
Ensure you have installed all necessary dependencies listed above
Extract the downloaded file
Import liberty-skills.sql to your database
Drag-and-drop the liberty-skills folder into your server’s resources folder (ensure the contents of this file include fxmanifest.lua and not another liberty-skills folder!)
Make sure to add ensure liberty-skills to your server’s server.cfg
Configure to your liking in liberty-skills/shared/config.lua
I think the way you’re updating the script will take a tremendous amount of resmon, could you share resource usage when you are for example, running, and the script is updating your XP?
There are two serverside exports available: AddPlayerEXP - Add EXP to a player - arguments: source, citizenid, skilltype, amount
eg. exports["liberty-skills"]:AddPlayerEXP(source, PlayerData.citizenid, "Stamina", 10)
GetCurLevel - Get a player’s level - arguments: source, type - returns: level, exp
eg. exports["liberty-skills"]:AddPlayerEXP(source, "Stamina")
Added new RemovePlayerEXP function/export
This can be implemented if you want to remove EXP from a player for any reason (going to jail, failing a skillcheck, etc) and will “wrap-around” if they hit 0 EXP (ie. if they lose 200 EXP for a skill but have 100 EXP, they will be 100 EXP away from levelling up on their new level)