1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Sign up for news, events and more!

    You're currently visiting the official DarkRP Forums as a guest. Sign up now to participate in our community and we'll let you know when we have news.

DarkRP jobs

Discussion in 'DarkRP Modding Questions & Help' started by *F.H.O* *Poisonbird*, Nov 15, 2016.

  1. Hello.

    I recently bought a server and wanted to add some jobs to it.

    When adding any job i get an error.
    I use TCB's job generator for the jobs and they should work.

    The code i have right now:
    TEAM_OWNER = DarkRP.createJob("Owner On Duty", {
    color = Color(36, 157, 196, 255),
    model = {"models/player/combine_super_soldier.mdl"},
    description = [[Owner on Booty! Do whatever the boot you want!]],
    weapons = {},
    command = "OOD",
    max = 1,
    salary = 0,
    admin = 2,
    vote = false,
    hasLicense = true,
    candemote = false,
    -- CustomCheck
    medic = false,
    chief = false,
    mayor = false,
    hobo = false,
    cook = false,
    category = "",
    })



    The error:

    [ERROR] addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:42: unexpected symbol near '}'
    1. unknown - addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:0


    Thanks for any help!
     
  2. Pab14567

    Pab14567 Well-Known Member

    Would be helpful if we knew what line is which and all the things around it, ( meaning all the jobs ) in a pastebin so we can know what line is what. ( basically just CTRL+A the whole file and CTRL+C on pastebin )
     
  3. Ok so, i fixed that somehow but not i added a new job and its in the F4 but pressing "Become Job" doesnt do anything?

    In my console it says:
    Unhandled Lua Refresh: [NAME:darkrp_customthings/jobs.lua] [TYPE:!UNKNOWN]


    jobs.lua: http://pastebin.com/vK1WTJxf
    --- Double Post Merged, Nov 16, 2016 ---
    Fixed aswell,

    New error in console:

    [ERROR] addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:21: unexpected symbol near '}'
    1. unknown - addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:0


    New jobs.lua: http://pastebin.com/NpmfDSE4


    Problem is, none of those jobs are showing up?

    Thanks!
     
    Last edited: Nov 16, 2016
  4. Pab14567

    Pab14567 Well-Known Member

    take off #NoSimplerr# That's not how you do it , plus take it off since you don't understand how to read and interpret lua errors

    Simplerr yes disables autorefresh but helps you understand the errors

    this further strengthens my point as to why you NEED to take off #NoSimplerr#

    Code (Text):

     -- line 19 Add jobs under the following line:
     -- line 20  ---------------------------------------------------------------------------]]
    -- line 21 })
    -- line 22 TEAM_OWNER = DarkRP.createJob("Owner On Duty", {
     
     
  5. Ì removed the Simplerr. And still the same! Same jobs.lua and error in logs:
    it.lua:86

    Couldn't Load Init Script: 'darkrp/gamemode/init.lua'
    Default clips will be not be modified
    +---------------------------------+
    | E2 EXTENSIONS |
    +----------------+----------------+
    | ENABLED | DISABLED |
    +----------------+----------------+
    | console | constraintcore |
    | file | effects |
    | find | http |
    | holo | propcore |
    | npc | remoteupload |
    | ranger | wiring |
    | serialization | |
    | sound | |
    +----------------+----------------+
    HTTP failed - ISteamHTTP isn't available!
    Making workshop map available for client download
    Using map cycle file cfg/mapcycle.txt.
    Couldn't find any entities named downtown_shopstorefront01bglass, which point_template respawn_downtown_shopstorefront01 is specifying.
    Precache called on a point_template that has no templates: respawn_downtown_shopstorefront01
    Nav File is wrong or something (1)
    Server logging enabled.
    Server logging data to file logs\L1117002.log
    Unknown command "sbox_allownpcs"
    Unknown command "sbox_plpldamage"
    Unknown command "sbox_playergod"
    Unknown command "sbox_maxspawners"
    Unknown command "sbox_maxturrets"
    Writing cfg/banned_user.cfg.
    Client "*F.H.O* *Poisonbird*" connected (82.176.30.236:27005).
    Spawning textscreens...
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) is Authed
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Spawned for the first time
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Spawned
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a keys
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a weapon_physcannon
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a gmod_camera
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a gmod_tool
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a pocket
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a weapon_physgun
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a weapon_keypadchecker
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a door_ram
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a arrest_stick
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a unarrest_stick
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a stunstick
    ServerLog: [FAdmin] *F.H.O* *Poisonbird* (STEAM_0:1:55795963) Attempted to pick up a weaponchecker
    [*F.H.O* *Poisonbird*|2|STEAM_0:1:55795963] Lua Error:

    [ERROR] addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:33: unexpected symbol near '}'
    1. unknown - addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:0
     
  6. Zoephix

    Zoephix New Member

    Code (Text):
    TEAM_OWNER = DarkRP.createJob("Owner on Duty", {
        color = Color(20, 150, 20, 255),
        model = {
            "models/player/combine_super_soldier.mdl",
        },
        description = [[The Owner on duty],
        weapons = {},
        command = "ood",
        max = 0,
        salary = GAMEMODE.Config.normalsalary,
        admin = 1,
        vote = false,
        hasLicense = false,
        candemote = false,
        category = "Citizens",
    })
    Simply put that in jobrelated.lua, thank me later.
     
    Last edited: Nov 20, 2016
  7. Pab14567

    Pab14567 Well-Known Member

    Or you can just remove it and it'll default to Other.
     

Share This Page