RRT/src/world.py
def print_obstacles(self, gameDisplay, robot_size):
        '''
        prints obstacles, spawn and goal onto the display

        Default obstacle colour: (0,0,0)
        '''
        inflate = False
        if self.inflated_obstacles:
            inflate = True
            self.reduce_obstacle(robot_size)

        for obstacle in self.obstacles:
            pygame.draw.rect(gameDisplay, (0,0,0), pygame.Rect(obstacle[0], obstacle[1], obstacle[2], obstacle[3]))
        
        pygame.draw.circle(gameDisplay, (255,0,0), self.spawn, 10)
        pygame.draw.circle(gameDisplay, (0,255,0), self.goal, 10)

        if inflate:
            self.grow_obstacles(robot_size)

        prints obstacles, spawn and goal onto the display

        Default obstacle colour: (0,0,0)
        
prints obstacles, spawn and goal onto the display
Default obstacle colour: (0,0,0)
prints obstacles spawn and goal onto the display Default obstacle colour : ( 0 0 0 )
def print_obstacles(self, gameDisplay, robot_size):
        inflate = False
        if self.inflated_obstacles:
            inflate = True
            self.reduce_obstacle(robot_size)
        for obstacle in self.obstacles:
            pygame.draw.rect(gameDisplay, (0,0,0), pygame.Rect(obstacle[0], obstacle[1], obstacle[2], obstacle[3]))
        pygame.draw.circle(gameDisplay, (255,0,0), self.spawn, 10)
        pygame.draw.circle(gameDisplay, (0,255,0), self.goal, 10)
        if inflate:
            self.grow_obstacles(robot_size)
def print_obstacles ( self , gameDisplay , robot_size ) : inflate = False if self . inflated_obstacles : inflate = True self . reduce_obstacle ( robot_size ) for obstacle in self . obstacles : pygame . draw . rect ( gameDisplay , ( 0 , 0 , 0 ) , pygame . Rect ( obstacle [ 0 ] , obstacle [ 1 ] , obstacle [ 2 ] , obstacle [ 3 ] ) ) pygame . draw . circle ( gameDisplay , ( 255 , 0 , 0 ) , self . spawn , 10 ) pygame . draw . circle ( gameDisplay , ( 0 , 255 , 0 ) , self . goal , 10 ) if inflate : self . grow_obstacles ( robot_size )
prints obstacles, spawn and goal onto the display
Default obstacle colour: (0,0,0)
prints obstacles spawn and goal onto the display Default obstacle colour : ( 0 0 0 )
'''
        prints obstacles, spawn and goal onto the display

        Default obstacle colour: (0,0,0)
        '''
self
gameDisplay
robot_size