Hello,i want to show you my first addon.
This is [QWERSTRICTION] weapon restriction and weapon loadout addon for server owners.

ULX admin mod recommended for DComboBox for ulx groups but it works without ulx.

You must to be superadmin.
Type to console “qwerstriction” or better
bind p qwerstriction.

Write in chat !qwerst for menu open

Description section:

  1. Weapons
    In this section you can add weapons to ban list for each group.
    The biggest button inserts all weapons that you have.
    Just press the weapon name and group in inset “remove Weapon” to clear the panel and ban list.



  1. Loadout
    Loadout- default weapons after player spawn.
    in this section you can add custom loadouts and BIG button inherits,that mean you can add many weapons by pressing 1 click.
    Also you can set ammo for weapons and groups(group should be in loadout)



  1. Entities- Ban entities list from Q menu
    i think i will not to describe you how to work with it,its easy.


  1. Toolgun
    Ban toolgun things for each group.
    There is a button named “tool name” that can help you if you can’t find tool name.


  1. NPC
    Just set limit and ban npc class for each group.


  1. Props
    Just set limit and ban model props for each group.

  2. Ragdoll
    Just set limit and ban model ragdolls for each group.

  3. Vehicles
    Just set limit and ban class of vehicle(car) for each group.







Your code is full of unnecessary file reading calls and pretty terrible overall, but pretty good gui at least.

Like what the hell. Read the file once and store the data in a global.
local function Checkabyz() ///
if !file.Exists(“qwerstriction/weapon.txt”,“DATA”) then return end ///
local List=util.KeyValuesToTable(file.Read(“qwerstriction/weapon.txt”,“DATA”)) ///
for k,v in pairs(player.GetAll()) do ///
for n,s in pairs(List) do ///
for i=1,#s do ///
if v:IsUserGroup(n) && v:HasWeapon(s*) then ///
v:StripWeapon(s*) ///
end ///
end ///
end ///
end ///
end ///