def set_destination(self, dest_hex): from hexagon import Hexagon start_hex = self.get_base_hex() # self.curr_path = a_star(start_hex, dest_hex) self.curr_path = Hexagon.find_path(start_hex, dest_hex)
def generate(start_seg, stop_seg):#, distance, height_range=(0, 2)): from hexagon import Hexagon # for curr_seg in a_star(start_seg, stop_seg): for curr_seg in Hexagon.find_path(start_seg, stop_seg): curr_seg.set_improvement('road', True)
def generate(start_seg, stop_seg): #, distance, height_range=(0, 2)): from hexagon import Hexagon # for curr_seg in a_star(start_seg, stop_seg): for curr_seg in Hexagon.find_path(start_seg, stop_seg): curr_seg.set_improvement('road', True)