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.

NEED HELP: Custom jobs cannot spawn their job related items.

Discussion in 'DarkRP Modding Questions & Help' started by Ryanorfeed, Sep 24, 2019.

  1. Ryanorfeed

    Ryanorfeed New Member

    My custom jobs (Meth Cook, Cook, and Black Market Dealer) all have custom weapons, shipments, and entities that only that job can spawn. But when you look in the F4 menu, nothing shows up. It fixes it only for the people currently on the server if i set (GM.Config.hideNonBuyable = false) and (GM.Config.hideTeamUnbuyable = true) in settings.lua to opposites (setting false to true and true to false) and then back to their default. It seems to refresh the file and fixes the issue. But if a new person joins the server, they cannot see the entities for the specific job. I must also refresh the addentities.lua allowed = {TEAM_METH}, line to allow the job to purchase it. It is also strange because the Gun Dealer job still functions properly. It could have a correlation between custom jobs made in jobs.lua and not jobrelated.lua maybe?

    This is the error i believe is related to the issue i get in my console:
    [AddCSLuaFile] Couldn't find 'darkrp_modules/eml/sh_eml_darkrp.lua' (@gamemodes/darkrp/gamemode/libraries/modificationloader.lua (line 83))

    I think it has something to do with that but i have no idea how to fix it.

    I also get these errors but don't believe they are related:
    [Ryanorfeed|4|STEAM_x:x:xxxxxxxx] Lua Error:

    [ERROR] RunString:1: unexpected symbol near '<'
    1. onsuccess - lua/autorun/free_darkrp_hud.lua:154
    2. unknown - lua/includes/modules/http.lua:29
    -----------------------------------------------------------------------------------------------------------------------
    Reloading Scripted Entities..

    [ERROR] addons/cronos bank rob/lua/entities/bank_vault/init.lua:242: '=' expected near '<eof>'

    Refusing to load bank_vault because it is missing Type and Base keys!
    ----------------------------------------------------------------------------------------------------------------------
    I have attached my lua files that i believe hold the issue.
    Thank you for your time.
    -Ryanorfeed
    --- Double Post Merged, Sep 24, 2019 ---
    OK so shortly after I posted this I tried messing around with the files more to see if I can fix it. Turns out moving my custom jobs from jobs.lua to jobrelated.lua fixed the issue for now. But I am still confused on why a job from jobs.lua cannot spawn entities or shipments.
     

    Attached Files:

    Last edited: Sep 24, 2019

Share This Page