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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
adminlist = {USGN HERE}
godMode={}
addhook("spawn","onspawn")
addhook("serveraction","_serveraction")
addhook("join","_join")
addhook("hit","_hit")
function initArray(m)
	local array = {}
	for i = 1, m do
		array[i]=0
	end
	return array
end
isadmin=initArray(32)
function onspawn(id)
	for id = 1,32 do
		if player(id,"usgn")==usgn then
			isadmin[id]=1
		end
	end
end
function _join(id)
	godMode[id]=false
end
function _serveraction(id,action)
	if action==3 then
		for _, usgn in ipairs(adminlist) do
		if godMode[id]==false then
		msg2(id,"GodMode Activated")
			godMode[id]=true
		else
			msg2(id,"GodMode Deactivated")
			godMode[id]=false
		end
	end
end
function _hit(id)
	if godMode[id]==true then
		return 1
		end
	end
end