Jon Solow
commited on
Commit
·
d9c420f
1
Parent(s):
b4d2f11
Round integer scoring
Browse files
src/pages/11_Scoreboard.py
CHANGED
@@ -91,7 +91,7 @@ def get_roster_html_str(
|
|
91 |
def get_player_html_str(
|
92 |
player_opt: PlayerOption, player_stats: dict[str, float], player_score: float, multiplier: int
|
93 |
) -> str:
|
94 |
-
score = player_score * float(multiplier)
|
95 |
if player_opt.week and player_opt.team:
|
96 |
game_map = get_schedule_with_live().get(player_opt.week, {}).get(player_opt.team, {})
|
97 |
else:
|
@@ -190,7 +190,7 @@ def assemble_user_scores(
|
|
190 |
week = int(roster_key[0])
|
191 |
player_score = player_scores_map.get(week, {}).get(player_id.gsis_id, 0.0)
|
192 |
multiplier = float(multiplier_map.get(user_id, {}).get(week, {}).get(player_id.gsis_id, 1))
|
193 |
-
user_score_map[week] += player_score * multiplier
|
194 |
for week, week_score in user_score_map.items():
|
195 |
week_user_score_map[week][user_id] = week_score
|
196 |
return week_user_score_map
|
|
|
91 |
def get_player_html_str(
|
92 |
player_opt: PlayerOption, player_stats: dict[str, float], player_score: float, multiplier: int
|
93 |
) -> str:
|
94 |
+
score = round(player_score * float(multiplier), 0)
|
95 |
if player_opt.week and player_opt.team:
|
96 |
game_map = get_schedule_with_live().get(player_opt.week, {}).get(player_opt.team, {})
|
97 |
else:
|
|
|
190 |
week = int(roster_key[0])
|
191 |
player_score = player_scores_map.get(week, {}).get(player_id.gsis_id, 0.0)
|
192 |
multiplier = float(multiplier_map.get(user_id, {}).get(week, {}).get(player_id.gsis_id, 1))
|
193 |
+
user_score_map[week] += round(player_score * multiplier, 0)
|
194 |
for week, week_score in user_score_map.items():
|
195 |
week_user_score_map[week][user_id] = week_score
|
196 |
return week_user_score_map
|