2026-05-30 18:39:09 +01:00
|
|
|
from pcslive import LiveStats
|
2026-05-30 18:59:12 +01:00
|
|
|
import time
|
2026-05-30 18:39:09 +01:00
|
|
|
|
|
|
|
|
stats = LiveStats()
|
|
|
|
|
|
|
|
|
|
if len(stats.races) > 0:
|
|
|
|
|
race = stats.races[0]
|
|
|
|
|
print("Latest timeline update from", race.title, ":")
|
|
|
|
|
|
|
|
|
|
|
2026-05-30 18:59:12 +01:00
|
|
|
last_update = ""
|
|
|
|
|
while True:
|
|
|
|
|
race.get_timeline()
|
|
|
|
|
if last_update != race.timeline[0]:
|
|
|
|
|
print(race.timeline[0])
|
|
|
|
|
last_update = race.timeline[0]
|
|
|
|
|
time.sleep(10)
|