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
function initArray(m)
local array = {}
for i = 1, m do
array[i]=0
end
return array
end
flsh=initArray(32)
addhook("drop","drop")
function drop(id,wpn)
if flsh[id]==1 then
flsh[id]=0
end
end
addhook("collect","clct")
function clct(id,wpn)
if wpn==52 then
if flsh[id]==0 then
flsh[id]=1
end
end
end
addhook("attack","att")
function att(id,wpn)
if wpn==52 then
if flsh[id]==1 then
flsh[id]=0
end
end
end
addhook("walkover","wlk")
function wlk(id,wpn)
if wpn==52 then
if flsh[id]==1 then
flsh[id]=0
return 1
end
end
end