function ur.spawnSwep( ply, weap ) local loadout = ur.getLoadout(ply) local function excluded() if ur.config.admin_exclude.loadouts == "true" and ply:IsAdmin() then return true end if loadout == "excluded" then return true end if ur.config.loadouts == "false" then return true end return false end if ur.loadouts[loadout] then if not excluded() then if not(table.HasValue(ur.loadouts[loadout]["loadout"], weap)) then ULib.tsay(ply, "Sorry, You Are Not Allowed To Use This Weapon") return false end end end end hook.Add( "PlayerSpawnSWEP", "URestrict.SpawnSwep_Hook", ur.spawnSwep)