Skip to content

Commit 6acb512

Browse files
fix: Only display "Watching Replay" in spectate HUD
This is a temporary change until we are able to distinguish between spectating a replay and a player
1 parent 71b9508 commit 6acb512

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

scripts/hud/spectate.ts

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,16 @@ class HudSpectateHandler {
1212
toggleReplayControls: $('#ToggleReplayControls')
1313
};
1414

15-
/* TODO
1615
constructor() {
17-
$.RegisterForUnhandledEvent('MomentumSpectatorTargetChanged', (type: RunEntityType) =>
18-
this.onSpectatorChanged(type)
19-
);
16+
// TEMP: Hide spectate panel since we don't distinguish between replays and spectate yet
17+
this.panels.indicatorSpectating.visible = false;
18+
19+
// $.RegisterForUnhandledEvent('MomentumSpectatorTargetChanged', (type: RunEntityType) =>
20+
// this.onSpectatorChanged(type)
21+
// );
2022
}
2123

22-
onSpectatorChanged(type: RunEntityType) {
24+
/*onSpectatorChanged(type: RunEntityType) {
2325
if (type !== RunEntityType.PLAYER) {
2426
const isReplay = type === RunEntityType.REPLAY;
2527
@@ -31,6 +33,5 @@ class HudSpectateHandler {
3133
this.panels.toggleReplayControls.visible = isReplay;
3234
this.panels.indicatorWatchingReplay.visible = isReplay;
3335
}
34-
}
35-
*/
36+
}*/
3637
}

0 commit comments

Comments
 (0)