Fix accidental globals
This commit is contained in:
parent
07fa3b264d
commit
1f2a7ed039
@ -18,7 +18,7 @@
|
||||
do
|
||||
local loose, user_toggles, user_settings
|
||||
loose, user_toggles, user_settings = ...
|
||||
local mw,mh,mt
|
||||
local mw,mh,mt,mwater
|
||||
mw = user_settings["mw"] or 512 -- width
|
||||
mh = user_settings["mh"] or 512 -- height
|
||||
mt = user_settings["mt"] or 1.0 -- turbulence
|
||||
|
@ -31,7 +31,7 @@ do
|
||||
common.map_set(ret)
|
||||
for x=0,mx-1 do
|
||||
for z=0,mz-1 do
|
||||
l = {0, my - depth, my - depth, 0, b, g, r, 1}
|
||||
local l = {0, my - depth, my - depth, 0, b, g, r, 1}
|
||||
common.map_pillar_set(x, z, l)
|
||||
end
|
||||
end
|
||||
|
@ -98,6 +98,7 @@ function slot_add(neth, tidx, wpn, name)
|
||||
-- TODO: actually balance this properly!
|
||||
tidx = (i-1) % 2
|
||||
end
|
||||
local _wpn
|
||||
if MODE_TEAM_GUNS then
|
||||
_wpn = tidx + 1
|
||||
else
|
||||
|
@ -353,12 +353,12 @@ function new_player(settings)
|
||||
end
|
||||
|
||||
function this.tool_switch_next()
|
||||
new_tool = (this.tool + 1) % #this.tools
|
||||
local new_tool = (this.tool + 1) % #this.tools
|
||||
this.tool_switch(new_tool)
|
||||
end
|
||||
|
||||
function this.tool_switch_prev()
|
||||
new_tool = (this.tool - 1) % #this.tools
|
||||
local new_tool = (this.tool - 1) % #this.tools
|
||||
this.tool_switch(new_tool)
|
||||
end
|
||||
|
||||
@ -559,7 +559,7 @@ function new_player(settings)
|
||||
function this.fall_damage(amt)
|
||||
--print("damage",this.name,part,amt)
|
||||
local l = teams[this.team].color_chat
|
||||
r,g,b = l[1],l[2],l[3]
|
||||
local r,g,b = l[1],l[2],l[3]
|
||||
|
||||
local c = argb_split_to_merged(r,g,b)
|
||||
|
||||
@ -873,6 +873,7 @@ function new_player(settings)
|
||||
end
|
||||
end
|
||||
|
||||
local tx1,ty1,tz1
|
||||
if this.alive then
|
||||
tx1,ty1,tz1 = trace_map_box(
|
||||
ox, oy, oz,
|
||||
|
Loading…
x
Reference in New Issue
Block a user