Merge remote-tracking branch 'upstream/redacted' into redacted
This commit is contained in:
commit
e22b271248
|
@ -44,6 +44,8 @@ def update_loop():
|
||||||
state["update_text"] = "Play blall!" #they also need a timestamp
|
state["update_text"] = "Play blall!" #they also need a timestamp
|
||||||
state["delay"] -= 1
|
state["delay"] -= 1
|
||||||
|
|
||||||
|
state["display_top_of_inning"] = state["top_of_inning"]
|
||||||
|
|
||||||
if state["delay"] <= 0:
|
if state["delay"] <= 0:
|
||||||
if this_game.top_of_inning != state["top_of_inning"]:
|
if this_game.top_of_inning != state["top_of_inning"]:
|
||||||
state["update_pause"] = 2
|
state["update_pause"] = 2
|
||||||
|
@ -51,6 +53,7 @@ def update_loop():
|
||||||
state["batter"] = "-"
|
state["batter"] = "-"
|
||||||
if not state["top_of_inning"]:
|
if not state["top_of_inning"]:
|
||||||
state["display_inning"] -= 1
|
state["display_inning"] -= 1
|
||||||
|
state["display_top_of_inning"] = False
|
||||||
|
|
||||||
if state["update_pause"] == 1:
|
if state["update_pause"] == 1:
|
||||||
state["update_emoji"] = "🍿"
|
state["update_emoji"] = "🍿"
|
||||||
|
@ -100,4 +103,4 @@ def update_loop():
|
||||||
state["update_pause"] -= 1
|
state["update_pause"] -= 1
|
||||||
|
|
||||||
socketio.emit("states_update", states_to_send)
|
socketio.emit("states_update", states_to_send)
|
||||||
time.sleep(1)
|
time.sleep(3)
|
8
sql scripts/batting average leaders.sql
Normal file
8
sql scripts/batting average leaders.sql
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
SELECT name,
|
||||||
|
plate_appearances - (walks_taken + sacrifices) as atbats,
|
||||||
|
ROUND(hits*1.0 / (plate_appearances - (walks_taken + sacrifices)*1.0),3) as average,
|
||||||
|
ROUND(total_bases*1.0 / (plate_appearances - (walks_taken + sacrifices)*1.0),3) as slg,
|
||||||
|
ROUND((walks_taken + hits)*1.0/plate_appearances*1.0,3) as obp,
|
||||||
|
ROUND((walks_taken + hits)*1.0/plate_appearances*1.0,3) + ROUND(total_bases*1.0 / (plate_appearances - (walks_taken + sacrifices)*1.0),3) as ops
|
||||||
|
FROM stats WHERE plate_appearances > 50
|
||||||
|
ORDER BY ops DESC;
|
9
sql scripts/pitching leaders.sql
Normal file
9
sql scripts/pitching leaders.sql
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
SELECT name,
|
||||||
|
outs_pitched,
|
||||||
|
ROUND(runs_allowed*27.0/(outs_pitched*1.0),3) as era,
|
||||||
|
ROUND((walks_allowed+hits_allowed)*3.0/(outs_pitched*1.0),3) as whip,
|
||||||
|
ROUND(walks_allowed*27.0/(outs_pitched*1.0),3) as bbper9,
|
||||||
|
ROUND(strikeouts_given*27.0/(outs_pitched*1.0),3) as kper9,
|
||||||
|
ROUND(strikeouts_given*1.0/walks_allowed*1.0,3) as kperbb
|
||||||
|
FROM stats WHERE outs_pitched > 150
|
||||||
|
ORDER BY bbper9 ASC;
|
BIN
static/discord.png
Normal file
BIN
static/discord.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 8.9 KiB |
|
@ -1,4 +1,5 @@
|
||||||
@import url('https://fonts.googleapis.com/css2?family=Alegreya&display=swap');
|
@import url('https://fonts.googleapis.com/css2?family=Alegreya&display=swap');
|
||||||
|
@import url('https://fonts.googleapis.com/css2?family=Goldman:wght@700&display=swap');
|
||||||
body {
|
body {
|
||||||
background-image: url("prism.png");
|
background-image: url("prism.png");
|
||||||
}
|
}
|
||||||
|
@ -21,12 +22,23 @@ body {
|
||||||
grid-row: 1;
|
grid-row: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.link{
|
||||||
|
position: relative;
|
||||||
|
top: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
.h1 {
|
.h1 {
|
||||||
margin: auto;
|
margin: auto;
|
||||||
width: 45%;
|
width: 45%;
|
||||||
|
color: white;
|
||||||
font-family: 'Alegreya', serif;
|
font-family: 'Alegreya', serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.page_header {
|
||||||
|
color: white;
|
||||||
|
font-family: 'Goldman', cursive;
|
||||||
|
}
|
||||||
|
|
||||||
.emptyslot {
|
.emptyslot {
|
||||||
border: 2px dashed white;
|
border: 2px dashed white;
|
||||||
border-radius: 15px;
|
border-radius: 15px;
|
||||||
|
|
|
@ -54,7 +54,7 @@ $(document).ready(function (){
|
||||||
|
|
||||||
const updateGame = (gamediv, gamestate) => {
|
const updateGame = (gamediv, gamestate) => {
|
||||||
gamediv.id = "updateTarget";
|
gamediv.id = "updateTarget";
|
||||||
$('#updateTarget .inning').html("Inning: " + (gamestate.top_of_inning ? "🔼" : "🔽") + " " + gamestate.display_inning + "/" + gamestate.max_innings);
|
$('#updateTarget .inning').html("Inning: " + (gamestate.display_top_of_inning ? "🔼" : "🔽") + " " + gamestate.display_inning + "/" + gamestate.max_innings);
|
||||||
$('#updateTarget .weather').html(gamestate.weather_emoji + " " + gamestate.weather_text);
|
$('#updateTarget .weather').html(gamestate.weather_emoji + " " + gamestate.weather_text);
|
||||||
|
|
||||||
$('#updateTarget .away_name').html(gamestate.away_name);
|
$('#updateTarget .away_name').html(gamestate.away_name);
|
||||||
|
|
|
@ -11,8 +11,9 @@
|
||||||
<body>
|
<body>
|
||||||
<section class="container" id="container">
|
<section class="container" id="container">
|
||||||
<div></div>
|
<div></div>
|
||||||
<div class="emptyslot" id="title">
|
<div id="title">
|
||||||
<h1>game page ahoy</h1>
|
<h2 class="page_header">THE SIMMADOME</h2>
|
||||||
|
<h2 class="page_header">Join SIBR on <a href="https://discord.gg/UhAajY2NCW" class="link"><img src="static/discord.png" height="30"></a> to start your own games!</h2>
|
||||||
</div>
|
</div>
|
||||||
<div></div>
|
<div></div>
|
||||||
<div class="emptyslot"></div>
|
<div class="emptyslot"></div>
|
||||||
|
|
|
@ -57,6 +57,7 @@
|
||||||
<Content Include="games_config.json" />
|
<Content Include="games_config.json" />
|
||||||
<Content Include="ids" />
|
<Content Include="ids" />
|
||||||
<Content Include="matteo.db" />
|
<Content Include="matteo.db" />
|
||||||
|
<Content Include="static\discord.png" />
|
||||||
<Content Include="static\games_page.css" />
|
<Content Include="static\games_page.css" />
|
||||||
<Content Include="static\loader.js" />
|
<Content Include="static\loader.js" />
|
||||||
<Content Include="static\prism.png" />
|
<Content Include="static\prism.png" />
|
||||||
|
|
Loading…
Reference in New Issue
Block a user