1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
adminlst = {} --// USGNs of admins
adminwpn = {30} --// admin weapons ID's
flashwpn = {30} --// weapons that flash on hit
isThere = function(list, element)
	for _,v in pairs(list) do
		if element == v then return true end
	end
	return false
end
addhook("walkover", "OnCollectAttempt")
addhook("buy", "OnCollectAttempt")
OnCollectAttempt = function(id, iid, t)
	t = t or iid
	if isThere(adminwpn, t) then	
		if not isThere(adminlst, player(id, "usgn")) then
			msg2(id, "You can't carry "..itemtype(t, "name").."! It's reserved for admins!")
			return 1
		end
	end
end
addhook("hit", "OnHit")
OnHit = function(victim, attacker, wpn)
	if isThere(adminlst, player(attacker, "usgn")) and isThere(flashwpn, wpn) then
		parse("flashplayer "..victim.." 5")
	end
end