Nachalarmieren select

Alarmieren aus Einsatz erstellen Maske
Map-Tiles
SDS sound: Status J
SDS Nachricht: public-User
Audio: Es kann nur ein Nutzer gleichzeitig Funken
Select in Report und Chat: default value -> OnChange
This commit is contained in:
PxlLoewe
2025-06-09 01:10:39 -07:00
parent 1f8d9f1b72
commit ea78b41510
12 changed files with 114 additions and 195 deletions

View File

@@ -7,10 +7,12 @@ export const useSounds = ({
isReceiving,
isTransmitting,
unpausedTracks,
transmitBlocked,
}: {
isReceiving: boolean;
isTransmitting: boolean;
unpausedTracks: unknown[];
transmitBlocked?: boolean;
}) => {
const { room } = useAudioStore();
// Sounds as refs
@@ -56,6 +58,17 @@ export const useSounds = ({
}
}, [isReceiving, isTransmitting, soundConnectionStarted]);
useEffect(() => {
if (transmitBlocked && foreignCallBlocked.current) {
foreignCallBlocked.current.volume = 0.2;
foreignCallBlocked.current.currentTime = 0;
foreignCallBlocked.current.loop = true;
foreignCallBlocked.current.play().catch(() => {});
} else if (foreignCallBlocked.current) {
foreignCallBlocked.current.pause();
}
}, [transmitBlocked]);
useEffect(() => {
if (isTransmitting && connectionStart.current!.paused) {
ownCallStarted.current!.volume = 0.2;