Updates en varios scripts
This commit is contained in:
@@ -22,6 +22,7 @@ def normalize_path(path):
|
||||
|
||||
# Inicialización de las opciones
|
||||
ignore_list = ["DECO Cassette", "Bootleg", "prototype", "Quiz", "Mahjong", "Demo"]
|
||||
ignore_system = ["neogeo"]
|
||||
|
||||
# Obtiene los argumentos
|
||||
parser = argparse.ArgumentParser(
|
||||
@@ -99,11 +100,12 @@ if args.list and args.manufacturer != None:
|
||||
manufacturer = game.getElementsByTagName("manufacturer")[0]
|
||||
description = game.getElementsByTagName("description")[0]
|
||||
if (
|
||||
manufacturer.firstChild.data == args.manufacturer
|
||||
(manufacturer.firstChild.data == args.manufacturer
|
||||
or args.manufacturer == 'all')
|
||||
and not cloneof
|
||||
and not isbios
|
||||
):
|
||||
print(description.firstChild.data)
|
||||
print(description.firstChild.data, '==>', game.getAttribute("name") + ".zip from", manufacturer.firstChild.data)
|
||||
|
||||
# Copia los juegos del desarrollador seleccionado
|
||||
if (
|
||||
@@ -127,6 +129,7 @@ if (
|
||||
name = game.getAttribute("name") + ".zip"
|
||||
cloneof = game.getAttribute("cloneof")
|
||||
isbios = game.getAttribute("isbios")
|
||||
romof = game.getAttribute("romof")
|
||||
manufacturer = game.getElementsByTagName("manufacturer")[0]
|
||||
description = game.getElementsByTagName("description")[0]
|
||||
driver = game.getElementsByTagName("driver")
|
||||
@@ -146,6 +149,11 @@ if (
|
||||
ignored_games.append(description.firstChild.data)
|
||||
isignored = True
|
||||
|
||||
for ignore_element in ignore_system:
|
||||
if ignore_element.casefold() in romof.casefold():
|
||||
ignored_games.append(description.firstChild.data)
|
||||
isignored = True
|
||||
|
||||
if not isignored:
|
||||
src = os.path.join(args.input, name)
|
||||
if args.sort:
|
||||
@@ -163,7 +171,7 @@ if (
|
||||
if os.path.isfile(src):
|
||||
shutil.copyfile(src, dst)
|
||||
copied_games.append(description.firstChild.data)
|
||||
print(description.firstChild.data)
|
||||
print(description.firstChild.data, '==>', game.getAttribute("name") + ".zip")
|
||||
else:
|
||||
notfound.append(description.firstChild.data)
|
||||
|
||||
@@ -196,6 +204,7 @@ if (
|
||||
name = game.getAttribute("name") + ".zip"
|
||||
cloneof = game.getAttribute("cloneof")
|
||||
isbios = game.getAttribute("isbios")
|
||||
romof = game.getAttribute("romof")
|
||||
manufacturer = game.getElementsByTagName("manufacturer")[0]
|
||||
description = game.getElementsByTagName("description")[0]
|
||||
driver = game.getElementsByTagName("driver")
|
||||
@@ -211,6 +220,11 @@ if (
|
||||
ignored_games.append(description.firstChild.data)
|
||||
isignored = True
|
||||
|
||||
for ignore_element in ignore_system:
|
||||
if ignore_element.casefold() in romof.casefold():
|
||||
ignored_games.append(description.firstChild.data)
|
||||
isignored = True
|
||||
|
||||
if not isignored:
|
||||
src = os.path.join(args.input, name)
|
||||
if args.sort:
|
||||
|
||||
Reference in New Issue
Block a user