def get_all_items(player, locations=None, except_item=None):
    """
    Retrieves all items from specified locations

    :param text_game_maker.player.player.Player player: player object
    :param [[text_game_maker.game_objects.items.Item]] locations: location lists to search.\
        If None, the item list of the current room/tile is used
    :param object except_item: do not retrive item from location if it is the\
        same memory object as except_item. If None, no items are ignored.
    :return: list of retreived items
    :rtype: [text_game_maker.game_objects.items.Item]
    """

    if not player.can_see():
        return []

    if not locations:
        locations = player.current.items.values()

    ret = []
    for loc in locations:
        for item in loc:
            if (not except_item is None) and (except_item is item):
                continue

            if item.scenery:
                continue

            ret.append(item)

    return ret