diff --git a/source/blood/src/actor.cpp b/source/blood/src/actor.cpp index 370f75cbb..f11a130e2 100644 --- a/source/blood/src/actor.cpp +++ b/source/blood/src/actor.cpp @@ -3137,6 +3137,8 @@ void actKillDude(int nKillerSprite, spritetype *pSprite, DAMAGE_TYPE damageType, case kDudeCultistShotgun: case kDudeCultistTesla: case kDudeCultistTNT: + if (!VanillaMode()) // kill all cultist idle alerts on death + sfxKill3DSound(pSprite, 16384+pSprite->index, -1); sfxPlay3DSound(pSprite, 1018+Random(2), -1, 0); if (nSeq == 3) seqSpawn(dudeInfo[nType].seqStartID+nSeq, 3, nXSprite, nDudeToGibClient2); diff --git a/source/blood/src/ai.cpp b/source/blood/src/ai.cpp index 94e6e0d2a..c16889716 100644 --- a/source/blood/src/ai.cpp +++ b/source/blood/src/ai.cpp @@ -379,8 +379,9 @@ void aiActivateDude(spritetype *pSprite, XSPRITE *pXSprite) case kMediumNormal: aiNewState(pSprite, pXSprite, &cultistSearch); if (Chance(0x8000)) { - if (pSprite->type == kDudeCultistTommy) aiPlay3DSound(pSprite, 4008+Random(5), AI_SFX_PRIORITY_1, -1); - else aiPlay3DSound(pSprite, 1008+Random(5), AI_SFX_PRIORITY_1, -1); + const int nChannel = !VanillaMode() ? 16384+pSprite->index : -1; + if (pSprite->type == kDudeCultistTommy) aiPlay3DSound(pSprite, 4008+Random(5), AI_SFX_PRIORITY_1, nChannel); + else aiPlay3DSound(pSprite, 1008+Random(5), AI_SFX_PRIORITY_1, nChannel); } break; case kMediumWater: @@ -390,8 +391,9 @@ void aiActivateDude(spritetype *pSprite, XSPRITE *pXSprite) } } else { if (Chance(0x8000)) { - if (pSprite->type == kDudeCultistTommy) aiPlay3DSound(pSprite, 4003+Random(4), AI_SFX_PRIORITY_1, -1); - else aiPlay3DSound(pSprite, 1003+Random(4), AI_SFX_PRIORITY_1, -1); + const int nChannel = !VanillaMode() ? 16384+pSprite->index : -1; + if (pSprite->type == kDudeCultistTommy) aiPlay3DSound(pSprite, 4003+Random(4), AI_SFX_PRIORITY_1, nChannel); + else aiPlay3DSound(pSprite, 1003+Random(4), AI_SFX_PRIORITY_1, nChannel); } switch (pXSprite->medium) { case kMediumNormal: @@ -412,6 +414,7 @@ void aiActivateDude(spritetype *pSprite, XSPRITE *pXSprite) return; #endif case kDudeCultistTommyProne: { + const int nChannel = !VanillaMode() ? 16384+pSprite->index : -1; DUDEEXTRA_STATS *pDudeExtraE = &gDudeExtra[pSprite->extra].stats; pDudeExtraE->active = 1; pSprite->type = kDudeCultistTommy; @@ -420,7 +423,7 @@ void aiActivateDude(spritetype *pSprite, XSPRITE *pXSprite) case 0: aiNewState(pSprite, pXSprite, &cultistSearch); if (Chance(0x8000)) - aiPlay3DSound(pSprite, 4008+Random(5), AI_SFX_PRIORITY_1, -1); + aiPlay3DSound(pSprite, 4008+Random(5), AI_SFX_PRIORITY_1, nChannel); break; case kMediumWater: case kMediumGoo: @@ -429,8 +432,7 @@ void aiActivateDude(spritetype *pSprite, XSPRITE *pXSprite) } } else { if (Chance(0x8000)) - aiPlay3DSound(pSprite, 4008+Random(5), AI_SFX_PRIORITY_1, -1); - + aiPlay3DSound(pSprite, 4008+Random(5), AI_SFX_PRIORITY_1, nChannel); switch (pXSprite->medium) { case kMediumNormal: aiNewState(pSprite, pXSprite, &cultistProneChase); @@ -445,6 +447,7 @@ void aiActivateDude(spritetype *pSprite, XSPRITE *pXSprite) } case kDudeCultistShotgunProne: { + const int nChannel = !VanillaMode() ? 16384+pSprite->index : -1; DUDEEXTRA_STATS *pDudeExtraE = &gDudeExtra[pSprite->extra].stats; pDudeExtraE->active = 1; pSprite->type = kDudeCultistShotgun; @@ -455,7 +458,7 @@ void aiActivateDude(spritetype *pSprite, XSPRITE *pXSprite) case kMediumNormal: aiNewState(pSprite, pXSprite, &cultistSearch); if (Chance(0x8000)) - aiPlay3DSound(pSprite, 1008+Random(5), AI_SFX_PRIORITY_1, -1); + aiPlay3DSound(pSprite, 1008+Random(5), AI_SFX_PRIORITY_1, nChannel); break; case kMediumWater: case kMediumGoo: @@ -466,7 +469,7 @@ void aiActivateDude(spritetype *pSprite, XSPRITE *pXSprite) else { if (Chance(0x8000)) - aiPlay3DSound(pSprite, 1003+Random(4), AI_SFX_PRIORITY_1, -1); + aiPlay3DSound(pSprite, 1003+Random(4), AI_SFX_PRIORITY_1, nChannel); switch (pXSprite->medium) { case kMediumNormal: