3.0.0.4-beta

This is a detailed changelog for the specified release above.

Happy New Year

This update handles a few critical issues that have come up. As well as fix or adjust some other issues that have been reported.

◾ Job Sorting

Prior to this update; jobs were sorted based on their alphabetical name OR if you supplied sortOrder to each job.

If you created your darkrp jobs file and listed jobs in order based on how you wanted them to appear; Arivia would not honor this, and re-organized them based on the alphabet.

Below is a list of ways you may sort jobs now:

◾ Alphabetical

To sort all jobs alphabetically:

  • Open lua\modules\arivia\cfg\sh_4_tabs.lua

  • Find bRawData within the cfg.tabs.jobs table, set to false

  • Restart server

cfg.tabs.jobs =
{
     bEnabled                    = true,
     bRawData                    = false,

◾ Jobs file order

To sort jobs in order based on how they are added in config\jobrelated.lua:

  • Open lua\modules\arivia\cfg\sh_4_tabs.lua

  • Find bRawData within the cfg.tabs.jobs table, set to true

  • Restart server

cfg.tabs.jobs =
{
     bEnabled                    = true,
     bRawData                    = true,

◾ Manual Order

To sort based on an unorganized darkrp jobs file which gives you control to define where each job appears even if you don't have the jobs organized in the darkrp file itself.

You will need to utilize the sortOrder parameter which needs to be specified for each job.

  • Open lua\modules\arivia\cfg\sh_4_tabs.lua

  • Find bRawData within the cfg.tabs.jobs table, set to false

  • Open config\jobrelated.lua

  • Add sortOrder to each job individually

  • Restart server

TEAM_CIVILIAN = DarkRP.createJob( 'Civilian',
{
    color           = Color( 255, 255, 255, 255 ),
    model           = { 'models/player/group01/male_01.mdl' },
    description     = [[Citizen]],
    command         = 'civilian',
    max             = 0,
    salary          = 50,
    admin           = 0,
    category        = 'Basic',
    sortOrder       = 1,
} )


TEAM_BUM = DarkRP.createJob( 'Bum',
{
    color           = Color( 255, 255, 255, 255 ),
    model           = { 'models/player/corpse1.mdl' },
    description     = [[Bum]],
    command         = 'bum',
    max             = 0,
    salary          = 50,
    admin           = 0,
    category        = 'Basic',
    sortOrder       = 3,
} )


TEAM_DOCTOR = DarkRP.createJob( 'Doctor',
{
    color           = Color( 255, 255, 255, 255 ),
    model           = { 'models/player/kleiner.mdl' },
    description     = [[Test]],
    command         = 'doctor',
    max             = 2,
    salary          = 100,
    admin           = 0,
    category        = 'Basic',
    sortOrder       = 2,
} )

The above code would add 3 new jobs in the category Basic:

  • Civilian Slot 1

  • Bum Slot 3

  • Doctor Slot 2

◾ Player Choice

In the future, a sorting option will be added which allows the player themselves to sort the list of jobs by any one of the following:

  • Job Name (A - Z, Z - A)

  • Salary (Least to Greatest, Greatest to Least)

  • Slots (Least to Greatest, Greatest to Least)

  • Default (How they are entered into the jobs file

◾ Script errors on single job

An issue was fixed which would display an error if the server owner only supplied ONE job in the darkrp jobs file.

The reason for this is because Arivia has an option which hides the player's default job and only shows the others. If this setting is enabled and only one job is available for the server, then the script would throw errors because it couldn't find a second job to list.

Arivia now displays the default job no matter what bShowCurrJob is set to; if the server only has one job to work with. This should help avoid confusion.

Last updated