/[enigma]/enigma/init.lua
ViewVC logotype

Diff of /enigma/init.lua

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.12 by mhawlisch, Tue Dec 3 12:16:45 2002 UTC revision 1.13 by mhawlisch, Tue Dec 3 12:49:41 2002 UTC
# Line 85  function set_stone(name, x,y, attrs) Line 85  function set_stone(name, x,y, attrs)
85  end  end
86    
87  function fill_floor(name, x0,y0, w,h)  function fill_floor(name, x0,y0, w,h)
88        if x0 == nil then x0 = 0 end
89        if y0 == nil then y0 = 0 end
90        if w  == nil then w  = level_width end
91        if h  == nil then h  = level_height end
92      for y=y0,y0+h-1 do      for y=y0,y0+h-1 do
93          for x=x0,x0+w-1 do set_floor(name, x, y) end          for x=x0,x0+w-1 do set_floor(name, x, y) end
94      end      end
# Line 141  function draw_stones(name, xy0, xystep, Line 145  function draw_stones(name, xy0, xystep,
145      end      end
146  end  end
147    
148  function draw_border(stonename)  function draw_border(stonename, x0, y0, w, h)
149      draw_stones(stonename, {0,0}, {1,0}, level_width)      if x0 == nil then x0 = 0 end
150      draw_stones(stonename, {0,level_height-1},{1,0}, level_width)      if y0 == nil then y0 = 0 end
151      draw_stones(stonename, {0,0}, {0,1}, level_height)      if w  == nil then w  = level_width end
152      draw_stones(stonename, {level_width-1,0},{0,1}, level_height)      if h  == nil then h  = level_height end
153        draw_stones(stonename, {x0,y0}, {1,0}, w)
154        draw_stones(stonename, {x0,y0+h-1},{1,0}, w)
155        draw_stones(stonename, {x0,y0}, {0,1}, h)
156        draw_stones(stonename, {x0+w-1,y0},{0,1}, h)
157  end  end
158    
159  function set_stones(name, poslist, attrs)  function set_stones(name, poslist, attrs)

Legend:
Removed from v.1.12  
changed lines
  Added in v.1.13

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26