Skip to content

Commit

Permalink
V0.0.6
Browse files Browse the repository at this point in the history
  • Loading branch information
domhnallmorr committed Mar 30, 2024
1 parent b2e37c7 commit 89a99f4
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
customtkinter.set_default_color_theme("blue") # Themes: blue (default), dark-blue, green

app = customtkinter.CTk() # create CTk window like you do with the Tk window
app.title("Race Engine V0.0.5")
app.title("Race Engine V0.0.6")
controller = race_engine_controller.RaceEngineController(app)

app.after(0, lambda:app.state("zoomed"))
Expand Down
16 changes: 11 additions & 5 deletions src/race_engine_view/custom_widgets/timing_screen_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,11 @@ def update_race(self, standings_df, race_fastest_laptime, fastest_lap_times=[],
if row["Status"] == "retired":
last_lap = "STOP"
else:
last_lap = self.view.milliseconds_to_minutes_seconds(row["Last Lap"])

if row["Last Lap"] != "-":
last_lap = self.view.milliseconds_to_minutes_seconds(row["Last Lap"])
else:
last_lap = "-"

if idx == 0:
interval = row["Lap"]
gap = "Lap"
Expand All @@ -60,9 +63,12 @@ def update_race(self, standings_df, race_fastest_laptime, fastest_lap_times=[],
gap = f"+{row['Lapped Status'].split()[1]}"
else:
gap = row["Gap to Leader"]/1000

fastest_lap = self.view.milliseconds_to_minutes_seconds(row["Fastest Lap"])


if row["Fastest Lap"] is not None:
fastest_lap = self.view.milliseconds_to_minutes_seconds(row["Fastest Lap"])
else:
fastest_lap = "-"

# CHECK IF DRIVER JUST SET FASTEST LAP
if race_fastest_laptime == row["Last Lap"]:
fastest_lap_driver = row["Driver"]
Expand Down

0 comments on commit 89a99f4

Please sign in to comment.