aboutsummaryrefslogtreecommitdiff
path: root/gamemode/core/inventory
diff options
context:
space:
mode:
authorAlexander Pickering <alexandermpickering@gmail.com>2017-08-17 20:08:23 -0400
committerAlexander Pickering <alexandermpickering@gmail.com>2017-08-17 20:08:23 -0400
commit7a31161e59b34d34917a5c8826d5187fd63e844b (patch)
tree85694d3dc3429f2a3c2183f03b5e7c7a818958b3 /gamemode/core/inventory
parentfcffbc1ff27a7cb28bab85b223be7060c481bf8b (diff)
downloadartery-7a31161e59b34d34917a5c8826d5187fd63e844b.tar.gz
artery-7a31161e59b34d34917a5c8826d5187fd63e844b.tar.bz2
artery-7a31161e59b34d34917a5c8826d5187fd63e844b.zip
Made console commands admin-only
this was probably a big security bug or something lol
Diffstat (limited to 'gamemode/core/inventory')
-rw-r--r--gamemode/core/inventory/sv_invtracker.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/gamemode/core/inventory/sv_invtracker.lua b/gamemode/core/inventory/sv_invtracker.lua
index d4e7d79..c60298c 100644
--- a/gamemode/core/inventory/sv_invtracker.lua
+++ b/gamemode/core/inventory/sv_invtracker.lua
@@ -257,10 +257,12 @@ concommand.Add("artery_ShowMyInventories",function(ply,cmd,args)
end)
concommand.Add("artery_AddInventory",function(ply,cmd,args)
+ if not ply:IsAdmin() then return end
track.GiveInventoryTo(ply,args[1])
end)
concommand.Add("artery_GiveItem",function(ply,cmd,args)
+ if not ply:IsAdmin() then return end
xpcall(function()
ply:GiveItem(itm.GetItemByName(args[1]))
end,function(err)