class_docstr: A high level game controller class for maze levels.
  
  The class allows navigating DMLab mazes using high level actions.
class_docstr_tok: ["A","high","level","game","controller","class","for","maze","levels",".","The","class","allows","navigating","DMLab","mazes","using","high","level","actions","."]
docstr: Return a new path that includes all intermediate steps.
docstr_tok: ["Return","a","new","path","that","includes","all","intermediate","steps","."]
code: def _expand_path(self, path):
      """Return a new path that includes all intermediate steps."""
      (last_x, last_y) = self.maze_position()
      expanded_path = [(last_x, last_y)]
      maze = self._get_maze()
      for x, y in path:
          if last_x != x or last_y != y:
              local_path = _find_path(maze, last_x, last_y, x, y)
              if local_path:
                  expanded_path += local_path
              else:
                  return None
          last_x, last_y = x, y
      return expanded_path
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import numpy
  from python.tests.utils import game_controller
label_desc: Use image node_id 5 for calling the MazeGameController obj's underlying member method code with example usage: obj._expand_path(path) and returns: expanded_path, None