diff --git a/apps/WarriorHappy/src/app/match/[matchId].tsx b/apps/WarriorHappy/src/app/match/[matchId].tsx
index dcb30f0..2f08262 100644
--- a/apps/WarriorHappy/src/app/match/[matchId].tsx
+++ b/apps/WarriorHappy/src/app/match/[matchId].tsx
@@ -116,7 +116,16 @@ export default function Match() {
});
}}
/>
-
+ {
+ console.log("stuff", stuff);
+ rawUpdate.mutate({
+ ...key,
+ event_log: { ...godlyHistory, auto: stuff },
+ });
+ }}
+ />
@@ -129,7 +138,15 @@ export default function Match() {
});
}}
/>
-
+ {
+ rawUpdate.mutate({
+ ...key,
+ event_log: { ...godlyHistory, teleop: stuff },
+ });
+ }}
+ />
-
+ {
+ rawUpdate.mutate({
+ ...key,
+ event_log: { ...godlyHistory, endgame: stuff },
+ });
+ }}
+ />
)}
diff --git a/apps/WarriorHappy/src/app/match/components/Dangerous.tsx b/apps/WarriorHappy/src/app/match/components/Dangerous.tsx
index dc451dc..ff18766 100644
--- a/apps/WarriorHappy/src/app/match/components/Dangerous.tsx
+++ b/apps/WarriorHappy/src/app/match/components/Dangerous.tsx
@@ -1,8 +1,15 @@
import { View } from "react-native";
+import { UltimateHistory } from "../types";
import ActionButton from "./ActionButton";
-export default function Dangerous() {
+export default function Dangerous({
+ setUltimateHistory,
+ ultimateHistory,
+}: {
+ setUltimateHistory: (history: UltimateHistory) => void;
+ ultimateHistory: UltimateHistory;
+}) {
return (
console.log("DC")}
+ action={() => {
+ setUltimateHistory({
+ ...ultimateHistory,
+ log: [...ultimateHistory.log, "DISCONNECTED"],
+ } as UltimateHistory);
+ }}
label="Disconnected"
theme={"red"}
/>
console.log("Tippy lol")}
+ action={() => {
+ setUltimateHistory({
+ ...ultimateHistory,
+ log: [...ultimateHistory.log, "TIPP"],
+ } as UltimateHistory);
+ }}
label="Tipped Over"
theme={"red"}
/>
diff --git a/packages/api/src/router/scouting.ts b/packages/api/src/router/scouting.ts
index 9205e84..f98b674 100644
--- a/packages/api/src/router/scouting.ts
+++ b/packages/api/src/router/scouting.ts
@@ -72,7 +72,8 @@ export const scoutingRouter = createTRPCRouter({
// biome-ignore lint/style/noNonNullAssertion: The match should be guaranteed to map to a singular event
eventKey: x.matches!.event,
// biome-ignore lint/style/noNonNullAssertion: see above
- eventName: x.matches!.events[0].name,
+
+ eventName: x.matches!.events?.name, // @ts-ignore
// biome-ignore lint/style/noNonNullAssertion: see above
team: parseInt(x.team.match(/\d+/)![0]),
red: redTeams,