Special ULX Groups having access to Pointshop Admin Tab(excluding Admin, SuperAdmin, etc.)

Can anyone help me?
I want to have custom ulx groups have access to the Pointshop admin tab, but I don’t want groups like admin or superadmin have access, more like owner, coder, manager, etc.
All help would be much appreciated :slight_smile:

I’m at class, so this is just at the top of my head. If you’re trying to restrict items, add this below the name/price/model/etc

ITEM.AllowedUserGroups = {  }

and inside of the {} add the names of the ulx groups you want to be able to buy it, for example “owner”, “admin”, “superadmin”, and etc.

If you mean restrict the entire category then I think that isn’t as simple, but I could be wrong.

He means the administration tab. Not items or categories…

Anyways, go to lua/vgui/DPointShopMenu.lua and find

if (PS.Config.AdminCanAccessAdminTab and LocalPlayer():IsAdmin()) or (PS.Config.SuperAdminCanAccessAdminTab and LocalPlayer():IsSuperAdmin()) then

and replace it with

if (LocalPlayer():IsUserGroup(“owner”)) then

There’s serverside checks in there too.

How would I change them to ulx groups?

Code given from Matt
local admin_allowed = PS.Config.AdminCanAccessAdminTab and ply:IsAdmin()

Would I just change it like this?
local owner_allowed = PS.Config.ownerCanAccessAdminTab and ply:Isowner()

Sm63 I will test your post next.

And thanks for responding you guys :slight_smile:

No, you would do

local owner_allowed = PS.Config.ownerCanAccessAdminTab and ply:IsUserGroup( "owner" )

What would I do to allow multiple ulx groups to have access to the Admin Tab though, this would only work for the owner rank I presume.