diff Engine/Spells/CastSpellInfo.cpp @ 2534:1bcadc6dd203

enum SOUND_
author Ritor1
date Mon, 09 Feb 2015 19:17:12 +0600
parents a77c34acdbc9
children a902abdfc7f2
line wrap: on
line diff
--- a/Engine/Spells/CastSpellInfo.cpp	Mon Jan 19 23:10:30 2015 +0600
+++ b/Engine/Spells/CastSpellInfo.cpp	Mon Feb 09 19:17:12 2015 +0600
@@ -251,7 +251,7 @@
         pTurnEngine->ApplyPlayerAction();
       }
       ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // "Spell failed"
-      pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+      pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
       pCastSpellInfo[n].uSpellID = 0;
       pPlayer->sMana -= uRequiredMana;
       return;
@@ -369,7 +369,7 @@
         if ( _v733 > amount )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -407,7 +407,7 @@
         if (!a2)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -499,7 +499,7 @@
         if ( !MonsterStats::BelongsToSupertype(pActors[PID_ID(a2)].pMonsterInfo.uID, MONSTER_SUPERTYPE_UNDEAD) )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -589,7 +589,7 @@
           || uCurrentlyLoadedLevelType == LEVEL_Outdoor && (pParty->uCurrentHour < 5 || pParty->uCurrentHour >= 21) )//только в дневное время
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -765,7 +765,7 @@
         _50C9D4_AfterEnchClickEventSecondParam = 0;
         _50C9D8_AfterEnchClickEventTimeout = 1;
         ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-        pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+        pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
         pCastSpell->uSpellID = 0;
         continue;
       }
@@ -937,7 +937,7 @@
           else
           {
             ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2);//"Не получилось!!!"
-            pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+            pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
             pCastSpell->uSpellID = 0;
           }
         }
@@ -1014,7 +1014,7 @@
         if ( uCurrentlyLoadedLevelType == LEVEL_Indoor)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[491], 2);  // Can't cast Meteor Shower indoors!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -1084,7 +1084,7 @@
         if ( uCurrentlyLoadedLevelType == LEVEL_Outdoor)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[492], 2); // Can't cast Inferno outdoors!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -1206,7 +1206,7 @@
         if ( pParty->uFlags & PARTY_FLAGS_1_FALLING)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[493], 2);  // Can't cast Jump while airborne!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           break;
         }
         if ( !pPlayer->CanCastSpell(uRequiredMana) )
@@ -1232,7 +1232,7 @@
         if (pParty->uFlags & (PARTY_FLAGS_1_ALERT_RED | PARTY_FLAGS_1_ALERT_YELLOW))
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[638], 2);  // There are hostile creatures nearby!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -1253,13 +1253,13 @@
         if ( uCurrentlyLoadedLevelType == LEVEL_Indoor)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[494], 2);  // Can not cast Fly indoors!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           break;
         }
         if ( !pPlayers[pCastSpell->uPlayerID + 1]->GetMaxMana() )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2);  // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           break;
         }
         if ( skill_level == 1 || skill_level == 2 || skill_level == 3 )
@@ -1281,7 +1281,7 @@
         if ( uCurrentlyLoadedLevelType == LEVEL_Indoor)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[495], 2);  // Can't cast Starburst indoors!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -1458,7 +1458,7 @@
         if ( !pPlayers[pCastSpell->uPlayerID + 1]->GetMaxMana() )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2);  // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           break;
         }
         switch (skill_level)
@@ -1495,7 +1495,7 @@
           _50C9D4_AfterEnchClickEventSecondParam = 0;
           _50C9D8_AfterEnchClickEventTimeout = 1;
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2);  // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -1519,7 +1519,7 @@
           _50C9D4_AfterEnchClickEventSecondParam = 0;
           _50C9D8_AfterEnchClickEventTimeout = 1;
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2);//Не получилось!!!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           spell_level = v723;
           continue;
@@ -1682,7 +1682,7 @@
           if ( item_not_broken == false )
             v317 = pGlobalTXT_LocalizationStrings[585];//Предмет недостаточно высокого качества
           ShowStatusBarString(v317, 2);
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           //v318 =  &pParty->pPlayers[pCastSpell->uPlayerID_2];
           pCastSpell->uSpellID = 0;
           pParty->pPlayers[pCastSpell->uPlayerID_2].PlaySound(SPEECH_43, 0);
@@ -1698,7 +1698,7 @@
           || rand() % 100 >= amount && skill_level != 4 )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -1712,7 +1712,7 @@
         if ( !_stricmp(pCurrentMapName, "d05.blv") ) // Arena
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -1791,7 +1791,7 @@
         if ( uCurrentlyLoadedLevelType == LEVEL_Indoor)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -2647,7 +2647,7 @@
         if ( mon_num >= amount )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[648], 2);  // This character can't summon any more monsters!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -2684,7 +2684,7 @@
         if ( uCurrentlyLoadedLevelType == LEVEL_Outdoor)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[497], 2);  // Can't cast Prismatic Light outdoors!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -2800,7 +2800,7 @@
         if ( pPlayer->uNumDivineInterventionCastsThisDay >= 3 )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -2851,7 +2851,7 @@
         if ( mon_id == -1 )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[496], 2);  // No valid target exists!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -2859,7 +2859,7 @@
          ||  pActors[mon_id].uAIState != Dead && pActors[mon_id].uAIState != Dying )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -2926,7 +2926,7 @@
           _50C9D4_AfterEnchClickEventSecondParam = 0;
           _50C9D8_AfterEnchClickEventTimeout = 1;
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -3012,7 +3012,7 @@
           if ( !pActors[mon_id].DoesDmgTypeDoDamage((DAMAGE_TYPE)10) )
           {
             ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-            pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+            pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
             pCastSpell->uSpellID = 0;
             continue;
           }
@@ -3074,7 +3074,7 @@
            || achieved_awards[pCastSpell->uPlayerID_2 - 4] <= 0 || achieved_awards[pCastSpell->uPlayerID_2 - 4] >= 3 )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -3188,7 +3188,7 @@
         if ( uCurrentlyLoadedLevelType == LEVEL_Indoor)
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[499], 2);  // Can't cast Armageddon indoors!
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }
@@ -3199,7 +3199,7 @@
         if ( pPlayer->uNumArmageddonCasts >= amount || pParty->armageddon_timer > 0 )
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[428], 2); // Spell failed
-          pAudioPlayer->PlaySound(SOUND_PlayerCantCastSpell, 0, 0, -1, 0, 0, 0, 0);
+          pAudioPlayer->PlaySound(SOUND_spellfail0201, 0, 0, -1, 0, 0, 0, 0);
           pCastSpell->uSpellID = 0;
           continue;
         }