
def setup_bmp(filename)
  graph=SDL::Surface.loadBMP(filename)
  graph.setColorKey SDL::SRCCOLORKEY, graph[0,0]
  graph=graph.displayFormat
end

def x_out?(x,w)
  x+w+10<LWALL_X || x-10>RWALL_X
end

def send_loc?(x,w)
  return true if LWALL_X+SEND_FIELD_WIDTH>x+w
  return true if RWALL_X-SEND_FIELD_WIDTH<x
  false
end

class System
  
  def initialize
    @life=3
  end

  def continue_game?
    @life > 0
  end
  
end
