josedisla Posted January 13, 2023 Share Posted January 13, 2023 Does anyone know what function or code I should use to add level to a job? Link to comment
Trust aka Tiffergan Posted January 13, 2023 Share Posted January 13, 2023 Here is an example of how you can use this function to set the level of a player's job: local player = getPlayerFromName("PlayerName") local level = 5 setElementData(player, "job level", level) This will set the player's job level to 5. You can then retrieve the data with the getElementData function. local player = getPlayerFromName("PlayerName") local level = getElementData(player, "job level") This will get the player's job level . Please note that this is just a basic example, you'll probably need to integrate this into your job system and add additional functionality such as checking for valid jobs and levels, and updating the player's job level in your database. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now