WebHost: check for duplicate names

Generate: use Counter for duplicate names to make finding the dupes easier
This commit is contained in:
Fabian Dill
2022-02-14 04:58:21 +01:00
parent d7d1d54a0b
commit 3fc93a33c8
3 changed files with 4 additions and 4 deletions

View File

@@ -14,7 +14,7 @@ ModuleUpdate.update()
import Utils
from worlds.alttp import Options as LttPOptions
from worlds.generic import PlandoItem, PlandoConnection
from worlds.generic import PlandoConnection
from Utils import parse_yaml, version_tuple, __version__, tuplize_version, get_options
from worlds.alttp.EntranceRandomizer import parse_arguments
from Main import main as ERmain
@@ -180,7 +180,7 @@ def main(args=None, callback=ERmain):
erargs.name[player] = handle_name(erargs.name[player], player, name_counter)
if len(set(erargs.name.values())) != len(erargs.name):
raise Exception(f"Names have to be unique. Names: {erargs.name}")
raise Exception(f"Names have to be unique. Names: {Counter(erargs.name.values())}")
if args.yaml_output:
import yaml