-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscore.html
81 lines (69 loc) · 1.6 KB
/
score.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<!DOCTYPE html>
<html>
<head>
<title>SCORE</title>
<style>
body{
font-size: 30px;
}
#C{
margin-left: auto;
}
#L{
width: 250px;
float: left;
}
#R{
width: 250px;
float: left;
}
.buttonRED {
background-color: red;
border: none;
color: white;
padding: 40px 40px;
text-align: center;
font-size: 20px;
cursor: pointer;
}
.buttonGREEN {
background-color: green;
border: none;
color: white;
padding: 40px 40px;
text-align: center;
font-size: 20px;
cursor: pointer;
}
.button:hover {
background-color: green;
}
</style>
</head>
<body>
<script>
var finalScoreRed = 0;
var finalScoreBlue = 0;
function setRed(){
finalScoreRed = document.getElementById('finalScoreRed').value;
NetworkTables.putValue('/SmartDashboard/finalScoreRed', finalScoreRed);
}
function setBlue(){
finalScoreBlue = document.getElementById('finalScoreBlue').value;
NetworkTables.putValue('/SmartDashboard/finalScoreBlue', finalScoreBlue);
}
</script>
<div id="C">
<div id="L">
Final Score Red
<input type="text" id="finalScoreRed" value="0" size=10 style="font-size:36pt;height:120px;width:200px;text-align:center;"> </input>
<button id="red" onclick="setRed();" style="font-size:100%;height:60px;width:204px;">Set Score</button>
</div>
<div id="R">
Final Score Blue
<input type="text" id="finalScoreBlue" value="0" size=10 style="font-size:36pt;height:120px;width:200px;text-align:center;"> </input>
<button id="blue" onclick="setBlue();" style="font-size:100%;height:60px;width:204px;">Set Score</button>
</div>
</div>
</body>
</html>