예제 #1
0
파일: abandonia.py 프로젝트: ponty/abandi
    def parse_game(self, id):
        game = Game()

        game.id = id

        url = self.getGameHomePage(id)
        if not url:
            return None
        parser = self.WebParser.WebParser(url)

        # buy it!
        all_images = "|".join(parser.getImages())
        if "buy" in all_images.lower():
            return None
        if "protected" in all_images.lower():
            return None

        game.home_url = url
        game.source = self.name
        self.parse(game, parser)
        if not game:
            return None

        if not game.name:
            return None
        # example: http://www.abandonia.com/en/games/248/index.html
        if game.name.lower == "download":
            return None

        return game
예제 #2
0
    def parse_game(self, id):
        game = Game()

        game.id = id

        url = self.getGameHomePage(id)
        if not url:
            return None
        parser = self.WebParser.WebParser(url)

        # buy it!
        all_images = '|'.join(parser.getImages())
        if 'buy' in all_images.lower():
            return None
        if 'protected' in all_images.lower():
            return None

        game.home_url = url
        game.source = self.name
        self.parse(game, parser)
        if not game:
            return None

        if not game.name:
            return None
        # example: http://www.abandonia.com/en/games/248/index.html
        if game.name.lower == "download":
            return None

        return game
예제 #3
0
파일: osd.py 프로젝트: Cloudxtreme/abandi
    def parse_game(self, id):
        game = Game()

        game.id = id

        url = self.getGameHomePage(id)
        if not url:
            return None
        parser = self.WebParser.WebParser(url)
        game.home_url = url
        game.source = self.name
        self.parse(game, parser)
        if not game:
            return None

        if not game.name:
            return None
        return game
예제 #4
0
파일: osd.py 프로젝트: carriercomm/abandi
    def parse_game(self, id):
        game = Game()

        game.id = id

        url = self.getGameHomePage(id)
        if not url:
            return None
        parser = self.WebParser.WebParser(url)
        game.home_url = url
        game.source = self.name
        self.parse(game, parser)
        if not game:
            return None

        if not game.name:
            return None
        return game
예제 #5
0
파일: gb64.py 프로젝트: Cloudxtreme/abandi
    def parse_game(self, id):
        game = Game()

        game.id = id

        url = self.getGameHomePage(id)
        parser = self.WebParser.WebParser(url)
        game.home_url = url
        game.source = self.name
        self.parseLinks(game, parser)

        game.screenshot_url_list = '|'.join(
            self.selectScreenshots(parser.getImages(), id))

        if not game or not game.name or "Banner Exchange" in game.name:
            return None
        if not game.game_file_url:
            log.debug('no file to download for "%s"' % game.name)
            return None

        game.platform = 'c64'
        return game
예제 #6
0
파일: oscomp.py 프로젝트: ponty/abandi
    def parse_game(self, id):
        game = Game()

        game.id = id

        url = self.getGameHomePage(id)
        parser = self.WebParser.WebParser(url)
        game.home_url = url
        game.source = self.name
        self.parse(game, parser)

        if not game:
            return None

        if not game.name:
            return None

        if not game.platform:
            return None

        if game.genre.lower() == ("emulator"):
            return None

        if game.genre.lower() == ("operation system"):
            return None

        if game.genre.lower() == ("music"):
            return None

        if game.genre.lower() == ("utilities"):
            return None

        if game.genre.lower() == ("document"):
            return None

        return game
예제 #7
0
    def parse_game(self, id):
        game = Game()

        game.id = id

        url = self.getGameHomePage(id)
        parser = self.WebParser.WebParser(url)
        game.home_url = url
        game.source = self.name
        self.parse(game, parser)

        if not game:
            return None

        if not game.name:
            return None

        if not game.platform:
            return None

        if (game.genre.lower() == ("emulator")):
            return None

        if (game.genre.lower() == ("operation system")):
            return None

        if (game.genre.lower() == ("music")):
            return None

        if (game.genre.lower() == ("utilities")):
            return None

        if (game.genre.lower() == ("document")):
            return None

        return game