Skip to content

Commit

Permalink
E
Browse files Browse the repository at this point in the history
  • Loading branch information
BallisticCrusader committed Mar 8, 2024
1 parent 2c1efd2 commit 6e4bb7c
Showing 1 changed file with 20 additions and 12 deletions.
32 changes: 20 additions & 12 deletions web/matchscout.html
Original file line number Diff line number Diff line change
Expand Up @@ -210,17 +210,24 @@ <h3 id="teamPosition">Position: </h3>
clearFields()

if(data != ''){
matchData = jsonpack.unpack(data)
blueScore.value = matchData.blueScore
robotCondition.value = matchData.robotCondition
autoPerformance.value = matchData.autoPerformance
teleopPerformance.value = matchData.teleopPerformance
overallPerformance.value = matchData.overallPerformance
redScore.value = matchData.redScore
scoreArea.value = matchData.scoreArea
endState.value = matchData.endState
teamNotes.value = matchData.notes
try{
matchData = jsonpack.unpack(data)
blueScore.value = matchData.blueScore
robotCondition.value = matchData.robotCondition
autoPerformance.value = matchData.autoPerformance
teleopPerformance.value = matchData.teleopPerformance
overallPerformance.value = matchData.overallPerformance
redScore.value = matchData.redScore
scoreArea.value = matchData.scoreArea
endState.value = matchData.endState
teamNotes.value = matchData.notes
try {
if (matchData.version != 1) {
alert("Out of date data.")
}
} catch {
alert("Out of date data.")
}
try{
autoNotes.value = matchData.autoNotes
teleopNotes.value = matchData.teleopNotes
}catch{
Expand Down Expand Up @@ -312,7 +319,8 @@ <h3 id="teamPosition">Position: </h3>
redScore: Number(redScore.value),
autoNotes: Number(autoNotes.value),
teleopNotes: Number(teleopNotes.value),
notes: teamNotes.value
notes: teamNotes.value,
version: 1
})
socket.emit('writeToFile', selEvent, `matchscout-${matches.key}_qm${(curMatch+1)}-${curPosition}.jsonpack`, data)
alert('Saved!')
Expand Down

0 comments on commit 6e4bb7c

Please sign in to comment.