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.

Disable Prop Spawning for users only?

Discussion in 'DarkRP Modding Questions & Help' started by Cheesey, Feb 28, 2018.

  1. Cheesey

    Cheesey New Member

    I wanna make a starwar's rp server yet i only want admin's to spawn prop's.
     
  2. Sir Klutch

    Sir Klutch Active Member

    lua/autorun/server
    Code (Lua):

    local player_propspawn_groups = {
        ["admin"] = true,
        ["superadmin"] = true,
    }
    hook.Add("PlayerSpawnProp", "propspawn_groups_only", function(ply, mdl)
        local prop_spawnGroups = player_propspawn_groups[ply:GetUserGroup()]
        if not prop_spawnGroups then
            return false
        end
    end)
     
     
  3. Cheesey

    Cheesey New Member

    Thank's dude
     
    Sir Klutch likes this.
  4. BioCris14

    BioCris14 New Member

    Wait, do i put in the serverside? Is the serverside admin_functions.lua or do i have to create a lua file with that in it?
     
  5. Dr. farts

    Dr. farts New Member

    By posting this reply, I assume you are using ULX, so... You can also use URS. ( ULX Restriction System ) You can download it Here. Just add the URS folder into your server's addons folder and configure it within the !menu itself. You can configure based on ranks, jobs, and others.
     

Share This Page