From 23aea6badf83c8ad6d36ae40aa0d3d86ccddc79f Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Sat, 15 Mar 2025 19:06:29 -0400 Subject: [PATCH] More fixes for scoreboard. --- scoreboard.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/scoreboard.py b/scoreboard.py index 9b13ddd..831e514 100644 --- a/scoreboard.py +++ b/scoreboard.py @@ -37,7 +37,7 @@ class Scoreboard: try: # Try to use configService - self.configService.local_config.add_section("scoreboard") + self.configService.localConfig.add_section("scoreboard") except: # Fallback to old method try: @@ -49,8 +49,8 @@ class Scoreboard: for i in range(1, 11): try: # Try to use configService - score = self.configService.local_config.getint("scoreboard", f"score_{i}") - name = self.configService.local_config.get("scoreboard", f"name_{i}") + score = self.configService.localConfig.getint("scoreboard", f"score_{i}") + name = self.configService.localConfig.get("scoreboard", f"name_{i}") self.highScores.append({ 'name': name, 'score': score @@ -77,7 +77,7 @@ class Scoreboard: """Get current score.""" return self.currentScore - def get_highScores(self): + def get_high_scores(self): """Get list of high scores.""" return self.highScores @@ -146,8 +146,8 @@ class Scoreboard: try: # Try new method first for i, entry in enumerate(self.highScores): - self.configService.local_config.set("scoreboard", f"score_{i+1}", str(entry['score'])) - self.configService.local_config.set("scoreboard", f"name_{i+1}", entry['name']) + self.configService.localConfig.set("scoreboard", f"score_{i+1}", str(entry['score'])) + self.configService.localConfig.set("scoreboard", f"name_{i+1}", entry['name']) # Try to write with configService try: