From c2da0b54ecfb751a6ec7a0e0d76128478766d7d8 Mon Sep 17 00:00:00 2001 From: Richard Helgeby Date: Thu, 20 Sep 2012 11:41:21 +0200 Subject: [PATCH] Fixed hint text sound not precached error in CS: GO. --- src/zr/spawnprotect.inc | 1 - src/zr/translation.inc | 6 ++++++ src/zr/zhp.inc | 1 - 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/zr/spawnprotect.inc b/src/zr/spawnprotect.inc index b342b70..d2dd238 100644 --- a/src/zr/spawnprotect.inc +++ b/src/zr/spawnprotect.inc @@ -173,7 +173,6 @@ SpawnProtectStart(client) // Send time left in a hud message. TranslationPrintHintText(client, "Spawn Protect", pSpawnProtectTime[client]); - StopSound(client, SNDCHAN_STATIC, "UI/hint.wav"); // Start repeating timer. tSpawnProtect[client] = CreateTimer(1.0, SpawnProtectTimer, client, TIMER_FLAG_NO_MAPCHANGE|TIMER_REPEAT); diff --git a/src/zr/translation.inc b/src/zr/translation.inc index 9e72e1c..da4896a 100644 --- a/src/zr/translation.inc +++ b/src/zr/translation.inc @@ -331,6 +331,12 @@ stock TranslationPrintHintText(client, any:...) // Print translated phrase to client. PrintHintText(client, translation); + + // Stop hint text sound in CS:S. + if (g_Game == Game_CSS) + { + StopSound(client, SNDCHAN_STATIC, "UI/hint.wav"); + } } /** diff --git a/src/zr/zhp.inc b/src/zr/zhp.inc index 2c461c8..b58b560 100644 --- a/src/zr/zhp.inc +++ b/src/zr/zhp.inc @@ -250,7 +250,6 @@ ZHPUpdateHUD(client) // Display HP TranslationPrintHintText(client, "Display HP", health); - StopSound(client, SNDCHAN_STATIC, "UI/hint.wav"); } /**