from src.World import *
from src.BFS import *
from src.Node import *

class Map:

    #returns walls and snakes
    @staticmethod
    def get_obstacles(world: World):
        res = []
        res.extend(world.get_walls())
        for s in world.snakes:
            res.extend(world.snakes[s].get_body())
        return res

    #returns opponent snake heads
    @staticmethod
    def get_snake_heads(world: World):
        snake_heads = []
        for s in world.snakes:
            if world.snakes[s].get_head() is world.get_self().get_head():
                continue
            snake_heads.append(world.snakes[s].get_head())

        return snake_heads
