Don't play sounds when quick replaying in spectate mode
authorunc0rr
Fri, 02 Jan 2009 14:46:35 +0000
changeset 1562 c0eea030347b
parent 1561 f0af4e5fe880
child 1563 4ae873e854f8
Don't play sounds when quick replaying in spectate mode
hedgewars/uSound.pas
--- a/hedgewars/uSound.pas	Fri Jan 02 14:22:55 2009 +0000
+++ b/hedgewars/uSound.pas	Fri Jan 02 14:46:35 2009 +0000
@@ -83,7 +83,7 @@
 procedure PlaySound(snd: TSound; infinite: boolean);
 var loops: LongInt;
 begin
-if not isSoundEnabled then exit;
+if (not isSoundEnabled) or fastUntilLag then exit;
 if infinite then loops:= -1 else loops:= 0;
 Soundz[snd].lastChan:= Mix_PlayChannelTimed(-1, Soundz[snd].id, loops, -1)
 end;