Skip to content

Commit 51bbe4b

Browse files
authored
Bug/fix hero in english (#23)
* swap Mercy to Ange in fr.json and add unknow role * add hero in event for logo front and correct fr.json characters * add roles and fix bug in hero spawn/hero swap
1 parent c8d6c87 commit 51bbe4b

File tree

1 file changed

+9
-1
lines changed
  • src/log_analyser/objects

1 file changed

+9
-1
lines changed

src/log_analyser/objects/map.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,6 +251,14 @@ def find_character_name_in_english(self, character_name):
251251
with open(file_path, 'r', encoding='utf-8') as file:
252252
data = json.load(file)
253253
if character_name in data:
254-
return data[character_name] # Retourne la valeur associée au nom du personnage
254+
return data[character_name]
255+
256+
with open("log_analyser/roles/roles.json", 'r', encoding='utf-8') as file:
257+
data = json.load(file)
258+
for key, value in data.items():
259+
if character_name in value:
260+
return character_name
261+
262+
255263
print("Character name not found in english : ", character_name)
256264
return ""

0 commit comments

Comments
 (0)