             context.lineWidth = 1
             context.strokeStyle = 'black'
             context.stroke()
-          if @maze.is_target([x, y, z])
-            # paint target
+          if @maze.is_finish([x, y, z])
+            # paint finish mark 
             context.beginPath()
             context.arc(71 * x + 71 / 2, 71 * y + 71 / 2, 21, 0, 2 * Math.PI, false)
             context.lineWidth = 10

      if unvisited_neighbors.length > 0
        neighbor = choice(unvisited_neighbors)
        passage = [cell, neighbor]
        target = neighbor
        passage.sort()
        @passages[passage] = true
        visited_cells[neighbor] = true

  passage_exists: (passage) ->
    passage of @passages

  is_finish: (cell) ->
    cell of @finishes

class MazeUI3D
