plz why error line
1
if (tilex >= i[1][1] and tilex <= i[2][1]) and (tiley >= i[1][2] and tiley <= i[2][2]) then
error conssole
1
2
2
LUA ERROR: sys/lua/safezone.lua:24: attempt to compare number with bool ean
script
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
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
addhook("hit", "_hit")
addhook("movetile", "_movetile")
function _hit(id,pl)
	if _safezone(id) then
		return 1;
	elseif _safezone(pl) then
		return 1;
	end
end
function _movetile(id,x,y)
	if _safezone(id) then
		parse('hudtxt2 '..id..' 11 "'..t_color["azulm"]..'SAFE ZONE" 320 200 1');
	elseif not _safezone(id) then
		parse('hudtxt2 '..id..' 11 ""');
	end
end
function _safezone(id)
	local tilex = player(id,"tilex");
	local tiley = player(id,"tiley");
	for _, i in pairs(safezones) do
		if (tilex >= i[1][1] and tilex <= i[2][1]) and (tiley >= i[1][2] and tiley <= i[2][2]) then
			return true;
		end
	end
	return false;
end
Why error safezone
1 
Offline
mozilla1