Don't perform newly added actions if player is paused (#539)

This commit is contained in:
Eoghan Murray
2021-04-18 07:15:57 +01:00
committed by GitHub
parent fbfb96297d
commit 7c5e15d607

View File

@@ -242,7 +242,7 @@ export function createPlayerService(
const castFn = getCastFn(event, isSync);
if (isSync) {
castFn();
} else {
} else if (timer.isActive()) {
timer.addAction({
doAction: () => {
castFn();
@@ -250,9 +250,6 @@ export function createPlayerService(
},
delay: event.delay!,
});
if (!timer.isActive()) {
timer.start();
}
}
}
return { ...ctx, events };