This commit is contained in:
Trxye 2021-05-27 16:08:09 -05:00
commit a6de3f6141
78 changed files with 2298 additions and 2209 deletions

View file

@ -455,7 +455,7 @@ void LaraControl(short itemNumber)
item->pos.yPos += 100; item->pos.yPos += 100;
UpdateLaraRoom(LaraItem, 0); UpdateLaraRoom(LaraItem, 0);
StopSoundEffect(SFX_LARA_FALL); StopSoundEffect(SFX_TR4_LARA_FALL);
if (item->currentAnimState == LS_SWANDIVE_START) if (item->currentAnimState == LS_SWANDIVE_START)
{ {
@ -600,7 +600,7 @@ void LaraControl(short itemNumber)
Lara.headXrot = 0; Lara.headXrot = 0;
UpdateLaraRoom(item, -381); UpdateLaraRoom(item, -381);
SoundEffect(SFX_LARA_BREATH, &LaraItem->pos, 2); SoundEffect(SFX_TR4_LARA_BREATH, &LaraItem->pos, 2);
} }
} }
} }
@ -622,7 +622,7 @@ void LaraControl(short itemNumber)
Lara.headXrot = 0; Lara.headXrot = 0;
UpdateLaraRoom(item, 0); UpdateLaraRoom(item, 0);
SoundEffect(SFX_LARA_BREATH, &LaraItem->pos, 2); SoundEffect(SFX_TR4_LARA_BREATH, &LaraItem->pos, 2);
} }
break; break;

View file

@ -366,7 +366,7 @@ void lara_as_stop(ITEM_INFO* item, COLL_INFO* coll)
} }
if (item->animNumber != LA_SPRINT_TO_STAND_RIGHT && item->animNumber != LA_SPRINT_TO_STAND_LEFT) if (item->animNumber != LA_SPRINT_TO_STAND_RIGHT && item->animNumber != LA_SPRINT_TO_STAND_LEFT)
StopSoundEffect(SFX_LARA_SLIPPING); StopSoundEffect(SFX_TR4_LARA_SLIPPING);
// Handles waterskin and clockwork beetle // Handles waterskin and clockwork beetle
if (UseSpecialItem(item)) if (UseSpecialItem(item))
@ -901,7 +901,7 @@ void lara_col_death(ITEM_INFO* item, COLL_INFO* coll)
{ {
/*state 8*/ /*state 8*/
/*state code: lara_as_death*/ /*state code: lara_as_death*/
StopSoundEffect(SFX_LARA_FALL); StopSoundEffect(SFX_TR4_LARA_FALL);
Lara.moveAngle = item->pos.yRot; Lara.moveAngle = item->pos.yRot;
coll->badPos = 384; coll->badPos = 384;
@ -926,7 +926,7 @@ void lara_as_fastfall(ITEM_INFO* item, COLL_INFO* coll)
/*collision: lara_col_fastfall*/ /*collision: lara_col_fastfall*/
item->speed = (item->speed * 95) / 100; item->speed = (item->speed * 95) / 100;
if (item->fallspeed == 154) if (item->fallspeed == 154)
SoundEffect(SFX_LARA_FALL, &item->pos, 0); SoundEffect(SFX_TR4_LARA_FALL, &item->pos, 0);
} }
void lara_col_fastfall(ITEM_INFO* item, COLL_INFO* coll) void lara_col_fastfall(ITEM_INFO* item, COLL_INFO* coll)
@ -957,7 +957,7 @@ void lara_col_fastfall(ITEM_INFO* item, COLL_INFO* coll)
item->frameNumber = g_Level.Anims[item->animNumber].frameBase; item->frameNumber = g_Level.Anims[item->animNumber].frameBase;
} }
StopSoundEffect(SFX_LARA_FALL); StopSoundEffect(SFX_TR4_LARA_FALL);
item->fallspeed = 0; item->fallspeed = 0;
item->gravityStatus = false; item->gravityStatus = false;

View file

@ -51,7 +51,7 @@ WEAPON_INFO Weapons[NUM_WEAPONS] =
9, 9,
3, 3,
0, 0,
SFX_LARA_FIRE, SFX_TR4_LARA_FIRE,
0 0
}, },
/* Revolver */ /* Revolver */
@ -67,7 +67,7 @@ WEAPON_INFO Weapons[NUM_WEAPONS] =
16, 16,
3, 3,
0, 0,
SFX_REVOLVER, SFX_TR4_DESSERT_EAGLE_FIRE,
0 0
}, },
/* Uzis */ /* Uzis */
@ -83,7 +83,7 @@ WEAPON_INFO Weapons[NUM_WEAPONS] =
3, 3,
3, 3,
0, 0,
SFX_LARA_UZI_FIRE, SFX_TR4_LARA_UZI_FIRE,
0 0
}, },
/* Shotgun */ /* Shotgun */
@ -99,7 +99,7 @@ WEAPON_INFO Weapons[NUM_WEAPONS] =
9, 9,
3, 3,
10, 10,
SFX_LARA_SHOTGUN, SFX_TR4_LARA_SHOTGUN,
0 0
}, },
/* HK */ /* HK */
@ -131,7 +131,7 @@ WEAPON_INFO Weapons[NUM_WEAPONS] =
0, 0,
2, 2,
10, 10,
SFX_LARA_CROSSBOW, SFX_TR4_LARA_CROSSBOW,
20 20
}, },
/* Flare */ /* Flare */
@ -163,7 +163,7 @@ WEAPON_INFO Weapons[NUM_WEAPONS] =
0, 0,
2, 2,
0, 0,
SFX_LARA_UZI_FIRE, SFX_TR4_LARA_UZI_FIRE,
0 0
}, },
/* Grenade launcher */ /* Grenade launcher */
@ -227,7 +227,7 @@ WEAPON_INFO Weapons[NUM_WEAPONS] =
0, 0,
0, 0,
0, 0,
SFX_LARA_UZI_FIRE, SFX_TR4_LARA_UZI_FIRE,
0 0
} }
}; };
@ -731,7 +731,7 @@ void HitTarget(ITEM_INFO* item, GAME_VECTOR* hitPos, int damage, int grenade)
if (item->objectNumber == ID_ROMAN_GOD1 || if (item->objectNumber == ID_ROMAN_GOD1 ||
item->objectNumber == ID_ROMAN_GOD2) item->objectNumber == ID_ROMAN_GOD2)
{ {
SoundEffect(SFX_SWORD_GOD_HITMET, &item->pos, 0); SoundEffect(SFX_TR5_SWORD_GOD_HITMET, &item->pos, 0);
} }
break; break;
@ -844,7 +844,7 @@ FireWeaponType FireWeapon(int weaponType, ITEM_INFO* target, ITEM_INFO* src, sho
target->hitPoints--; target->hitPoints--;
ricochet_angle = (mGetAngle(LaraItem->pos.zPos, LaraItem->pos.xPos, target->pos.zPos, target->pos.xPos) / 16) & 4095; ricochet_angle = (mGetAngle(LaraItem->pos.zPos, LaraItem->pos.xPos, target->pos.zPos, target->pos.xPos) / 16) & 4095;
TriggerRicochetSparks(&vDest, ricochet_angle, 16, 0); TriggerRicochetSparks(&vDest, ricochet_angle, 16, 0);
SoundEffect(SFX_LARA_RICOCHET, &target->pos, 0); // play RICOCHET Sample SoundEffect(SFX_TR4_LARA_RICOCHET, &target->pos, 0); // play RICOCHET Sample
} }
else if (target->objectNumber == ID_SHIVA) //So must be Shiva else if (target->objectNumber == ID_SHIVA) //So must be Shiva
{ {
@ -857,7 +857,7 @@ FireWeaponType FireWeapon(int weaponType, ITEM_INFO* target, ITEM_INFO* src, sho
target->hitStatus = true; //need to do this to maintain defence state target->hitStatus = true; //need to do this to maintain defence state
ricochet_angle = (mGetAngle(LaraItem->pos.zPos, LaraItem->pos.xPos, target->pos.zPos, target->pos.xPos) / 16) & 4095; ricochet_angle = (mGetAngle(LaraItem->pos.zPos, LaraItem->pos.xPos, target->pos.zPos, target->pos.xPos) / 16) & 4095;
TriggerRicochetSparks(&vDest, ricochet_angle, 16, 0); TriggerRicochetSparks(&vDest, ricochet_angle, 16, 0);
SoundEffect(SFX_LARA_RICOCHET, &target->pos, 0); // play RICOCHET Sample SoundEffect(SFX_TR4_LARA_RICOCHET, &target->pos, 0); // play RICOCHET Sample
} }
else //Shiva's not in defence mode or has its back to Lara else //Shiva's not in defence mode or has its back to Lara
HitTarget(target, &vDest, weapon->damage, 0); HitTarget(target, &vDest, weapon->damage, 0);

View file

@ -254,7 +254,7 @@ void draw_flare()
{ {
if (frame == 72) if (frame == 72)
{ {
SoundEffect(SFX_RAVESTICK, &LaraItem->pos, g_Level.Rooms[LaraItem->roomNumber].flags & ENV_FLAG_WATER); SoundEffect(SFX_TR4_OBJ_GEM_SMASH, &LaraItem->pos, g_Level.Rooms[LaraItem->roomNumber].flags & ENV_FLAG_WATER);
Lara.flareAge = 1; Lara.flareAge = 1;
} }

View file

@ -760,7 +760,7 @@ void lara_col_poledown(ITEM_INFO* item, COLL_INFO* coll)
} }
// CHECK // CHECK
SoundEffect(SFX_LARA_ROPEDOWN_LOOP, &item->pos, 0); SoundEffect(SFX_TR4_LARA_POLE_LOOP, &item->pos, 0);
if (item->itemFlags[2] < 0) if (item->itemFlags[2] < 0)
item->itemFlags[2] = 0; item->itemFlags[2] = 0;

View file

@ -766,8 +766,8 @@ void ControlGrenade(short itemNumber)
AlertNearbyGuards(item); AlertNearbyGuards(item);
SoundEffect(SFX_EXPLOSION1, &item->pos, PITCH_SHIFT | 0x1800000); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, PITCH_SHIFT | 0x1800000);
SoundEffect(SFX_EXPLOSION2, &item->pos, 0); SoundEffect(SFX_TR4_EXPLOSION2, &item->pos, 0);
// Setup the counter for spawned grenades in the case of flash and super grenades ammos // Setup the counter for spawned grenades in the case of flash and super grenades ammos
if (item->itemFlags[0] != GRENADE_NORMAL && item->itemFlags[0] != GRENADE_ULTRA) if (item->itemFlags[0] != GRENADE_NORMAL && item->itemFlags[0] != GRENADE_ULTRA)
@ -981,8 +981,8 @@ void ControlRocket(short itemNumber)
AlertNearbyGuards(item); AlertNearbyGuards(item);
SoundEffect(SFX_EXPLOSION1, &item->pos, PITCH_SHIFT | 0x1800000); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, PITCH_SHIFT | 0x1800000);
SoundEffect(SFX_EXPLOSION2, &item->pos, 0); SoundEffect(SFX_TR4_EXPLOSION2, &item->pos, 0);
ExplodeItemNode(item, 0, 0, EXPLODE_NORMAL); ExplodeItemNode(item, 0, 0, EXPLODE_NORMAL);
KillItem(itemNumber); KillItem(itemNumber);
@ -1155,12 +1155,12 @@ void AnimateShotgun(int weaponType)
if (Lara.Weapons[WEAPON_HK].HasSilencer) if (Lara.Weapons[WEAPON_HK].HasSilencer)
{ {
SoundEffect(SFX_HK_SILENCED, 0, 0); SoundEffect(SFX_TR5_HK_SILENCED, 0, 0);
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, &LaraItem->pos, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, &LaraItem->pos, 83888140);
SoundEffect(SFX_HK_FIRE, &LaraItem->pos, 0); SoundEffect(SFX_TR5_HK_FIRE, &LaraItem->pos, 0);
} }
} }
else else
@ -1176,8 +1176,8 @@ void AnimateShotgun(int weaponType)
// && HKFlag // && HKFlag
&& !(Lara.Weapons[WEAPON_HK].HasSilencer)) && !(Lara.Weapons[WEAPON_HK].HasSilencer))
{ {
StopSoundEffect(SFX_HK_FIRE); StopSoundEffect(SFX_TR5_HK_FIRE);
SoundEffect(SFX_HK_STOP, &LaraItem->pos, 0); SoundEffect(SFX_TR5_HK_STOP, &LaraItem->pos, 0);
// HKFlag = 0; // HKFlag = 0;
} }
} }
@ -1189,7 +1189,7 @@ void AnimateShotgun(int weaponType)
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, &LaraItem->pos, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, &LaraItem->pos, 83888140);
SoundEffect(SFX_HK_FIRE, &LaraItem->pos, 0); SoundEffect(SFX_HK_FIRE, &LaraItem->pos, 0);
} }
}*/ }*/
@ -1232,8 +1232,8 @@ void AnimateShotgun(int weaponType)
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, &LaraItem->pos, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, &LaraItem->pos, 83888140);
SoundEffect(SFX_HK_FIRE, &LaraItem->pos, 0); SoundEffect(SFX_TR5_HK_FIRE, &LaraItem->pos, 0);
} }
} }
else else
@ -1250,8 +1250,8 @@ void AnimateShotgun(int weaponType)
// && HKFlag // && HKFlag
&& !(Lara.Weapons[WEAPON_HK].HasSilencer)) && !(Lara.Weapons[WEAPON_HK].HasSilencer))
{ {
StopSoundEffect(SFX_HK_FIRE); StopSoundEffect(SFX_TR5_HK_FIRE);
SoundEffect(SFX_HK_STOP, &LaraItem->pos, 0); SoundEffect(SFX_TR5_HK_STOP, &LaraItem->pos, 0);
// HKFlag = 0; // HKFlag = 0;
} }
/* else if (HKFlag) /* else if (HKFlag)
@ -1262,7 +1262,7 @@ void AnimateShotgun(int weaponType)
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, &LaraItem->pos, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, &LaraItem->pos, 83888140);
SoundEffect(SFX_HK_FIRE, &LaraItem->pos, 0); SoundEffect(SFX_HK_FIRE, &LaraItem->pos, 0);
} }
}*/ }*/
@ -1500,8 +1500,8 @@ void ControlCrossbowBolt(short itemNumber)
AlertNearbyGuards(item); AlertNearbyGuards(item);
SoundEffect(SFX_EXPLOSION1, &item->pos, PITCH_SHIFT | 0x1800000); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, PITCH_SHIFT | 0x1800000);
SoundEffect(SFX_EXPLOSION2, &item->pos, 0); SoundEffect(SFX_TR4_EXPLOSION2, &item->pos, 0);
ExplodeItemNode(item, 0, 0, EXPLODE_NORMAL); ExplodeItemNode(item, 0, 0, EXPLODE_NORMAL);
KillItem(itemNumber); KillItem(itemNumber);
@ -1710,7 +1710,7 @@ void FireRocket()
AddActiveItem(itemNumber); AddActiveItem(itemNumber);
SoundEffect(SFX_EXPLOSION1, 0, 0); SoundEffect(SFX_TR4_EXPLOSION1, 0, 0);
Savegame.Level.AmmoUsed++; Savegame.Level.AmmoUsed++;
Savegame.Game.AmmoUsed++; Savegame.Game.AmmoUsed++;
@ -1982,7 +1982,7 @@ void FireShotgun()
Lara.rightArm.flash_gun = Weapons[WEAPON_SHOTGUN].flashTime; Lara.rightArm.flash_gun = Weapons[WEAPON_SHOTGUN].flashTime;
SoundEffect(SFX_EXPLOSION1, &LaraItem->pos, 20971524); SoundEffect(SFX_TR4_EXPLOSION1, &LaraItem->pos, 20971524);
SoundEffect(Weapons[WEAPON_SHOTGUN].sampleNum, &LaraItem->pos, 0); SoundEffect(Weapons[WEAPON_SHOTGUN].sampleNum, &LaraItem->pos, 0);
Savegame.Game.AmmoUsed++; Savegame.Game.AmmoUsed++;

View file

@ -85,7 +85,7 @@ void lara_slide_slope(ITEM_INFO* item, COLL_INFO* coll)
} }
else else
item->goalAnimState = LS_STOP; item->goalAnimState = LS_STOP;
StopSoundEffect(SFX_LARA_SLIPPING); StopSoundEffect(SFX_TR4_LARA_SLIPPING);
} }
} }
else else
@ -107,7 +107,7 @@ void lara_slide_slope(ITEM_INFO* item, COLL_INFO* coll)
item->goalAnimState = LS_FALL_BACK; item->goalAnimState = LS_FALL_BACK;
} }
StopSoundEffect(SFX_LARA_SLIPPING); StopSoundEffect(SFX_TR4_LARA_SLIPPING);
item->gravityStatus = true; item->gravityStatus = true;
item->fallspeed = 0; item->fallspeed = 0;

View file

@ -433,7 +433,7 @@ void UpdateSubsuitAngles()
if (Subsuit.Vel[0] != 0 || Subsuit.Vel[1] != 0) if (Subsuit.Vel[0] != 0 || Subsuit.Vel[1] != 0)
{ {
SoundEffect(SFX_LARA_UNDERWATER_ENGINE, &LaraItem->pos, (((Subsuit.Vel[0] + Subsuit.Vel[1]) * 4) & 0x1F00) + 10); SoundEffect(SFX_TR5_LARA_UNDERWATER_ENGINE, &LaraItem->pos, (((Subsuit.Vel[0] + Subsuit.Vel[1]) * 4) & 0x1F00) + 10);
} }
} }
@ -651,7 +651,7 @@ void LaraSwimCollision(ITEM_INFO* item, COLL_INFO* coll)
{ {
if (LaraDrawType == 5) if (LaraDrawType == 5)
{ {
SoundEffect(SFX_SWIMSUIT_METAL_CLASH, &LaraItem->pos, ((2 * GetRandomControl() + 0x8000) * 256) | 6); SoundEffect(SFX_TR5_SWIMSUIT_METAL_CLASH, &LaraItem->pos, ((2 * GetRandomControl() + 0x8000) * 256) | 6);
} }
if (Lara.anxiety < 96) if (Lara.anxiety < 96)

View file

@ -126,7 +126,7 @@ void AnimatePistols(int weaponType)
Lara.rightArm.flash_gun = weapon->flashTime; Lara.rightArm.flash_gun = weapon->flashTime;
SoundEffect(SFX_EXPLOSION1, &LaraItem->pos, PITCH_SHIFT | 0x2000000); SoundEffect(SFX_TR4_EXPLOSION1, &LaraItem->pos, PITCH_SHIFT | 0x2000000);
SoundEffect(weapon->sampleNum, &LaraItem->pos, 0); SoundEffect(weapon->sampleNum, &LaraItem->pos, 0);
soundPlayed = true; soundPlayed = true;
@ -224,7 +224,7 @@ void AnimatePistols(int weaponType)
if (!soundPlayed) if (!soundPlayed)
{ {
SoundEffect(SFX_EXPLOSION1, &LaraItem->pos, PITCH_SHIFT | 0x2000000); SoundEffect(SFX_TR4_EXPLOSION1, &LaraItem->pos, PITCH_SHIFT | 0x2000000);
SoundEffect(weapon->sampleNum, &LaraItem->pos, 0); SoundEffect(weapon->sampleNum, &LaraItem->pos, 0);
} }
@ -426,7 +426,7 @@ void undraw_pistols(int weaponType)
if (frameLeft == p->draw2Anim - 1) if (frameLeft == p->draw2Anim - 1)
{ {
undraw_pistol_mesh_left(weaponType); undraw_pistol_mesh_left(weaponType);
SoundEffect(SFX_LARA_HOLSTER_AWAY, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_HOLSTER, &LaraItem->pos, 0);
} }
} }
set_arm_info(&Lara.leftArm, frameLeft); set_arm_info(&Lara.leftArm, frameLeft);
@ -463,7 +463,7 @@ void undraw_pistols(int weaponType)
if (frameRight == p->draw2Anim - 1) if (frameRight == p->draw2Anim - 1)
{ {
undraw_pistol_mesh_right(weaponType); undraw_pistol_mesh_right(weaponType);
SoundEffect(SFX_LARA_HOLSTER_AWAY, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_HOLSTER, &LaraItem->pos, 0);
} }
} }
set_arm_info(&Lara.rightArm, frameRight); set_arm_info(&Lara.rightArm, frameRight);
@ -517,7 +517,7 @@ void draw_pistols(int weaponType)
else if (frame == p->draw2Anim) else if (frame == p->draw2Anim)
{ {
draw_pistol_meshes(weaponType); draw_pistol_meshes(weaponType);
SoundEffect(SFX_LARA_HOLSTER_DRAW, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_DRAW, &LaraItem->pos, 0);
} }
else if (frame == p->recoilAnim - 1) else if (frame == p->recoilAnim - 1)
{ {

View file

@ -816,8 +816,8 @@ void FixedCamera(ITEM_INFO* item)
|| !(GlobalCounter & 0x3F) || !(GlobalCounter & 0x3F)
|| objLos && !(GlobalCounter & 0xF) && GetRandomControl() & 1) || objLos && !(GlobalCounter & 0xF) && GetRandomControl() & 1)
{ {
SoundEffect(SFX_EXPLOSION1, 0, 83886084); SoundEffect(SFX_TR4_EXPLOSION1, 0, 83886084);
SoundEffect(SFX_HK_FIRE, 0, 0); SoundEffect(SFX_TR5_HK_FIRE, 0, 0);
FlashFadeR = 192; FlashFadeR = 192;
FlashFadeB = 0; FlashFadeB = 0;
@ -1291,7 +1291,7 @@ void BinocularCamera(ITEM_INFO* item)
if (BinocularRange < 128) if (BinocularRange < 128)
BinocularRange = 128; BinocularRange = 128;
else else
SoundEffect(SFX_ZOOM_VIEW_WHIRR, 0, (flags * 256) | 6); SoundEffect(SFX_TR5_ZOOM_VIEW_WHIRR, 0, (flags * 256) | 6);
} }
else if (InputBusy & IN_DUCK) else if (InputBusy & IN_DUCK)
{ {
@ -1299,7 +1299,7 @@ void BinocularCamera(ITEM_INFO* item)
if (BinocularRange > 1536) if (BinocularRange > 1536)
BinocularRange = 1536; BinocularRange = 1536;
else else
SoundEffect(SFX_ZOOM_VIEW_WHIRR, 0, (flags * 256) | 6); SoundEffect(SFX_TR5_ZOOM_VIEW_WHIRR, 0, (flags * 256) | 6);
} }
PHD_VECTOR src; PHD_VECTOR src;
@ -1350,12 +1350,12 @@ void BinocularCamera(ITEM_INFO* item)
firing = 1; firing = 1;
if (Lara.Weapons[WEAPON_HK].HasSilencer) if (Lara.Weapons[WEAPON_HK].HasSilencer)
{ {
SoundEffect(SFX_HK_SILENCED, 0, 0); SoundEffect(SFX_TR5_HK_SILENCED, 0, 0);
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, 0, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, 0, 83888140);
SoundEffect(SFX_HK_FIRE, 0, 0); SoundEffect(SFX_TR5_HK_FIRE, 0, 0);
} }
} }
else if (Lara.Weapons[WEAPON_HK].SelectedAmmo == WEAPON_AMMO2) else if (Lara.Weapons[WEAPON_HK].SelectedAmmo == WEAPON_AMMO2)
@ -1371,12 +1371,12 @@ void BinocularCamera(ITEM_INFO* item)
firing = 1; firing = 1;
if (Lara.Weapons[WEAPON_HK].HasSilencer) if (Lara.Weapons[WEAPON_HK].HasSilencer)
{ {
SoundEffect(SFX_HK_SILENCED, 0, 0); SoundEffect(SFX_TR5_HK_SILENCED, 0, 0);
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, 0, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, 0, 83888140);
SoundEffect(SFX_HK_FIRE, 0, 0); SoundEffect(SFX_TR5_HK_FIRE, 0, 0);
} }
} }
else else
@ -1385,12 +1385,12 @@ void BinocularCamera(ITEM_INFO* item)
if (Lara.Weapons[WEAPON_HK].HasSilencer) if (Lara.Weapons[WEAPON_HK].HasSilencer)
{ {
SoundEffect(SFX_HK_SILENCED, 0, 0); SoundEffect(SFX_TR5_HK_SILENCED, 0, 0);
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, 0, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, 0, 83888140);
SoundEffect(SFX_HK_FIRE, 0, 0); SoundEffect(SFX_TR5_HK_FIRE, 0, 0);
} }
} }
} }
@ -1400,12 +1400,12 @@ void BinocularCamera(ITEM_INFO* item)
{ {
if (Lara.Weapons[WEAPON_HK].HasSilencer) if (Lara.Weapons[WEAPON_HK].HasSilencer)
{ {
SoundEffect(SFX_HK_SILENCED, 0, 0); SoundEffect(SFX_TR5_HK_SILENCED, 0, 0);
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, 0, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, 0, 83888140);
SoundEffect(SFX_HK_FIRE, 0, 0); SoundEffect(SFX_TR5_HK_FIRE, 0, 0);
} }
} }
else else
@ -1414,12 +1414,12 @@ void BinocularCamera(ITEM_INFO* item)
firing = 1; firing = 1;
if (Lara.Weapons[WEAPON_HK].HasSilencer) if (Lara.Weapons[WEAPON_HK].HasSilencer)
{ {
SoundEffect(SFX_HK_SILENCED, 0, 0); SoundEffect(SFX_TR5_HK_SILENCED, 0, 0);
} }
else else
{ {
SoundEffect(SFX_EXPLOSION1, 0, 83888140); SoundEffect(SFX_TR4_EXPLOSION1, 0, 83888140);
SoundEffect(SFX_HK_FIRE, 0, 0); SoundEffect(SFX_TR5_HK_FIRE, 0, 0);
} }
} }
@ -1556,7 +1556,7 @@ void CalculateCamera()
//Camera is in a water room, play water sound effect. //Camera is in a water room, play water sound effect.
if ((g_Level.Rooms[Camera.pos.roomNumber].flags & ENV_FLAG_WATER)) if ((g_Level.Rooms[Camera.pos.roomNumber].flags & ENV_FLAG_WATER))
{ {
SoundEffect(SFX_UNDERWATER, NULL, SFX_ALWAYS); SoundEffect(SFX_TR4_UNDERWATER, NULL, SFX_ALWAYS);
if (Camera.underwater == 0) if (Camera.underwater == 0)
{ {
Camera.underwater = 1; Camera.underwater = 1;

View file

@ -635,7 +635,7 @@ int ItemPushLara(ITEM_INFO* item, ITEM_INFO* l, COLL_INFO* coll, int spazon, cha
if ((!Lara.hitFrame) && (!hitSoundTimer)) if ((!Lara.hitFrame) && (!hitSoundTimer))
{ {
SoundEffect(SFX_LARA_INJURY_RND, &l->pos, 0); SoundEffect(SFX_TR4_LARA_INJURY, &l->pos, 0);
hitSoundTimer = generateFloat(5, 15); hitSoundTimer = generateFloat(5, 15);
} }

View file

@ -63,24 +63,24 @@ using namespace T5M::Floordata;
short ShatterSounds[18][10] = short ShatterSounds[18][10] =
{ {
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_WOOD, SFX_SMASH_WOOD, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_WOOD, SFX_TR5_SMASH_WOOD, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_METAL, SFX_SMASH_METAL, SFX_SMASH_METAL, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_METAL, SFX_TR5_SMASH_METAL, SFX_TR5_SMASH_METAL, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_METAL, SFX_SMASH_METAL, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_METAL, SFX_TR5_SMASH_METAL, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_METAL, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_METAL, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_METAL, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_METAL, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}, {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS},
{SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS, SFX_SMASH_GLASS}}; {SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS, SFX_TR5_SMASH_GLASS}};
int KeyTriggerActive; int KeyTriggerActive;
int number_los_rooms; int number_los_rooms;
@ -2323,7 +2323,7 @@ int GetTargetOnLOS(GAME_VECTOR *src, GAME_VECTOR *dest, int DrawTarget, int firi
if (Lara.gunType == WEAPON_REVOLVER) if (Lara.gunType == WEAPON_REVOLVER)
{ {
SoundEffect(SFX_REVOLVER, NULL, 0); SoundEffect(SFX_TR4_DESSERT_EAGLE_FIRE, NULL, 0);
} }
} }
@ -3242,7 +3242,7 @@ void PlaySoundTrack(short track, short flags)
void RumbleScreen() void RumbleScreen()
{ {
if (!(GlobalCounter & 0x1FF)) if (!(GlobalCounter & 0x1FF))
SoundEffect(SFX_KLAXON, 0, 4104); SoundEffect(SFX_TR5_KLAXON, 0, 4104);
if (RumbleTimer >= 0) if (RumbleTimer >= 0)
RumbleTimer++; RumbleTimer++;
@ -3331,7 +3331,7 @@ int ExplodeItemNode(ITEM_INFO *item, int Node, int NoXZVel, int bits)
Num = bits; Num = bits;
if (item->objectNumber == ID_SHOOT_SWITCH1 && (CurrentLevel == 4 || CurrentLevel == 7)) // TODO: remove hardcoded think ! if (item->objectNumber == ID_SHOOT_SWITCH1 && (CurrentLevel == 4 || CurrentLevel == 7)) // TODO: remove hardcoded think !
{ {
SoundEffect(SFX_SMASH_METAL, &item->pos, 0); SoundEffect(SFX_TR5_SMASH_METAL, &item->pos, 0);
} }
else if (Num == 256) else if (Num == 256)
{ {

View file

@ -553,7 +553,7 @@ void DoorControl(short itemNumber)
else else
{ {
if (!item->itemFlags[0]) if (!item->itemFlags[0])
SoundEffect(SFX_LIFT_DOORS, &item->pos, 0); SoundEffect(SFX_TR5_LIFT_DOORS, &item->pos, 0);
item->itemFlags[0] += STEP_SIZE; item->itemFlags[0] += STEP_SIZE;
} }
} }
@ -562,7 +562,7 @@ void DoorControl(short itemNumber)
if (item->itemFlags[0] > 0) if (item->itemFlags[0] > 0)
{ {
if (item->itemFlags[0] == SECTOR(4)) if (item->itemFlags[0] == SECTOR(4))
SoundEffect(SFX_LIFT_DOORS, &item->pos, 0); SoundEffect(SFX_TR5_LIFT_DOORS, &item->pos, 0);
item->itemFlags[0] -= STEP_SIZE; item->itemFlags[0] -= STEP_SIZE;
} }
if (!door->opened) if (!door->opened)

View file

@ -240,7 +240,7 @@ void LaraLocation(ITEM_INFO* item)
void ExplosionFX(ITEM_INFO* item) void ExplosionFX(ITEM_INFO* item)
{ {
SoundEffect(SFX_EXPLOSION1, NULL, 0); SoundEffect(SFX_TR4_EXPLOSION1, NULL, 0);
Camera.bounce = -75; Camera.bounce = -75;
FlipEffect = -1; FlipEffect = -1;
} }
@ -265,7 +265,7 @@ void ActivateCamera(ITEM_INFO* item)
void PoseidonSFX(ITEM_INFO* item) void PoseidonSFX(ITEM_INFO* item)
{ {
SoundEffect(SFX_GRAB_OPEN, NULL, 0); SoundEffect(SFX_TR4_WATER_FLUSHES, NULL, 0);
FlipEffect = -1; FlipEffect = -1;
} }
@ -332,7 +332,7 @@ void ControlWaterfallMist(short itemNumber) // ControlWaterfallMist
z = item->pos.zPos - phd_cos(item->pos.yRot + ANGLE(180)) * 512 + phd_cos(item->pos.yRot - ANGLE(90)) * 256; z = item->pos.zPos - phd_cos(item->pos.yRot + ANGLE(180)) * 512 + phd_cos(item->pos.yRot - ANGLE(90)) * 256;
TriggerWaterfallMist(x, item->pos.yPos, z, item->pos.yRot + ANGLE(180)); TriggerWaterfallMist(x, item->pos.yPos, z, item->pos.yRot + ANGLE(180));
SoundEffect(SFX_WATERFALL_LOOP, &item->pos, 0); SoundEffect(SFX_TR4_WATERFALL_LOOP, &item->pos, 0);
} }
short DoBloodSplat(int x, int y, int z, short a4, short a5, short roomNumber) short DoBloodSplat(int x, int y, int z, short a4, short a5, short roomNumber)
@ -406,7 +406,7 @@ void Richochet(PHD_3DPOS* pos)
target.y = pos->yPos; target.y = pos->yPos;
target.z = pos->zPos; target.z = pos->zPos;
TriggerRicochetSpark(&target, angle / 16, 3, 0); TriggerRicochetSpark(&target, angle / 16, 3, 0);
SoundEffect(SFX_LARA_RICOCHET, pos, 0); SoundEffect(SFX_TR4_LARA_RICOCHET, pos, 0);
} }
void DoLotsOfBlood(int x, int y, int z, int speed, short direction, short roomNumber, int count) void DoLotsOfBlood(int x, int y, int z, int speed, short direction, short roomNumber, int count)

View file

@ -935,7 +935,7 @@ void SetupSplash(const SPLASH_SETUP* const setup,int room)
soundPosition.xRot = 0; soundPosition.xRot = 0;
soundPosition.zRot = 0; soundPosition.zRot = 0;
SoundEffect(SFX_LARA_SPLASH, &soundPosition, 0); SoundEffect(SFX_TR4_LARA_SPLASH, &soundPosition, 0);
} }
void UpdateSplashes() void UpdateSplashes()

View file

@ -163,7 +163,7 @@ void DoFlameTorch()
if (!(Wibble & 7)) if (!(Wibble & 7))
TriggerTorchFlame(LaraItem - g_Level.Items.data(), 0); TriggerTorchFlame(LaraItem - g_Level.Items.data(), 0);
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, (PHD_3DPOS*)&pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, (PHD_3DPOS*)&pos, 0);
TorchRoom = LaraItem->roomNumber; TorchRoom = LaraItem->roomNumber;
} }
@ -249,7 +249,7 @@ void TorchControl(short itemNumber)
if (!(Wibble & 7)) if (!(Wibble & 7))
TriggerTorchFlame(itemNumber, 1); TriggerTorchFlame(itemNumber, 1);
TorchRoom = item->roomNumber; TorchRoom = item->roomNumber;
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &item->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &item->pos, 0);
} }
} }

View file

@ -633,7 +633,7 @@ int Inventory::DoInventory()
// Handle input // Handle input
if (DbInput & IN_DESELECT) if (DbInput & IN_DESELECT)
{ {
//SoundEffect(SFX_MENU_SELECT, NULL, 0); //SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
// Exit from inventory // Exit from inventory
m_enterObject = NO_ITEM; m_enterObject = NO_ITEM;
@ -642,7 +642,7 @@ int Inventory::DoInventory()
} }
else if (DbInput & IN_FORWARD && (m_activeRing == INV_RING_WEAPONS && m_rings[INV_RING_PUZZLES].numObjects != 0 || m_activeRing == INV_RING_OPTIONS)) else if (DbInput & IN_FORWARD && (m_activeRing == INV_RING_WEAPONS && m_rings[INV_RING_PUZZLES].numObjects != 0 || m_activeRing == INV_RING_OPTIONS))
{ {
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
int newRing = INV_RING_WEAPONS; int newRing = INV_RING_WEAPONS;
if (m_activeRing == INV_RING_WEAPONS) if (m_activeRing == INV_RING_WEAPONS)
@ -657,7 +657,7 @@ int Inventory::DoInventory()
} }
else if (DbInput & IN_BACK && (m_activeRing == INV_RING_PUZZLES || m_activeRing == INV_RING_WEAPONS)) else if (DbInput & IN_BACK && (m_activeRing == INV_RING_PUZZLES || m_activeRing == INV_RING_WEAPONS))
{ {
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
int newRing = INV_RING_WEAPONS; int newRing = INV_RING_WEAPONS;
if (m_activeRing == INV_RING_WEAPONS) if (m_activeRing == INV_RING_WEAPONS)
@ -672,7 +672,7 @@ int Inventory::DoInventory()
} }
else if (TrInput & IN_LEFT) else if (TrInput & IN_LEFT)
{ {
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
// Change object left // Change object left
float deltaAngle = 360.0f / m_rings[m_activeRing].numObjects / INV_NUM_FRAMES_ROTATE; float deltaAngle = 360.0f / m_rings[m_activeRing].numObjects / INV_NUM_FRAMES_ROTATE;
@ -694,7 +694,7 @@ int Inventory::DoInventory()
} }
else if (TrInput & IN_RIGHT) else if (TrInput & IN_RIGHT)
{ {
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
// Change object right // Change object right
float deltaAngle = 360.0f / m_rings[m_activeRing].numObjects / INV_NUM_FRAMES_ROTATE; float deltaAngle = 360.0f / m_rings[m_activeRing].numObjects / INV_NUM_FRAMES_ROTATE;
@ -866,7 +866,7 @@ int Inventory::DoPuzzle()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex > 0) if (ring->selectedIndex > 0)
ring->selectedIndex--; ring->selectedIndex--;
} }
@ -874,13 +874,13 @@ int Inventory::DoPuzzle()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex < ring->numActions) if (ring->selectedIndex < ring->numActions)
ring->selectedIndex++; ring->selectedIndex++;
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (ring->actions[ring->selectedIndex] == INV_ACTION_USE) if (ring->actions[ring->selectedIndex] == INV_ACTION_USE)
{ {
@ -955,7 +955,7 @@ int Inventory::DoWeapon()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex > 0) if (ring->selectedIndex > 0)
ring->selectedIndex--; ring->selectedIndex--;
} }
@ -963,13 +963,13 @@ int Inventory::DoWeapon()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex < ring->numActions) if (ring->selectedIndex < ring->numActions)
ring->selectedIndex++; ring->selectedIndex++;
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (ring->actions[ring->selectedIndex] == INV_ACTION_USE) if (ring->actions[ring->selectedIndex] == INV_ACTION_USE)
{ {
@ -1164,7 +1164,7 @@ bool Inventory::DoCombine()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
// Change object left // Change object left
float deltaAngle = 360.0f / combineRing->numObjects / INV_NUM_FRAMES_ROTATE; float deltaAngle = 360.0f / combineRing->numObjects / INV_NUM_FRAMES_ROTATE;
@ -1199,7 +1199,7 @@ bool Inventory::DoCombine()
UpdateSceneAndDrawInventory(); UpdateSceneAndDrawInventory();
} }
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
if (combineRing->currentObject < combineRing->numObjects - 1) if (combineRing->currentObject < combineRing->numObjects - 1)
combineRing->currentObject++; combineRing->currentObject++;
else else
@ -1209,7 +1209,7 @@ bool Inventory::DoCombine()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
// Check if can be combined // Check if can be combined
short currentObject = combineRing->objects[combineRing->currentObject].inventoryObject; short currentObject = combineRing->objects[combineRing->currentObject].inventoryObject;
@ -1220,7 +1220,7 @@ bool Inventory::DoCombine()
combination->piece2 == currentObject && combination->piece1 == ring->objects[ring->currentObject].inventoryObject) combination->piece2 == currentObject && combination->piece1 == ring->objects[ring->currentObject].inventoryObject)
{ {
// I can do the combination // I can do the combination
SoundEffect(SFX_MENU_COMBINE, NULL, 0); SoundEffect(SFX_TR4_MENU_COMBINE, NULL, 0);
combination->combineRoutine(INV_COMBINE_COMBINE, combination->combinedObject); combination->combineRoutine(INV_COMBINE_COMBINE, combination->combinedObject);
LoadObjects(true); LoadObjects(true);
SelectObject(oldRing, combination->combinedObject, 2 * INV_OBJECTS_SCALE); SelectObject(oldRing, combination->combinedObject, 2 * INV_OBJECTS_SCALE);
@ -1257,7 +1257,7 @@ bool Inventory::DoSepare()
if (combination->combinedObject == currentObject) if (combination->combinedObject == currentObject)
{ {
// Separation can be done // Separation can be done
SoundEffect(SFX_MENU_COMBINE, NULL, 0); SoundEffect(SFX_TR4_MENU_COMBINE, NULL, 0);
combination->combineRoutine(INV_COMBINE_SEPARE, combination->combinedObject); combination->combineRoutine(INV_COMBINE_SEPARE, combination->combinedObject);
LoadObjects(true); LoadObjects(true);
SelectObject(m_activeRing, combination->piece1, 2 * INV_OBJECTS_SCALE); SelectObject(m_activeRing, combination->piece1, 2 * INV_OBJECTS_SCALE);
@ -1344,7 +1344,7 @@ void Inventory::DoSelectAmmo()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
// Change object left // Change object left
float deltaAngle = 360.0f / ammoRing->numObjects / INV_NUM_FRAMES_ROTATE; float deltaAngle = 360.0f / ammoRing->numObjects / INV_NUM_FRAMES_ROTATE;
@ -1379,7 +1379,7 @@ void Inventory::DoSelectAmmo()
UpdateSceneAndDrawInventory(); UpdateSceneAndDrawInventory();
} }
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
if (ammoRing->currentObject < ammoRing->numObjects - 1) if (ammoRing->currentObject < ammoRing->numObjects - 1)
ammoRing->currentObject++; ammoRing->currentObject++;
else else
@ -1389,7 +1389,7 @@ void Inventory::DoSelectAmmo()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
// Choose ammo // Choose ammo
switch (ring->objects[ring->currentObject].inventoryObject) switch (ring->objects[ring->currentObject].inventoryObject)
@ -1463,7 +1463,7 @@ void Inventory::UseCurrentItem()
SoundEffect(116, 0, 2); SoundEffect(116, 0, 2);
Savegame.Game.HealthUsed++; Savegame.Game.HealthUsed++;
SoundEffect(SFX_MENU_MEDI, NULL, 0); SoundEffect(SFX_TR4_MENU_MEDI, NULL, 0);
return; return;
} }
@ -1495,7 +1495,7 @@ void Inventory::UseCurrentItem()
SoundEffect(116, 0, 2); SoundEffect(116, 0, 2);
Savegame.Game.HealthUsed++; Savegame.Game.HealthUsed++;
SoundEffect(SFX_MENU_MEDI, NULL, 0); SoundEffect(SFX_TR4_MENU_MEDI, NULL, 0);
return; return;
} }
@ -1536,7 +1536,7 @@ void Inventory::UseCurrentItem()
{ {
m_selectedObject = objectNumber; m_selectedObject = objectNumber;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
return; return;
} }
@ -1554,7 +1554,7 @@ void Inventory::UseCurrentItem()
{ {
m_selectedObject = objectNumber; m_selectedObject = objectNumber;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
return; return;
} }
@ -1587,7 +1587,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_PISTOLS) if (!Lara.gunStatus && Lara.gunType == WEAPON_PISTOLS)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1606,7 +1606,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_UZI) if (!Lara.gunStatus && Lara.gunType == WEAPON_UZI)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1625,7 +1625,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_REVOLVER) if (!Lara.gunStatus && Lara.gunType == WEAPON_REVOLVER)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1644,7 +1644,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_SHOTGUN) if (!Lara.gunStatus && Lara.gunType == WEAPON_SHOTGUN)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1663,7 +1663,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_GRENADE_LAUNCHER) if (!Lara.gunStatus && Lara.gunType == WEAPON_GRENADE_LAUNCHER)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1682,7 +1682,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_HARPOON_GUN) if (!Lara.gunStatus && Lara.gunType == WEAPON_HARPOON_GUN)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1701,7 +1701,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_CROSSBOW) if (!Lara.gunStatus && Lara.gunType == WEAPON_CROSSBOW)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1720,7 +1720,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_HARPOON_GUN) if (!Lara.gunStatus && Lara.gunType == WEAPON_HARPOON_GUN)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1739,7 +1739,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_ROCKET_LAUNCHER) if (!Lara.gunStatus && Lara.gunType == WEAPON_ROCKET_LAUNCHER)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1758,7 +1758,7 @@ void Inventory::UseCurrentItem()
if (!Lara.gunStatus && Lara.gunType == WEAPON_HK) if (!Lara.gunStatus && Lara.gunType == WEAPON_HK)
Lara.gunStatus = LG_DRAW_GUNS; Lara.gunStatus = LG_DRAW_GUNS;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
else else
{ {
@ -1787,7 +1787,7 @@ void Inventory::UseCurrentItem()
LaraGun(); LaraGun();
TrInput = 0; TrInput = 0;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
} }
} }
@ -1897,7 +1897,7 @@ int Inventory::DoTitleInventory()
// Handle input // Handle input
if (TrInput & IN_LEFT) if (TrInput & IN_LEFT)
{ {
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
// Change object right // Change object right
float deltaAngle = 360.0f / ring->numObjects / INV_NUM_FRAMES_ROTATE; float deltaAngle = 360.0f / ring->numObjects / INV_NUM_FRAMES_ROTATE;
@ -1919,7 +1919,7 @@ int Inventory::DoTitleInventory()
} }
else if (TrInput & IN_RIGHT) else if (TrInput & IN_RIGHT)
{ {
SoundEffect(SFX_MENU_ROTATE, NULL, 0); SoundEffect(SFX_TR4_MENU_ROTATE, NULL, 0);
// Change object left // Change object left
float deltaAngle = 360.0f / ring->numObjects / INV_NUM_FRAMES_ROTATE; float deltaAngle = 360.0f / ring->numObjects / INV_NUM_FRAMES_ROTATE;
@ -1941,7 +1941,7 @@ int Inventory::DoTitleInventory()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (ring->objects[ring->currentObject].inventoryObject == _INV_OBJECT_PASSPORT) if (ring->objects[ring->currentObject].inventoryObject == _INV_OBJECT_PASSPORT)
{ {
@ -2111,13 +2111,13 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_FORWARD && selectedSavegame > 0) else if (DbInput & IN_FORWARD && selectedSavegame > 0)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
selectedSavegame--; selectedSavegame--;
continue; continue;
} }
else if (DbInput & IN_BACK && selectedSavegame < MAX_SAVEGAMES - 1) else if (DbInput & IN_BACK && selectedSavegame < MAX_SAVEGAMES - 1)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
selectedSavegame++; selectedSavegame++;
continue; continue;
} }
@ -2139,7 +2139,7 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
//ReadSavegame(selectedSavegame); //ReadSavegame(selectedSavegame);
g_GameFlow->SelectedSaveGame = selectedSavegame; g_GameFlow->SelectedSaveGame = selectedSavegame;
@ -2183,13 +2183,13 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_FORWARD && selectedSavegame > 0) else if (DbInput & IN_FORWARD && selectedSavegame > 0)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
selectedSavegame--; selectedSavegame--;
continue; continue;
} }
else if (DbInput & IN_BACK && selectedSavegame < MAX_SAVEGAMES - 1) else if (DbInput & IN_BACK && selectedSavegame < MAX_SAVEGAMES - 1)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
selectedSavegame++; selectedSavegame++;
continue; continue;
} }
@ -2211,7 +2211,7 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
// Use the new savegame system // Use the new savegame system
char fileName[255]; char fileName[255];
@ -2258,13 +2258,13 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_FORWARD && selectedLevel > 0) else if (DbInput & IN_FORWARD && selectedLevel > 0)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
selectedLevel--; selectedLevel--;
continue; continue;
} }
else if (DbInput & IN_BACK && selectedLevel < g_GameFlow->GetNumLevels() - 1) else if (DbInput & IN_BACK && selectedLevel < g_GameFlow->GetNumLevels() - 1)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
selectedLevel++; selectedLevel++;
continue; continue;
} }
@ -2286,7 +2286,7 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
result = INV_RESULT_NEW_GAME; result = INV_RESULT_NEW_GAME;
g_GameFlow->SelectedLevelForNewGame = selectedLevel + 1; g_GameFlow->SelectedLevelForNewGame = selectedLevel + 1;
@ -2343,7 +2343,7 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
result = INV_RESULT_NEW_GAME; result = INV_RESULT_NEW_GAME;
moveLeft = false; moveLeft = false;
@ -2397,7 +2397,7 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
result = INV_RESULT_EXIT_GAME; result = INV_RESULT_EXIT_GAME;
moveLeft = false; moveLeft = false;
@ -2451,7 +2451,7 @@ int Inventory::DoPassport()
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
result = INV_RESULT_EXIT_TO_TILE; result = INV_RESULT_EXIT_TO_TILE;
moveLeft = false; moveLeft = false;
@ -2599,7 +2599,7 @@ void Inventory::DoControlsSettings()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex > 0) if (ring->selectedIndex > 0)
ring->selectedIndex--; ring->selectedIndex--;
} }
@ -2607,13 +2607,13 @@ void Inventory::DoControlsSettings()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex < NUM_CONTROLS + 2 - 1) if (ring->selectedIndex < NUM_CONTROLS + 2 - 1)
ring->selectedIndex++; ring->selectedIndex++;
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex == NUM_CONTROLS) if (ring->selectedIndex == NUM_CONTROLS)
{ {
@ -2639,7 +2639,7 @@ void Inventory::DoControlsSettings()
// If RETURN is pressed, then wait for a new key // If RETURN is pressed, then wait for a new key
if (KeyMap[DIK_RETURN] & 0x80) if (KeyMap[DIK_RETURN] & 0x80)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (!ring->waitingForKey) if (!ring->waitingForKey)
{ {
@ -2749,29 +2749,29 @@ void Inventory::DoGraphicsSettings()
switch (ring->selectedIndex) switch (ring->selectedIndex)
{ {
case INV_DISPLAY_RESOLUTION: case INV_DISPLAY_RESOLUTION:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->SelectedVideoMode > 0) if (ring->SelectedVideoMode > 0)
ring->SelectedVideoMode--; ring->SelectedVideoMode--;
break; break;
case INV_DISPLAY_WINDOWED: case INV_DISPLAY_WINDOWED:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.Windowed = !ring->Configuration.Windowed; ring->Configuration.Windowed = !ring->Configuration.Windowed;
break; break;
case INV_DISPLAY_SHADOWS: case INV_DISPLAY_SHADOWS:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableShadows = !ring->Configuration.EnableShadows; ring->Configuration.EnableShadows = !ring->Configuration.EnableShadows;
break; break;
case INV_DISPLAY_CAUSTICS: case INV_DISPLAY_CAUSTICS:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableCaustics = !ring->Configuration.EnableCaustics; ring->Configuration.EnableCaustics = !ring->Configuration.EnableCaustics;
break; break;
case INV_DISPLAY_VOLUMETRIC_FOG: case INV_DISPLAY_VOLUMETRIC_FOG:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableVolumetricFog = !ring->Configuration.EnableVolumetricFog; ring->Configuration.EnableVolumetricFog = !ring->Configuration.EnableVolumetricFog;
break; break;
} }
@ -2783,28 +2783,28 @@ void Inventory::DoGraphicsSettings()
switch (ring->selectedIndex) switch (ring->selectedIndex)
{ {
case INV_DISPLAY_RESOLUTION: case INV_DISPLAY_RESOLUTION:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->SelectedVideoMode < adapter->DisplayModes.size() - 1) if (ring->SelectedVideoMode < adapter->DisplayModes.size() - 1)
ring->SelectedVideoMode++; ring->SelectedVideoMode++;
break; break;
case INV_DISPLAY_WINDOWED: case INV_DISPLAY_WINDOWED:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.Windowed = !ring->Configuration.Windowed; ring->Configuration.Windowed = !ring->Configuration.Windowed;
break; break;
case INV_DISPLAY_SHADOWS: case INV_DISPLAY_SHADOWS:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableShadows = !ring->Configuration.EnableShadows; ring->Configuration.EnableShadows = !ring->Configuration.EnableShadows;
break; break;
case INV_DISPLAY_CAUSTICS: case INV_DISPLAY_CAUSTICS:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableCaustics = !ring->Configuration.EnableCaustics; ring->Configuration.EnableCaustics = !ring->Configuration.EnableCaustics;
break; break;
case INV_DISPLAY_VOLUMETRIC_FOG: case INV_DISPLAY_VOLUMETRIC_FOG:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableVolumetricFog = !ring->Configuration.EnableVolumetricFog; ring->Configuration.EnableVolumetricFog = !ring->Configuration.EnableVolumetricFog;
break; break;
} }
@ -2813,7 +2813,7 @@ void Inventory::DoGraphicsSettings()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex > 0) if (ring->selectedIndex > 0)
ring->selectedIndex--; ring->selectedIndex--;
} }
@ -2821,13 +2821,13 @@ void Inventory::DoGraphicsSettings()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex < INV_DISPLAY_COUNT) if (ring->selectedIndex < INV_DISPLAY_COUNT)
ring->selectedIndex++; ring->selectedIndex++;
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (ring->selectedIndex == INV_DISPLAY_APPLY) if (ring->selectedIndex == INV_DISPLAY_APPLY)
{ {
@ -2849,7 +2849,7 @@ void Inventory::DoGraphicsSettings()
} }
else if (ring->selectedIndex == INV_DISPLAY_CANCEL) else if (ring->selectedIndex == INV_DISPLAY_CANCEL)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
closeObject = true; closeObject = true;
break; break;
@ -2908,13 +2908,13 @@ void Inventory::DoSoundSettings()
switch (ring->selectedIndex) switch (ring->selectedIndex)
{ {
case INV_SOUND_ENABLED: case INV_SOUND_ENABLED:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableSound = !ring->Configuration.EnableSound; ring->Configuration.EnableSound = !ring->Configuration.EnableSound;
break; break;
case INV_SOUND_SPECIAL_EFFECTS: case INV_SOUND_SPECIAL_EFFECTS:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableAudioSpecialEffects = !ring->Configuration.EnableAudioSpecialEffects; ring->Configuration.EnableAudioSpecialEffects = !ring->Configuration.EnableAudioSpecialEffects;
break; break;
@ -2932,7 +2932,7 @@ void Inventory::DoSoundSettings()
{ {
ring->Configuration.SfxVolume--; ring->Configuration.SfxVolume--;
GlobalFXVolume = ring->Configuration.SfxVolume; GlobalFXVolume = ring->Configuration.SfxVolume;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
break; break;
@ -2945,13 +2945,13 @@ void Inventory::DoSoundSettings()
switch (ring->selectedIndex) switch (ring->selectedIndex)
{ {
case INV_SOUND_ENABLED: case INV_SOUND_ENABLED:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableSound = !ring->Configuration.EnableSound; ring->Configuration.EnableSound = !ring->Configuration.EnableSound;
break; break;
case INV_SOUND_SPECIAL_EFFECTS: case INV_SOUND_SPECIAL_EFFECTS:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
ring->Configuration.EnableAudioSpecialEffects = !ring->Configuration.EnableAudioSpecialEffects; ring->Configuration.EnableAudioSpecialEffects = !ring->Configuration.EnableAudioSpecialEffects;
break; break;
@ -2969,7 +2969,7 @@ void Inventory::DoSoundSettings()
{ {
ring->Configuration.SfxVolume++; ring->Configuration.SfxVolume++;
GlobalFXVolume = ring->Configuration.SfxVolume; GlobalFXVolume = ring->Configuration.SfxVolume;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
} }
break; break;
@ -2979,7 +2979,7 @@ void Inventory::DoSoundSettings()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex > 0) if (ring->selectedIndex > 0)
ring->selectedIndex--; ring->selectedIndex--;
} }
@ -2987,13 +2987,13 @@ void Inventory::DoSoundSettings()
{ {
closeObject = false; closeObject = false;
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (ring->selectedIndex < INV_DISPLAY_COUNT) if (ring->selectedIndex < INV_DISPLAY_COUNT)
ring->selectedIndex++; ring->selectedIndex++;
} }
else if (DbInput & IN_SELECT) else if (DbInput & IN_SELECT)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (ring->selectedIndex == INV_DISPLAY_APPLY) if (ring->selectedIndex == INV_DISPLAY_APPLY)
{ {
@ -3015,7 +3015,7 @@ void Inventory::DoSoundSettings()
} }
else if (ring->selectedIndex == INV_DISPLAY_CANCEL) else if (ring->selectedIndex == INV_DISPLAY_CANCEL)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
closeObject = true; closeObject = true;
GlobalMusicVolume = oldVolume; GlobalMusicVolume = oldVolume;

View file

@ -595,7 +595,7 @@ int TitleOptions()
if (title_selected_option > 1) if (title_selected_option > 1)
title_selected_option >>= 1; title_selected_option >>= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDown) if (goDown)
@ -603,14 +603,14 @@ int TitleOptions()
if (title_selected_option < flag) if (title_selected_option < flag)
title_selected_option <<= 1; title_selected_option <<= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDeselect && title_menu_to_display != title_main_menu) if (goDeselect && title_menu_to_display != title_main_menu)
{ {
title_menu_to_display = title_main_menu; title_menu_to_display = title_main_menu;
title_selected_option = selected_option_bak; title_selected_option = selected_option_bak;
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
} }
} }
@ -618,7 +618,7 @@ int TitleOptions()
{ {
if (title_menu_to_display <= 2) if (title_menu_to_display <= 2)
{ {
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
if (title_menu_to_display != 0) if (title_menu_to_display != 0)
{ {
@ -765,7 +765,7 @@ void handle_display_setting_input()
if (goDeselect) if (goDeselect)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
title_menu_to_display = title_options_menu; title_menu_to_display = title_options_menu;
title_selected_option = 1; title_selected_option = 1;
@ -777,28 +777,28 @@ void handle_display_setting_input()
switch (title_selected_option) switch (title_selected_option)
{ {
case 1: case 1:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (CurrentSettings.videoMode > 0) if (CurrentSettings.videoMode > 0)
CurrentSettings.videoMode--; CurrentSettings.videoMode--;
break; break;
case 2: case 2:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.Windowed = !CurrentSettings.conf.Windowed; CurrentSettings.conf.Windowed = !CurrentSettings.conf.Windowed;
break; break;
case 4: case 4:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableShadows = !CurrentSettings.conf.EnableShadows; CurrentSettings.conf.EnableShadows = !CurrentSettings.conf.EnableShadows;
break; break;
case 8: case 8:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableCaustics = !CurrentSettings.conf.EnableCaustics; CurrentSettings.conf.EnableCaustics = !CurrentSettings.conf.EnableCaustics;
break; break;
case 16: case 16:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableVolumetricFog = !CurrentSettings.conf.EnableVolumetricFog; CurrentSettings.conf.EnableVolumetricFog = !CurrentSettings.conf.EnableVolumetricFog;
break; break;
} }
@ -809,28 +809,28 @@ void handle_display_setting_input()
switch (title_selected_option) switch (title_selected_option)
{ {
case 1: case 1:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (CurrentSettings.videoMode < adapter->DisplayModes.size() - 1) if (CurrentSettings.videoMode < adapter->DisplayModes.size() - 1)
CurrentSettings.videoMode++; CurrentSettings.videoMode++;
break; break;
case 2: case 2:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.Windowed = !CurrentSettings.conf.Windowed; CurrentSettings.conf.Windowed = !CurrentSettings.conf.Windowed;
break; break;
case 4: case 4:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableShadows = !CurrentSettings.conf.EnableShadows; CurrentSettings.conf.EnableShadows = !CurrentSettings.conf.EnableShadows;
break; break;
case 8: case 8:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableCaustics = !CurrentSettings.conf.EnableCaustics; CurrentSettings.conf.EnableCaustics = !CurrentSettings.conf.EnableCaustics;
break; break;
case 16: case 16:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableVolumetricFog = !CurrentSettings.conf.EnableVolumetricFog; CurrentSettings.conf.EnableVolumetricFog = !CurrentSettings.conf.EnableVolumetricFog;
break; break;
} }
@ -841,7 +841,7 @@ void handle_display_setting_input()
if (title_selected_option > 1) if (title_selected_option > 1)
title_selected_option >>= 1; title_selected_option >>= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDown) if (goDown)
@ -849,12 +849,12 @@ void handle_display_setting_input()
if (title_selected_option < settings_flag) if (title_selected_option < settings_flag)
title_selected_option <<= 1; title_selected_option <<= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goSelect) if (goSelect)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (title_selected_option & (1 << 5)) if (title_selected_option & (1 << 5))
{ {
@ -914,7 +914,7 @@ void handle_control_settings_input()
if (title_selected_option > 1) if (title_selected_option > 1)
title_selected_option >>= 1; title_selected_option >>= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDown) if (goDown)
@ -922,14 +922,14 @@ void handle_control_settings_input()
if (title_selected_option < settings_flag) if (title_selected_option < settings_flag)
title_selected_option <<= 1; title_selected_option <<= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goSelect) if (goSelect)
{ {
if (title_selected_option & (1 << 18))//apply if (title_selected_option & (1 << 18))//apply
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
memcpy(KeyboardLayout[1], CurrentSettings.conf.KeyboardLayout, NUM_CONTROLS); memcpy(KeyboardLayout[1], CurrentSettings.conf.KeyboardLayout, NUM_CONTROLS);
SaveConfiguration(); SaveConfiguration();
title_menu_to_display = title_options_menu; title_menu_to_display = title_options_menu;
@ -939,7 +939,7 @@ void handle_control_settings_input()
if (title_selected_option & (1 << 19))//cancel if (title_selected_option & (1 << 19))//cancel
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
title_menu_to_display = title_options_menu; title_menu_to_display = title_options_menu;
title_selected_option = 2; title_selected_option = 2;
return; return;
@ -949,7 +949,7 @@ void handle_control_settings_input()
if (KeyMap[DIK_RETURN]) if (KeyMap[DIK_RETURN])
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
CurrentSettings.waitingForkey = 1; CurrentSettings.waitingForkey = 1;
} }
@ -1051,13 +1051,13 @@ void handle_sound_settings_input()
switch (title_selected_option) switch (title_selected_option)
{ {
case 1: case 1:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableSound = !CurrentSettings.conf.EnableSound; CurrentSettings.conf.EnableSound = !CurrentSettings.conf.EnableSound;
break; break;
case 2: case 2:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableAudioSpecialEffects = !CurrentSettings.conf.EnableAudioSpecialEffects; CurrentSettings.conf.EnableAudioSpecialEffects = !CurrentSettings.conf.EnableAudioSpecialEffects;
break; break;
@ -1069,7 +1069,7 @@ void handle_sound_settings_input()
GlobalMusicVolume = CurrentSettings.conf.MusicVolume; GlobalMusicVolume = CurrentSettings.conf.MusicVolume;
if (!db) if (!db)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
db = 10; db = 10;
} }
else else
@ -1086,7 +1086,7 @@ void handle_sound_settings_input()
GlobalFXVolume = CurrentSettings.conf.SfxVolume; GlobalFXVolume = CurrentSettings.conf.SfxVolume;
if (!db) if (!db)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
db = 10; db = 10;
} }
else else
@ -1102,12 +1102,12 @@ void handle_sound_settings_input()
switch (title_selected_option) switch (title_selected_option)
{ {
case 1: case 1:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableSound = !CurrentSettings.conf.EnableSound; CurrentSettings.conf.EnableSound = !CurrentSettings.conf.EnableSound;
break; break;
case 2: case 2:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableAudioSpecialEffects = !CurrentSettings.conf.EnableAudioSpecialEffects; CurrentSettings.conf.EnableAudioSpecialEffects = !CurrentSettings.conf.EnableAudioSpecialEffects;
break; break;
@ -1119,7 +1119,7 @@ void handle_sound_settings_input()
GlobalMusicVolume = CurrentSettings.conf.MusicVolume; GlobalMusicVolume = CurrentSettings.conf.MusicVolume;
if (!db) if (!db)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
db = 10; db = 10;
} }
else else
@ -1136,7 +1136,7 @@ void handle_sound_settings_input()
GlobalFXVolume = CurrentSettings.conf.SfxVolume; GlobalFXVolume = CurrentSettings.conf.SfxVolume;
if (!db) if (!db)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
db = 10; db = 10;
} }
else else
@ -1152,7 +1152,7 @@ void handle_sound_settings_input()
if (title_selected_option > 1) if (title_selected_option > 1)
title_selected_option >>= 1; title_selected_option >>= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDown) if (goDown)
@ -1160,12 +1160,12 @@ void handle_sound_settings_input()
if (title_selected_option < settings_flag) if (title_selected_option < settings_flag)
title_selected_option <<= 1; title_selected_option <<= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goSelect) if (goSelect)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (title_selected_option & (1 << 4)) if (title_selected_option & (1 << 4))
{ {
@ -1186,7 +1186,7 @@ void handle_sound_settings_input()
if (title_selected_option & (1 << 5)) if (title_selected_option & (1 << 5))
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
GlobalMusicVolume = oldVolume; GlobalMusicVolume = oldVolume;
GlobalFXVolume = oldSfxVolume; GlobalFXVolume = oldSfxVolume;
title_menu_to_display = title_options_menu; title_menu_to_display = title_options_menu;
@ -1245,7 +1245,7 @@ int DoPauseMenu()
if (pause_selected_option > 1) if (pause_selected_option > 1)
pause_selected_option >>= 1; pause_selected_option >>= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDown) if (goDown)
@ -1253,7 +1253,7 @@ int DoPauseMenu()
if (pause_selected_option < pause_flag) if (pause_selected_option < pause_flag)
pause_selected_option <<= 1; pause_selected_option <<= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
} }
@ -1263,7 +1263,7 @@ int DoPauseMenu()
{ {
pauseMenu = 0; pauseMenu = 0;
GLOBAL_invMode = IM_NONE; GLOBAL_invMode = IM_NONE;
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
return INV_RESULT_NONE; return INV_RESULT_NONE;
} }
@ -1271,7 +1271,7 @@ int DoPauseMenu()
{ {
pause_selected_option = pause_menu_to_display == pause_statistics ? 1 : 2; pause_selected_option = pause_menu_to_display == pause_statistics ? 1 : 2;
pause_menu_to_display = pause_main_menu; pause_menu_to_display = pause_main_menu;
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
} }
} }
@ -1339,7 +1339,7 @@ void handle_display_setting_input_pause()
if (goDeselect) if (goDeselect)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
pause_menu_to_display = pause_options_menu; pause_menu_to_display = pause_options_menu;
pause_selected_option = 1; pause_selected_option = 1;
@ -1351,28 +1351,28 @@ void handle_display_setting_input_pause()
switch (pause_selected_option) switch (pause_selected_option)
{ {
case 1: case 1:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (CurrentSettings.videoMode > 0) if (CurrentSettings.videoMode > 0)
CurrentSettings.videoMode--; CurrentSettings.videoMode--;
break; break;
case 2: case 2:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.Windowed = !CurrentSettings.conf.Windowed; CurrentSettings.conf.Windowed = !CurrentSettings.conf.Windowed;
break; break;
case 4: case 4:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableShadows = !CurrentSettings.conf.EnableShadows; CurrentSettings.conf.EnableShadows = !CurrentSettings.conf.EnableShadows;
break; break;
case 8: case 8:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableCaustics = !CurrentSettings.conf.EnableCaustics; CurrentSettings.conf.EnableCaustics = !CurrentSettings.conf.EnableCaustics;
break; break;
case 16: case 16:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableVolumetricFog = !CurrentSettings.conf.EnableVolumetricFog; CurrentSettings.conf.EnableVolumetricFog = !CurrentSettings.conf.EnableVolumetricFog;
break; break;
} }
@ -1383,28 +1383,28 @@ void handle_display_setting_input_pause()
switch (pause_selected_option) switch (pause_selected_option)
{ {
case 1: case 1:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
if (CurrentSettings.videoMode < adapter->DisplayModes.size() - 1) if (CurrentSettings.videoMode < adapter->DisplayModes.size() - 1)
CurrentSettings.videoMode++; CurrentSettings.videoMode++;
break; break;
case 2: case 2:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.Windowed = !CurrentSettings.conf.Windowed; CurrentSettings.conf.Windowed = !CurrentSettings.conf.Windowed;
break; break;
case 4: case 4:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableShadows = !CurrentSettings.conf.EnableShadows; CurrentSettings.conf.EnableShadows = !CurrentSettings.conf.EnableShadows;
break; break;
case 8: case 8:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableCaustics = !CurrentSettings.conf.EnableCaustics; CurrentSettings.conf.EnableCaustics = !CurrentSettings.conf.EnableCaustics;
break; break;
case 16: case 16:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableVolumetricFog = !CurrentSettings.conf.EnableVolumetricFog; CurrentSettings.conf.EnableVolumetricFog = !CurrentSettings.conf.EnableVolumetricFog;
break; break;
} }
@ -1415,7 +1415,7 @@ void handle_display_setting_input_pause()
if (pause_selected_option > 1) if (pause_selected_option > 1)
pause_selected_option >>= 1; pause_selected_option >>= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDown) if (goDown)
@ -1423,12 +1423,12 @@ void handle_display_setting_input_pause()
if (pause_selected_option < pause_flag) if (pause_selected_option < pause_flag)
pause_selected_option <<= 1; pause_selected_option <<= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goSelect) if (goSelect)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (pause_selected_option & (1 << 5)) if (pause_selected_option & (1 << 5))
{ {
@ -1482,7 +1482,7 @@ void handle_control_settings_input_pause()
if (pause_selected_option > 1) if (pause_selected_option > 1)
pause_selected_option >>= 1; pause_selected_option >>= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDown) if (goDown)
@ -1490,14 +1490,14 @@ void handle_control_settings_input_pause()
if (pause_selected_option < pause_flag) if (pause_selected_option < pause_flag)
pause_selected_option <<= 1; pause_selected_option <<= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goSelect) if (goSelect)
{ {
if (pause_selected_option & (1 << 18))//apply if (pause_selected_option & (1 << 18))//apply
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
memcpy(KeyboardLayout[1], CurrentSettings.conf.KeyboardLayout, NUM_CONTROLS); memcpy(KeyboardLayout[1], CurrentSettings.conf.KeyboardLayout, NUM_CONTROLS);
SaveConfiguration(); SaveConfiguration();
pause_menu_to_display = pause_options_menu; pause_menu_to_display = pause_options_menu;
@ -1507,7 +1507,7 @@ void handle_control_settings_input_pause()
if (pause_selected_option & (1 << 19))//cancel if (pause_selected_option & (1 << 19))//cancel
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
pause_menu_to_display = pause_options_menu; pause_menu_to_display = pause_options_menu;
pause_selected_option = 2; pause_selected_option = 2;
return; return;
@ -1517,7 +1517,7 @@ void handle_control_settings_input_pause()
if (KeyMap[DIK_RETURN]) if (KeyMap[DIK_RETURN])
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
CurrentSettings.waitingForkey = 1; CurrentSettings.waitingForkey = 1;
} }
@ -1606,13 +1606,13 @@ void handle_sound_settings_input_pause()
switch (pause_selected_option) switch (pause_selected_option)
{ {
case 1: case 1:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableSound = !CurrentSettings.conf.EnableSound; CurrentSettings.conf.EnableSound = !CurrentSettings.conf.EnableSound;
break; break;
case 2: case 2:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableAudioSpecialEffects = !CurrentSettings.conf.EnableAudioSpecialEffects; CurrentSettings.conf.EnableAudioSpecialEffects = !CurrentSettings.conf.EnableAudioSpecialEffects;
break; break;
@ -1624,7 +1624,7 @@ void handle_sound_settings_input_pause()
GlobalMusicVolume = CurrentSettings.conf.MusicVolume; GlobalMusicVolume = CurrentSettings.conf.MusicVolume;
if (!db) if (!db)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
db = 10; db = 10;
} }
else else
@ -1641,7 +1641,7 @@ void handle_sound_settings_input_pause()
GlobalFXVolume = CurrentSettings.conf.SfxVolume; GlobalFXVolume = CurrentSettings.conf.SfxVolume;
if (!db) if (!db)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
db = 10; db = 10;
} }
else else
@ -1657,12 +1657,12 @@ void handle_sound_settings_input_pause()
switch (pause_selected_option) switch (pause_selected_option)
{ {
case 1: case 1:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableSound = !CurrentSettings.conf.EnableSound; CurrentSettings.conf.EnableSound = !CurrentSettings.conf.EnableSound;
break; break;
case 2: case 2:
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
CurrentSettings.conf.EnableAudioSpecialEffects = !CurrentSettings.conf.EnableAudioSpecialEffects; CurrentSettings.conf.EnableAudioSpecialEffects = !CurrentSettings.conf.EnableAudioSpecialEffects;
break; break;
@ -1674,7 +1674,7 @@ void handle_sound_settings_input_pause()
GlobalMusicVolume = CurrentSettings.conf.MusicVolume; GlobalMusicVolume = CurrentSettings.conf.MusicVolume;
if (!db) if (!db)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
db = 10; db = 10;
} }
else else
@ -1691,7 +1691,7 @@ void handle_sound_settings_input_pause()
GlobalFXVolume = CurrentSettings.conf.SfxVolume; GlobalFXVolume = CurrentSettings.conf.SfxVolume;
if (!db) if (!db)
{ {
SoundEffect(SFX_MENU_CHOOSE, NULL, 0); SoundEffect(SFX_TR4_MENU_CHOOSE, NULL, 0);
db = 10; db = 10;
} }
else else
@ -1707,7 +1707,7 @@ void handle_sound_settings_input_pause()
if (pause_selected_option > 1) if (pause_selected_option > 1)
pause_selected_option >>= 1; pause_selected_option >>= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goDown) if (goDown)
@ -1715,12 +1715,12 @@ void handle_sound_settings_input_pause()
if (pause_selected_option < pause_flag) if (pause_selected_option < pause_flag)
pause_selected_option <<= 1; pause_selected_option <<= 1;
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
} }
if (goSelect) if (goSelect)
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
if (pause_selected_option & (1 << 4)) if (pause_selected_option & (1 << 4))
{ {
@ -1741,7 +1741,7 @@ void handle_sound_settings_input_pause()
if (pause_selected_option & (1 << 5)) if (pause_selected_option & (1 << 5))
{ {
SoundEffect(SFX_MENU_SELECT, NULL, 0); SoundEffect(SFX_TR4_MENU_SELECT, NULL, 0);
GlobalMusicVolume = oldVolume; GlobalMusicVolume = oldVolume;
GlobalFXVolume = oldSfxVolume; GlobalFXVolume = oldSfxVolume;
pause_menu_to_display = pause_options_menu; pause_menu_to_display = pause_options_menu;
@ -2509,7 +2509,7 @@ void use_current_item()
if (LaraItem->hitPoints > 1000) if (LaraItem->hitPoints > 1000)
LaraItem->hitPoints = 1000; LaraItem->hitPoints = 1000;
SoundEffect(SFX_MENU_MEDI, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_MEDI, 0, SFX_ALWAYS);
Savegame.Game.HealthUsed++; Savegame.Game.HealthUsed++;
} }
else else
@ -2533,7 +2533,7 @@ void use_current_item()
Lara.dpoisoned = 0; Lara.dpoisoned = 0;
LaraItem->hitPoints = 1000; LaraItem->hitPoints = 1000;
SoundEffect(SFX_MENU_MEDI, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_MEDI, 0, SFX_ALWAYS);
Savegame.Game.HealthUsed++; Savegame.Game.HealthUsed++;
} }
else else
@ -2683,7 +2683,7 @@ void handle_inventry_menu()
combine_type_flag = 1; combine_type_flag = 1;
combine_obj1 = rings[RING_INVENTORY]->current_object_list[rings[RING_INVENTORY]->curobjinlist].invitem; combine_obj1 = rings[RING_INVENTORY]->current_object_list[rings[RING_INVENTORY]->curobjinlist].invitem;
combine_obj2 = rings[RING_AMMO]->current_object_list[rings[RING_AMMO]->curobjinlist].invitem; combine_obj2 = rings[RING_AMMO]->current_object_list[rings[RING_AMMO]->curobjinlist].invitem;
SoundEffect(SFX_MENU_COMBINE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_COMBINE, 0, SFX_ALWAYS);
} }
else else
{ {
@ -2694,7 +2694,7 @@ void handle_inventry_menu()
if (goDeselect) if (goDeselect)
{ {
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
combine_ring_fade_dir = 2; combine_ring_fade_dir = 2;
goDeselect = 0; goDeselect = 0;
} }
@ -2839,12 +2839,12 @@ void handle_inventry_menu()
if (goUp && current_selected_option > 0) if (goUp && current_selected_option > 0)
{ {
current_selected_option--; current_selected_option--;
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
} }
else if (goDown && current_selected_option < n - 1) else if (goDown && current_selected_option < n - 1)
{ {
current_selected_option++; current_selected_option++;
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
} }
if (ammo_active) if (ammo_active)
@ -2852,13 +2852,13 @@ void handle_inventry_menu()
if (goLeft && current_selected_option > 0) if (goLeft && current_selected_option > 0)
{ {
current_selected_option--; current_selected_option--;
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
} }
if (goRight && current_selected_option < n - 1) if (goRight && current_selected_option < n - 1)
{ {
current_selected_option++; current_selected_option++;
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
} }
current_ammo_type[0] = current_selected_option; current_ammo_type[0] = current_selected_option;
@ -2867,7 +2867,7 @@ void handle_inventry_menu()
if (goSelect) if (goSelect)
{ {
if (current_options[current_selected_option].type != 5 && current_options[current_selected_option].type != 1) if (current_options[current_selected_option].type != 5 && current_options[current_selected_option].type != 1)
SoundEffect(SFX_MENU_CHOOSE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_CHOOSE, 0, SFX_ALWAYS);
switch (current_options[current_selected_option].type) switch (current_options[current_selected_option].type)
{ {
@ -2934,7 +2934,7 @@ void handle_inventry_menu()
if (goDeselect && ammo_active) if (goDeselect && ammo_active)
{ {
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
goDeselect = 0; goDeselect = 0;
ammo_active = 0; ammo_active = 0;
rings[RING_INVENTORY]->ringactive = 1; rings[RING_INVENTORY]->ringactive = 1;
@ -3455,7 +3455,7 @@ void draw_current_object_list(int ringnum)
{ {
if (!rings[ringnum]->objlistmovement) if (!rings[ringnum]->objlistmovement)
{ {
SoundEffect(SFX_MENU_ROTATE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_ROTATE, 0, SFX_ALWAYS);
rings[ringnum]->objlistmovement += 8192; rings[ringnum]->objlistmovement += 8192;
if (ammo_selector_flag) if (ammo_selector_flag)
@ -3467,7 +3467,7 @@ void draw_current_object_list(int ringnum)
{ {
if (!rings[ringnum]->objlistmovement) if (!rings[ringnum]->objlistmovement)
{ {
SoundEffect(SFX_MENU_ROTATE, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_ROTATE, 0, SFX_ALWAYS);
rings[ringnum]->objlistmovement -= 8192; rings[ringnum]->objlistmovement -= 8192;
if (ammo_selector_flag) if (ammo_selector_flag)
@ -3541,7 +3541,7 @@ int S_CallInventory2()
if (DbInput & IN_OPTION) if (DbInput & IN_OPTION)
{ {
SoundEffect(SFX_MENU_SELECT, 0, SFX_ALWAYS); SoundEffect(SFX_TR4_MENU_SELECT, 0, SFX_ALWAYS);
val = 1; val = 1;
} }

View file

@ -199,30 +199,26 @@ void AnimateWaterfalls()
} }
} }
void ControlWaterfall(short itemNumber) void ControlWaterfall(short itemNumber)
{ {
ITEM_INFO* item = &g_Level.Items[itemNumber]; ITEM_INFO* item = &g_Level.Items[itemNumber];
TriggerActive(item);
if (itemNumber != 0) int dx = item->pos.xPos - LaraItem->pos.xPos;
{ int dy = item->pos.yPos - LaraItem->pos.yPos;
item->status = ITEM_ACTIVE; int dz = item->pos.zPos - LaraItem->pos.zPos;
if (item->triggerFlags == 0x29C) if (dx >= -16384 && dx <= 16384 && dy >= -16384 && dy <= 16384 && dz >= -16384 && dz <= 16384)
{
SoundEffect(SFX_D_METAL_KICKOPEN, &item->pos, 0);
}
else if (item->triggerFlags == 0x309)
{
SoundEffect(SFX_WATERFALL_LOOP, &item->pos, 0);
}
}
else
{ {
if (item->triggerFlags == 2 || item->triggerFlags == 0x29C) if (!(Wibble & 0xC))
{ {
item->status = ITEM_INVISIBLE; TriggerWaterfallMist(
item->pos.xPos + 68 * phd_sin(item->pos.yRot),
item->pos.yPos,
item->pos.zPos + 68 * phd_cos(item->pos.yRot),
item->pos.yRot >> 4);
} }
SoundEffect(SFX_TR4_WATERFALL_LOOP, &item->pos, 0);
} }
} }

View file

@ -106,7 +106,7 @@ short GunHit(int x, int y, int z, short speed, short yrot, short roomNumber)
GetLaraJointPosition(&pos, (25 * GetRandomControl()) / 32768); GetLaraJointPosition(&pos, (25 * GetRandomControl()) / 32768);
DoBloodSplat(pos.x, pos.y, pos.z, (GetRandomControl() & 3) + 3, LaraItem->pos.yRot, LaraItem->roomNumber); DoBloodSplat(pos.x, pos.y, pos.z, (GetRandomControl() & 3) + 3, LaraItem->pos.yRot, LaraItem->roomNumber);
SoundEffect(SFX_LARA_INJURY_RND, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_INJURY, &LaraItem->pos, 0);
return GunShot(x, y, z, speed, yrot, roomNumber); return GunShot(x, y, z, speed, yrot, roomNumber);
} }

View file

@ -495,7 +495,7 @@ void UpdateRopeSwing(ITEM_INFO* item)
RopeSwing = 0; RopeSwing = 0;
} }
SoundEffect(SFX_LARA_ROPE_CREAK, &item->pos, 0); SoundEffect(SFX_TR4_LARA_ROPE_CREAK, &item->pos, 0);
} }
else if (Lara.ropeLastX < 0 && Lara.ropeFrame == Lara.ropeDFrame) else if (Lara.ropeLastX < 0 && Lara.ropeFrame == Lara.ropeDFrame)
{ {
@ -528,7 +528,7 @@ void UpdateRopeSwing(ITEM_INFO* item)
RopeSwing = 0; RopeSwing = 0;
} }
SoundEffect(SFX_LARA_ROPE_CREAK, &item->pos, 0); SoundEffect(SFX_TR4_LARA_ROPE_CREAK, &item->pos, 0);
} }
else if (Lara.ropeLastX > 0 && Lara.ropeFrame == Lara.ropeDFrame) else if (Lara.ropeLastX > 0 && Lara.ropeFrame == Lara.ropeDFrame)
{ {
@ -653,7 +653,7 @@ void LaraClimbRope(ITEM_INFO* item, COLL_INFO* coll)
if (item->animNumber == LA_ROPE_DOWN && item->frameNumber == g_Level.Anims[item->animNumber].frameEnd) if (item->animNumber == LA_ROPE_DOWN && item->frameNumber == g_Level.Anims[item->animNumber].frameEnd)
{ {
SoundEffect(SFX_LARA_ROPEDOWN_LOOP, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_POLE_LOOP, &LaraItem->pos, 0);
item->frameNumber = g_Level.Anims[item->animNumber].frameBase; item->frameNumber = g_Level.Anims[item->animNumber].frameBase;
Lara.ropeFlag = 0; Lara.ropeFlag = 0;
++Lara.ropeSegment; ++Lara.ropeSegment;

View file

@ -702,5 +702,5 @@ bool Sound_CheckBASSError(const char* message, bool verbose, ...)
void SayNo() void SayNo()
{ {
SoundEffect(SFX_LARA_NO, NULL, SFX_ALWAYS); SoundEffect(SFX_TR4_LARA_NO, NULL, SFX_ALWAYS);
} }

File diff suppressed because it is too large Load diff

View file

@ -192,7 +192,7 @@ void CrowDoveSwitchControl(short itemNumber)
if ((item->meshBits & 2)) if ((item->meshBits & 2))
{ {
ExplodeItemNode(item, 1, 0, 0x100); ExplodeItemNode(item, 1, 0, 0x100);
SoundEffect(SFX_RAVENSWITCH_EXP, &item->pos, 0); SoundEffect(SFX_TR5_RAVENSWITCH_EXP, &item->pos, 0);
item->meshBits = 5; item->meshBits = 5;
RemoveActiveItem(itemNumber); RemoveActiveItem(itemNumber);
item->itemFlags[0] = 1; // I use this for not making it activable again by trigger item->itemFlags[0] = 1; // I use this for not making it activable again by trigger
@ -753,7 +753,7 @@ void TurnSwitchControl(short itemNum)
l->frameNumber >= g_Level.Anims[LA_TURNSWITCH_PUSH_CLOCKWISE_START].frameBase + 58 && l->frameNumber >= g_Level.Anims[LA_TURNSWITCH_PUSH_CLOCKWISE_START].frameBase + 58 &&
l->frameNumber <= g_Level.Anims[LA_TURNSWITCH_PUSH_CLOCKWISE_START].frameBase + 115) l->frameNumber <= g_Level.Anims[LA_TURNSWITCH_PUSH_CLOCKWISE_START].frameBase + 115)
{ {
SoundEffect(SFX_PUSHABLE_SOUND, &item->pos, 2); SoundEffect(SFX_TR4_PUSHABLE_SOUND, &item->pos, 2);
} }
} }
else else
@ -780,7 +780,7 @@ void TurnSwitchControl(short itemNum)
l->frameNumber >= g_Level.Anims[LA_TURNSWITCH_PUSH_COUNTER_CLOCKWISE_START].frameBase + 58 && l->frameNumber >= g_Level.Anims[LA_TURNSWITCH_PUSH_COUNTER_CLOCKWISE_START].frameBase + 58 &&
l->frameNumber <= g_Level.Anims[LA_TURNSWITCH_PUSH_COUNTER_CLOCKWISE_START].frameBase + 115) l->frameNumber <= g_Level.Anims[LA_TURNSWITCH_PUSH_COUNTER_CLOCKWISE_START].frameBase + 115)
{ {
SoundEffect(SFX_PUSHABLE_SOUND, &item->pos, 2); SoundEffect(SFX_TR4_PUSHABLE_SOUND, &item->pos, 2);
} }
} }
@ -1394,43 +1394,44 @@ void CogSwitchCollision(short itemNum, ITEM_INFO* l, COLL_INFO* coll)
} }
} }
void CogSwitchControl(short itemNum) void CogSwitchControl(short itemNumber)
{ {
ITEM_INFO* item = &g_Level.Items[itemNum]; ITEM_INFO* item = &g_Level.Items[itemNumber];
AnimateItem(item); AnimateItem(item);
if (item->currentAnimState == 1) if (item->currentAnimState == 1)
{ {
if (item->goalAnimState == 1 && !(TrInput & IN_ACTION)) if (item->goalAnimState == 1 && !(TrInput & IN_ACTION))
{ {
LaraItem->goalAnimState = LS_COGWHEEL_UNGRAB; LaraItem->goalAnimState = LS_STOP;
item->goalAnimState = 0; item->goalAnimState = 0;
} }
if (LaraItem->animNumber == LA_COGWHEEL_PULL) if (LaraItem->animNumber == LA_COGWHEEL_PULL)
{ {
if (LaraItem->frameNumber == (g_Level.Anims[LA_COGWHEEL_PULL].frameBase + 10)) if (LaraItem->frameNumber == g_Level.Anims[LA_COGWHEEL_PULL].frameBase + 10)
{ {
ITEM_INFO* it = (ITEM_INFO*)Lara.generalPtr; ITEM_INFO* it = (ITEM_INFO*)Lara.generalPtr;
it->itemFlags[0] = 40; it->itemFlags[0] = 40;
Lara.generalPtr = (ITEM_INFO*)it; Lara.generalPtr = (ITEM_INFO*)it;
SoundEffect(SFX_STONE_SCRAPE_FAST, &it->pos, 0);
} }
} }
} }
else else
{ {
if (item->frameNumber == g_Level.Anims[item->animNumber].frameEnd && LaraItem->animNumber != LA_COGWHEEL_RELEASE) if (item->frameNumber == g_Level.Anims[item->animNumber].frameEnd)
{ {
item->currentAnimState = 0; item->currentAnimState = 0;
item->status = ITEM_NOT_ACTIVE; item->status = ITEM_NOT_ACTIVE;
RemoveActiveItem(itemNum);
// LaraItem->animNumber = LA_STAND_SOLID; RemoveActiveItem(itemNumber);
// LaraItem->frameNumber = g_Level.Anims[LaraItem->animNumber].frameBase;
LaraItem->goalAnimState = LS_COGWHEEL_UNGRAB; LaraItem->animNumber = LA_STAND_SOLID;
// LaraItem->currentAnimState = LS_STOP; LaraItem->frameNumber = g_Level.Anims[item->animNumber].frameBase;
// Lara.gunStatus = LG_NO_ARMS; /*must add this as an anim command instead to avoid trouble!*/ LaraItem->goalAnimState = LS_STOP;
LaraItem->currentAnimState = LS_STOP;
Lara.gunStatus = LG_NO_ARMS;
} }
} }
} }

View file

@ -968,7 +968,7 @@ void UpdateGunShells()
int ceiling = GetCeiling(floor, gs->pos.xPos, gs->pos.yPos, gs->pos.zPos); int ceiling = GetCeiling(floor, gs->pos.xPos, gs->pos.yPos, gs->pos.zPos);
if (gs->pos.yPos < ceiling) if (gs->pos.yPos < ceiling)
{ {
SoundEffect(SFX_LARA_SHOTGUN_SHELL, &gs->pos, 0); SoundEffect(SFX_TR4_LARA_SHOTGUN_SHELL, &gs->pos, 0);
gs->speed -= 4; gs->speed -= 4;
if (gs->speed < 8) if (gs->speed < 8)
@ -984,7 +984,7 @@ void UpdateGunShells()
int height = GetFloorHeight(floor, gs->pos.xPos, gs->pos.yPos, gs->pos.zPos); int height = GetFloorHeight(floor, gs->pos.xPos, gs->pos.yPos, gs->pos.zPos);
if (gs->pos.yPos >= height) if (gs->pos.yPos >= height)
{ {
SoundEffect(SFX_LARA_SHOTGUN_SHELL, &gs->pos, 0); SoundEffect(SFX_TR4_LARA_SHOTGUN_SHELL, &gs->pos, 0);
gs->speed -= 8; gs->speed -= 8;
if (gs->speed >= 8) if (gs->speed >= 8)
{ {
@ -1046,7 +1046,7 @@ void LaraBubbles(ITEM_INFO* item)
PHD_VECTOR pos; PHD_VECTOR pos;
int num, i; int num, i;
SoundEffect(SFX_LARA_BUBBLES, &item->pos, 1); SoundEffect(SFX_TR4_LARA_BUBBLES, &item->pos, 1);
pos.x = 0; pos.x = 0;
@ -1349,7 +1349,7 @@ void TriggerShockwave(PHD_3DPOS* pos, short innerRad, short outerRad, int speed,
sptr->b = b; sptr->b = b;
sptr->life = life; sptr->life = life;
SoundEffect(SFX_IMP_STONE_HIT, pos, 0); SoundEffect(SFX_TR5_IMP_STONE_HIT, pos, 0);
} }
} }

View file

@ -68,7 +68,7 @@ void FlameEmitterControl(short itemNumber)
if ((flags & 7) == 2 || (flags & 7) == 7) if ((flags & 7) == 2 || (flags & 7) == 7)
{ {
PHD_3DPOS* pos = &item->pos; PHD_3DPOS* pos = &item->pos;
SoundEffect(SFX_D_METAL_CAGE_OPEN, &item->pos, 0); SoundEffect(SFX_TR4_FLAME_EMITTER, &item->pos, 0);
TriggerSuperJetFlame(item, -256 - (3072 * GlobalCounter & 0x1C00), GlobalCounter & 1); TriggerSuperJetFlame(item, -256 - (3072 * GlobalCounter & 0x1C00), GlobalCounter & 1);
g = (GetRandomControl() & 0x1F) + 96; g = (GetRandomControl() & 0x1F) + 96;
r = (GetRandomControl() & 0x3F) + 192; r = (GetRandomControl() & 0x3F) + 192;
@ -110,7 +110,7 @@ void FlameEmitterControl(short itemNumber)
if (item->itemFlags[1]) if (item->itemFlags[1])
{ {
SoundEffect(SFX_D_METAL_CAGE_OPEN, &item->pos, 0); SoundEffect(SFX_TR4_FLAME_EMITTER, &item->pos, 0);
if (item->itemFlags[1] <= -8192) if (item->itemFlags[1] <= -8192)
TriggerSuperJetFlame(item, -256 - (3072 * GlobalCounter & 0x1C00), GlobalCounter & 1); TriggerSuperJetFlame(item, -256 - (3072 * GlobalCounter & 0x1C00), GlobalCounter & 1);
@ -131,7 +131,7 @@ void FlameEmitterControl(short itemNumber)
} }
} }
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &item->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &item->pos, 0);
return; return;
} }
@ -142,7 +142,7 @@ void FlameEmitterControl(short itemNumber)
falloff = 16 - (GetRandomControl() & 1); falloff = 16 - (GetRandomControl() & 1);
TriggerDynamicLight(item->pos.xPos, item->pos.yPos, item->pos.zPos, falloff, r, g, 0); TriggerDynamicLight(item->pos.xPos, item->pos.yPos, item->pos.zPos, falloff, r, g, 0);
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &item->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &item->pos, 0);
if (!Lara.burn if (!Lara.burn
&& item->triggerFlags != 33 && item->triggerFlags != 33
@ -204,7 +204,7 @@ void FlameEmitter2Control(short itemNumber)
TriggerDynamicLight(item->pos.xPos, item->pos.yPos, item->pos.zPos, 10, r, g, 0); TriggerDynamicLight(item->pos.xPos, item->pos.yPos, item->pos.zPos, 10, r, g, 0);
} }
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &item->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &item->pos, 0);
} }
} }
} }
@ -266,7 +266,7 @@ void FlameControl(short fxNumber)
int wh = GetWaterHeight(fx->pos.xPos, fx->pos.yPos, fx->pos.zPos, fx->roomNumber); int wh = GetWaterHeight(fx->pos.xPos, fx->pos.yPos, fx->pos.zPos, fx->roomNumber);
if (wh == NO_HEIGHT || fx->pos.yPos <= wh || Lara.burnBlue) if (wh == NO_HEIGHT || fx->pos.yPos <= wh || Lara.burnBlue)
{ {
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &fx->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &fx->pos, 0);
LaraItem->hitPoints -= 7; LaraItem->hitPoints -= 7;
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
@ -316,7 +316,7 @@ void FallingBlockCollision(short itemNum, ITEM_INFO* l, COLL_INFO* coll)
{ {
if (!((item->pos.xPos ^ l->pos.xPos) & 0xFFFFFC00) && !((l->pos.zPos ^ item->pos.zPos) & 0xFFFFFC00)) if (!((item->pos.xPos ^ l->pos.xPos) & 0xFFFFFC00) && !((l->pos.zPos ^ item->pos.zPos) & 0xFFFFFC00))
{ {
SoundEffect(SFX_ROCK_FALL_CRUMBLE, &item->pos, 0); SoundEffect(SFX_TR4_ROCK_FALL_CRUMBLE, &item->pos, 0);
AddActiveItem(itemNum); AddActiveItem(itemNum);
item->itemFlags[0] = 0; item->itemFlags[0] = 0;
@ -534,7 +534,7 @@ void WreckingBallControl(short itemNumber)
} }
if (item->itemFlags[0] == 1) if (item->itemFlags[0] == 1)
{ {
SoundEffect(SFX_GRAB_MOTOR_B_LP, &item->pos, 0); SoundEffect(SFX_TR5_J_GRAB_MOTOR_B_LP, &item->pos, 0);
adx = abs(dx); adx = abs(dx);
if (adx >= 32) if (adx >= 32)
adx = 32; adx = 32;
@ -553,7 +553,7 @@ void WreckingBallControl(short itemNumber)
} }
if (item->itemFlags[0] == 2) if (item->itemFlags[0] == 2)
{ {
SoundEffect(SFX_GRAB_MOTOR_B_LP, &item->pos, 0); SoundEffect(SFX_TR5_J_GRAB_MOTOR_B_LP, &item->pos, 0);
adz = abs(dz); adz = abs(dz);
if (adz >= 32) if (adz >= 32)
adz = 32; adz = 32;
@ -573,7 +573,7 @@ void WreckingBallControl(short itemNumber)
if (item->itemFlags[1] == -1 && (oldX != item->pos.xPos || oldZ != item->pos.zPos)) if (item->itemFlags[1] == -1 && (oldX != item->pos.xPos || oldZ != item->pos.zPos))
{ {
item->itemFlags[1] = 0; item->itemFlags[1] = 0;
SoundEffect(SFX_GRAB_MOTOR_A, &item->pos, 0); SoundEffect(SFX_TR5_J_GRAB_MOTOR_A, &item->pos, 0);
} }
if ((item->pos.xPos & 0x3FF) == 512 && (item->pos.zPos & 0x3FF) == 512) if ((item->pos.xPos & 0x3FF) == 512 && (item->pos.zPos & 0x3FF) == 512)
item->itemFlags[0] = 0; item->itemFlags[0] = 0;
@ -581,8 +581,8 @@ void WreckingBallControl(short itemNumber)
{ {
if (item->itemFlags[1] != -1) if (item->itemFlags[1] != -1)
{ {
StopSoundEffect(SFX_GRAB_MOTOR_B_LP); StopSoundEffect(SFX_TR5_J_GRAB_MOTOR_B_LP);
SoundEffect(SFX_GRAB_MOTOR_C, &item->pos, 0); SoundEffect(SFX_TR5_J_GRAB_MOTOR_C, &item->pos, 0);
} }
item->itemFlags[1] = 1; item->itemFlags[1] = 1;
item->triggerFlags = 30; item->triggerFlags = 30;
@ -600,7 +600,7 @@ void WreckingBallControl(short itemNumber)
} }
else if (item->frameNumber == g_Level.Anims[item->animNumber].frameEnd) else if (item->frameNumber == g_Level.Anims[item->animNumber].frameEnd)
{ {
SoundEffect(SFX_GRAB_DROP, &item->pos, 0); SoundEffect(SFX_TR5_J_GRAB_DROP, &item->pos, 0);
++item->itemFlags[1]; ++item->itemFlags[1];
item->fallspeed = 6; item->fallspeed = 6;
item->pos.yPos += item->fallspeed; item->pos.yPos += item->fallspeed;
@ -637,12 +637,12 @@ void WreckingBallControl(short itemNumber)
item->pos.yPos += item->fallspeed; item->pos.yPos += item->fallspeed;
if (item->pos.yPos < item2->pos.yPos + 1644) if (item->pos.yPos < item2->pos.yPos + 1644)
{ {
StopSoundEffect(SFX_GRAB_WINCH_UP_LP); StopSoundEffect(SFX_TR5_J_GRAB_WINCH_UP_LP);
item->itemFlags[0] = 1; item->itemFlags[0] = 1;
item->pos.yPos = item2->pos.yPos + 1644; item->pos.yPos = item2->pos.yPos + 1644;
if (item->fallspeed < -32) if (item->fallspeed < -32)
{ {
SoundEffect(SFX_GRAB_IMPACT, &item->pos, 4104); SoundEffect(SFX_TR5_J_GRAB_IMPACT, &item->pos, 4104);
item->fallspeed = -item->fallspeed / 8; item->fallspeed = -item->fallspeed / 8;
BounceCamera(item, 16, 8192); BounceCamera(item, 16, 8192);
} }
@ -655,7 +655,7 @@ void WreckingBallControl(short itemNumber)
} }
else if (!item->itemFlags[0]) else if (!item->itemFlags[0])
{ {
SoundEffect(SFX_GRAB_WINCH_UP_LP, &item->pos, 0); SoundEffect(SFX_TR5_J_GRAB_WINCH_UP_LP, &item->pos, 0);
} }
} }
item2->pos.xPos = item->pos.xPos; item2->pos.xPos = item->pos.xPos;
@ -899,7 +899,7 @@ void FlameEmitter3Control(short itemNumber)
{ {
// Electricity bolts // Electricity bolts
SoundEffect(SFX_2GUNTEX_HIT_GUNS, &item->pos, 0); SoundEffect(SFX_TR4_ELEC_ARCING_LOOP, &item->pos, 0);
byte g = (GetRandomControl() & 0x3F) + 192; byte g = (GetRandomControl() & 0x3F) + 192;
byte b = (GetRandomControl() & 0x3F) + 192; byte b = (GetRandomControl() & 0x3F) + 192;
@ -1005,7 +1005,7 @@ void FlameEmitter3Control(short itemNumber)
TriggerFireFlame(x + item->pos.xPos, item->pos.yPos, z + item->pos.zPos, -1, 2); TriggerFireFlame(x + item->pos.xPos, item->pos.yPos, z + item->pos.zPos, -1, 2);
} }
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &item->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &item->pos, 0);
TriggerDynamicLight(x, item->pos.yPos, z, 12, (GetRandomControl() & 0x3F) + 192, ((GetRandomControl() / 16) & 0x1F) + 96, 0); TriggerDynamicLight(x, item->pos.yPos, z, 12, (GetRandomControl() & 0x3F) + 192, ((GetRandomControl() / 16) & 0x1F) + 96, 0);

View file

@ -147,7 +147,7 @@ void ElectricityWiresControl(short itemNumber)
if (TriggerActive(item)) if (TriggerActive(item))
{ {
SoundEffect(SFX_ELECTRIC_WIRES, &item->pos, 0); SoundEffect(SFX_TR5_ELECTRIC_WIRES, &item->pos, 0);
counter = (abs(LaraItem->pos.xPos - item->pos.xPos) > 2048) counter = (abs(LaraItem->pos.xPos - item->pos.xPos) > 2048)
+ (abs(LaraItem->pos.zPos - item->pos.zPos) > 2048) + (abs(LaraItem->pos.zPos - item->pos.zPos) > 2048)
@ -265,7 +265,7 @@ void ElectricityWiresControl(short itemNumber)
{ {
if (LaraItem->hitPoints > 32) if (LaraItem->hitPoints > 32)
{ {
SoundEffect(SFX_LARA_ELECTRIC_CRACKLES, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_ELECTRIC_CRACKLES, &LaraItem->pos, 0);
TriggerLaraElectricitySparks(0); TriggerLaraElectricitySparks(0);
TriggerLaraElectricitySparks(1); TriggerLaraElectricitySparks(1);
TriggerDynamicLight(pos1.x, pos1.y, pos1.z, 8, 0, GetRandomControl() & 0x7F, (GetRandomControl() & 0x3F) + 128); TriggerDynamicLight(pos1.x, pos1.y, pos1.z, 8, 0, GetRandomControl() & 0x7F, (GetRandomControl() & 0x3F) + 128);

View file

@ -19,7 +19,7 @@ static void XianDamage(ITEM_INFO* item, CREATURE_INFO* xian, int damage)
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect(item, &spearRightBite, DoBloodSplat); CreatureEffect(item, &spearRightBite, DoBloodSplat);
xian->flags |= 1; xian->flags |= 1;
SoundEffect(SFX_TR2_CRUNCH3, &item->pos, 0); SoundEffect(SFX_TR2_CRUNCH2, &item->pos, 0);
} }
if (!(xian->flags & 2) && (item->touchBits & 0x800)) if (!(xian->flags & 2) && (item->touchBits & 0x800))
@ -28,7 +28,7 @@ static void XianDamage(ITEM_INFO* item, CREATURE_INFO* xian, int damage)
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect(item, &spearLeftBite, DoBloodSplat); CreatureEffect(item, &spearLeftBite, DoBloodSplat);
xian->flags |= 2; xian->flags |= 2;
SoundEffect(SFX_TR2_CRUNCH3, &item->pos, 0); SoundEffect(SFX_TR2_CRUNCH2, &item->pos, 0);
} }
} }

View file

@ -55,8 +55,8 @@ void SwordGuardianControl(short itemNum)
if (item->currentAnimState != 12) if (item->currentAnimState != 12)
{ {
//item->meshBits >>= 1; //item->meshBits >>= 1;
SoundEffect(SFX_EXPLOSION1, &LaraItem->pos, 0); SoundEffect(SFX_TR4_EXPLOSION1, &LaraItem->pos, 0);
SoundEffect(SFX_EXPLOSION2, &LaraItem->pos, 0); SoundEffect(SFX_TR4_EXPLOSION2, &LaraItem->pos, 0);
//item->meshBits = 0xFFFFFFFF; //item->meshBits = 0xFFFFFFFF;
//item->objectNumber = ID_SAS; //item->objectNumber = ID_SAS;
ExplodingDeath(itemNum, -1, 256); ExplodingDeath(itemNum, -1, 256);

View file

@ -602,7 +602,7 @@ int SpeedBoatDynamics(short itemNum)
{ {
LaraItem->hitPoints -= boat->speed; LaraItem->hitPoints -= boat->speed;
LaraItem->hitStatus = 1; LaraItem->hitStatus = 1;
SoundEffect(SFX_TR2_LARA_GETTING_HURT, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_INJURY, &LaraItem->pos, 0);
newspeed /= 2; newspeed /= 2;
boat->speed /= 2; boat->speed /= 2;
} }
@ -1030,7 +1030,7 @@ void SpeedBoatControl(short itemNumber)
binfo->pitch += ((pitch - binfo->pitch) / 4); binfo->pitch += ((pitch - binfo->pitch) / 4);
if (boat->speed > 8) if (boat->speed > 8)
SoundEffect(SFX_TR2_BOAT_HIGH_ENGINE_RPM, &boat->pos, 4 + ((0x10000 - (BOAT_MAX_SPEED - binfo->pitch) * 100) * 256)); SoundEffect(SFX_TR2_BOAT_ACCELERATE, &boat->pos, 4 + ((0x10000 - (BOAT_MAX_SPEED - binfo->pitch) * 100) * 256));
else if (drive) else if (drive)
SoundEffect(SFX_TR2_BOAT_IDLE, &boat->pos, 4 + ((0x10000 - (BOAT_MAX_SPEED - binfo->pitch) * 100) * 256)); SoundEffect(SFX_TR2_BOAT_IDLE, &boat->pos, 4 + ((0x10000 - (BOAT_MAX_SPEED - binfo->pitch) * 100) * 256));

View file

@ -212,8 +212,8 @@ void SkidooExplode(ITEM_INFO* skidoo)
// KillItem(Lara.Vehicle); // KillItem(Lara.Vehicle);
skidoo->status = ITEM_DEACTIVATED; skidoo->status = ITEM_DEACTIVATED;
SoundEffect(SFX_EXPLOSION1, 0, 0); SoundEffect(SFX_TR4_EXPLOSION1, 0, 0);
SoundEffect(SFX_EXPLOSION2, 0, 0); SoundEffect(SFX_TR4_EXPLOSION2, 0, 0);
Lara.Vehicle = NO_ITEM; Lara.Vehicle = NO_ITEM;
} }
@ -294,7 +294,7 @@ bool SkidooCheckGetOff()
LaraItem->pos.yPos -= 200; LaraItem->pos.yPos -= 200;
LaraItem->fallspeed = skidoo->fallspeed; LaraItem->fallspeed = skidoo->fallspeed;
LaraItem->speed = skidoo->speed; LaraItem->speed = skidoo->speed;
SoundEffect(SFX_LARA_FALL, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_FALL, &LaraItem->pos, 0);
} }
LaraItem->pos.xRot = LaraItem->pos.zRot = 0; LaraItem->pos.xRot = LaraItem->pos.zRot = 0;
@ -989,13 +989,13 @@ bool SkidooControl()
skinfo->trackMesh = ((skinfo->trackMesh & 3) == 1) ? 2 : 1; skinfo->trackMesh = ((skinfo->trackMesh & 3) == 1) ? 2 : 1;
skinfo->pitch += (pitch - skinfo->pitch) / 4; skinfo->pitch += (pitch - skinfo->pitch) / 4;
SoundEffect(SFX_TR2_SNOWMOBILE_HIGH_ENGINE_RPM, &skidoo->pos, 4 + ((0x10000 - (SKIDOO_MAX_SPEED - skinfo->pitch) * 100) * 256)); SoundEffect(SFX_TR2_SKIDOO_ACCELERATE, &skidoo->pos, 4 + ((0x10000 - (SKIDOO_MAX_SPEED - skinfo->pitch) * 100) * 256));
} }
else else
{ {
skinfo->trackMesh = 0; skinfo->trackMesh = 0;
if (!drive) if (!drive)
SoundEffect(SFX_TR2_SNOWMOBILE_IDLE, &skidoo->pos, 0); SoundEffect(SFX_TR2_SKIDOO_IDLE, &skidoo->pos, 0);
skinfo->pitch = 0; skinfo->pitch = 0;
} }
skidoo->floor = height; skidoo->floor = height;

View file

@ -320,7 +320,7 @@ void MPStickControl(short itemNumber)
LaraItem->hitPoints -= 80; LaraItem->hitPoints -= 80;
LaraItem->hitStatus = 1; LaraItem->hitStatus = 1;
CreatureEffect(item, &mpstickBite1, DoBloodSplat); CreatureEffect(item, &mpstickBite1, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
creature->flags = 1; creature->flags = 1;
} }
@ -337,7 +337,7 @@ void MPStickControl(short itemNumber)
enemy->hitStatus = 1; enemy->hitStatus = 1;
creature->flags = 1; creature->flags = 1;
CreatureEffect(item, &mpstickBite1, DoBloodSplat); CreatureEffect(item, &mpstickBite1, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
} }
} }
} }
@ -359,7 +359,7 @@ void MPStickControl(short itemNumber)
LaraItem->hitPoints -= 80; LaraItem->hitPoints -= 80;
LaraItem->hitStatus = 1; LaraItem->hitStatus = 1;
CreatureEffect(item, &mpstickBite1, DoBloodSplat); CreatureEffect(item, &mpstickBite1, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
creature->flags = 1; creature->flags = 1;
} }
@ -376,7 +376,7 @@ void MPStickControl(short itemNumber)
enemy->hitStatus = 1; enemy->hitStatus = 1;
creature->flags = 1; creature->flags = 1;
CreatureEffect(item, &mpstickBite1, DoBloodSplat); CreatureEffect(item, &mpstickBite1, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
} }
} }
@ -419,7 +419,7 @@ void MPStickControl(short itemNumber)
enemy->hitStatus = 1; enemy->hitStatus = 1;
creature->flags = 2; creature->flags = 2;
CreatureEffect(item, &mpstickBite1, DoBloodSplat); CreatureEffect(item, &mpstickBite1, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
} }
} }
} }
@ -438,7 +438,7 @@ void MPStickControl(short itemNumber)
LaraItem->hitPoints -= 150; LaraItem->hitPoints -= 150;
LaraItem->hitStatus = 1; LaraItem->hitStatus = 1;
CreatureEffect(item, &mpstickBite2, DoBloodSplat); CreatureEffect(item, &mpstickBite2, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
creature->flags = 1; creature->flags = 1;
} }
@ -455,7 +455,7 @@ void MPStickControl(short itemNumber)
enemy->hitStatus = 1; enemy->hitStatus = 1;
creature->flags = 1; creature->flags = 1;
CreatureEffect(item, &mpstickBite2, DoBloodSplat); CreatureEffect(item, &mpstickBite2, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
} }
} }
} }

View file

@ -110,7 +110,7 @@ static void ShivaDamage(ITEM_INFO* item, CREATURE_INFO* shiva, int damage)
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect(item, &shivaRightBite, DoBloodSplat); CreatureEffect(item, &shivaRightBite, DoBloodSplat);
shiva->flags = 1; shiva->flags = 1;
SoundEffect(SFX_TR2_CRUNCH3, &item->pos, 0); SoundEffect(SFX_TR2_CRUNCH2, &item->pos, 0);
} }
if (!(shiva->flags) && (item->touchBits & 0x2400)) if (!(shiva->flags) && (item->touchBits & 0x2400))
@ -119,7 +119,7 @@ static void ShivaDamage(ITEM_INFO* item, CREATURE_INFO* shiva, int damage)
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect(item, &shivaLeftBite, DoBloodSplat); CreatureEffect(item, &shivaLeftBite, DoBloodSplat);
shiva->flags = 1; shiva->flags = 1;
SoundEffect(SFX_TR2_CRUNCH3, &item->pos, 0); SoundEffect(SFX_TR2_CRUNCH2, &item->pos, 0);
} }
} }

View file

@ -83,7 +83,7 @@ void FireBigGun(ITEM_INFO *obj)
for (int i = 0; i < 5; i++) for (int i = 0; i < 5; i++)
TriggerGunSmoke(pos.x, pos.y, pos.z, 0, 0, 0, 1, WEAPON_ROCKET_LAUNCHER, 32); TriggerGunSmoke(pos.x, pos.y, pos.z, 0, 0, 0, 1, WEAPON_ROCKET_LAUNCHER, 32);
SoundEffect(SFX_EXPLOSION1, 0, 0); SoundEffect(SFX_TR4_EXPLOSION1, 0, 0);
} }
} }

View file

@ -155,8 +155,8 @@ static void QuadbikeExplode(ITEM_INFO* item)
TriggerShockwave(&PHD_3DPOS(item->pos.xPos, item->pos.yPos - 128, item->pos.zPos, 0, item->pos.yRot, 0), 50, 180, 40, generateFloat(160, 200), 60, 60, 64, generateFloat(0, 359), 0); TriggerShockwave(&PHD_3DPOS(item->pos.xPos, item->pos.yPos - 128, item->pos.zPos, 0, item->pos.yRot, 0), 50, 180, 40, generateFloat(160, 200), 60, 60, 64, generateFloat(0, 359), 0);
item->status = ITEM_DEACTIVATED; item->status = ITEM_DEACTIVATED;
SoundEffect(SFX_EXPLOSION1, NULL, 0); SoundEffect(SFX_TR4_EXPLOSION1, NULL, 0);
SoundEffect(SFX_EXPLOSION2, NULL, 0); SoundEffect(SFX_TR4_EXPLOSION2, NULL, 0);
Lara.Vehicle = NO_ITEM; Lara.Vehicle = NO_ITEM;
} }

View file

@ -437,7 +437,7 @@ static int RubberBoatDynamics(short boat_number)
{ {
LaraItem->hitPoints -= boat->speed; LaraItem->hitPoints -= boat->speed;
LaraItem->hitStatus = 1; LaraItem->hitStatus = 1;
SoundEffect(SFX_LARA_INJURY_RND, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_INJURY, &LaraItem->pos, 0);
newspeed /= 2; newspeed /= 2;
boat->speed /= 2; boat->speed /= 2;
} }

View file

@ -59,7 +59,7 @@ void GuideControl(short itemNumber)
GetJointAbsPosition(item, &pos, guideBiteInfo1.meshNum); GetJointAbsPosition(item, &pos, guideBiteInfo1.meshNum);
AddFire(pos.x, pos.y, pos.z, 0, item->roomNumber, 0); AddFire(pos.x, pos.y, pos.z, 0, item->roomNumber, 0);
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &item->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &item->pos, 0);
TriggerFireFlame(pos.x, pos.y - 40, pos.z, -1, 7); TriggerFireFlame(pos.x, pos.y - 40, pos.z, -1, 7);
short random = GetRandomControl(); short random = GetRandomControl();

View file

@ -233,8 +233,8 @@ void SentryGunControl(short itemNum)
for (int i = 0; i < 2; i++) for (int i = 0; i < 2; i++)
TriggerExplosionSparks(item->pos.xPos, item->pos.yPos - 768, item->pos.zPos, 3, -1, 0, item->roomNumber); TriggerExplosionSparks(item->pos.xPos, item->pos.yPos - 768, item->pos.zPos, 3, -1, 0, item->roomNumber);
SoundEffect(SFX_EXPLOSION1, &item->pos, 25165828); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, 25165828);
SoundEffect(SFX_EXPLOSION2, &item->pos, 0); SoundEffect(SFX_TR4_EXPLOSION2, &item->pos, 0);
} }
} }
} }

View file

@ -590,7 +590,7 @@ void SkeletonControl(short itemNumber)
LaraItem->hitPoints -= 80; LaraItem->hitPoints -= 80;
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect2(item, &skeletonBite, 15, -1, DoBloodSplat); CreatureEffect2(item, &skeletonBite, 15, -1, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
creature->flags = 1; creature->flags = 1;
} }
} }
@ -651,7 +651,7 @@ void SkeletonControl(short itemNumber)
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect2(item, &skeletonBite, 10, item->pos.yRot, DoBloodSplat); CreatureEffect2(item, &skeletonBite, 10, item->pos.yRot, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
creature->flags = 1; creature->flags = 1;
} }

View file

@ -64,7 +64,7 @@ void SphinxControl(short itemNumber)
if (((mesh->z / 1024) == (z / 1024)) && ((mesh->x / 1024) == (x / 1024)) && mesh->staticNumber >= 50) if (((mesh->z / 1024) == (z / 1024)) && ((mesh->x / 1024) == (x / 1024)) && mesh->staticNumber >= 50)
{ {
ShatterObject(NULL, mesh, -64, item->roomNumber, 0); ShatterObject(NULL, mesh, -64, item->roomNumber, 0);
SoundEffect(SFX_SMASH_ROCK, &item->pos, 0); SoundEffect(SFX_TR4_HIT_ROCK, &item->pos, 0);
mesh->flags &= ~0x100; mesh->flags &= ~0x100;
floor->stopper = false; floor->stopper = false;

View file

@ -25,7 +25,7 @@ void ElementPuzzleControl(short itemNumber)
if (item->triggerFlags == 1) if (item->triggerFlags == 1)
{ {
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &item->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &item->pos, 0);
byte r = (GetRandomControl() & 0x3F) + 192; byte r = (GetRandomControl() & 0x3F) + 192;
byte g = (GetRandomControl() & 0x1F) + 96; byte g = (GetRandomControl() & 0x1F) + 96;

View file

@ -15,7 +15,7 @@ void LaraDoubleControl(short itemNum)
{ {
ITEM_INFO* item = &g_Level.Items[itemNum]; ITEM_INFO* item = &g_Level.Items[itemNum];
SoundEffect(SFX_TR4_METAL_SCRAPE_LOOP, &item->pos, 0); SoundEffect(SFX_TR4_METAL_SCRAPE_LOOP1, &item->pos, 0);
if (CreatureActive(itemNum)) if (CreatureActive(itemNum))
{ {

View file

@ -23,9 +23,9 @@ void MineControl(short itemNum)
int num = GetSpheres(item, CreatureSpheres, SPHERES_SPACE_WORLD, Matrix::Identity); int num = GetSpheres(item, CreatureSpheres, SPHERES_SPACE_WORLD, Matrix::Identity);
if (item->itemFlags[0] >= 150) if (item->itemFlags[0] >= 150)
{ {
SoundEffect(SFX_EXPLOSION1, &item->pos, 0); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, 0);
SoundEffect(SFX_EXPLOSION2, &item->pos, 0); SoundEffect(SFX_TR4_EXPLOSION2, &item->pos, 0);
SoundEffect(SFX_EXPLOSION1, &item->pos, PITCH_SHIFT | 0x1800000); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, PITCH_SHIFT | 0x1800000);
if (num > 0) if (num > 0)
{ {
@ -85,7 +85,7 @@ void MineControl(short itemNum)
sphere++; sphere++;
} }
SoundEffect(SFX_LOOP_FOR_SMALL_FIRES, &item->pos, 0); SoundEffect(SFX_TR4_LOOP_FOR_SMALL_FIRES, &item->pos, 0);
} }
} }

View file

@ -26,7 +26,7 @@ void SlicerDicerControl(short itemNum)
ITEM_INFO* item = &g_Level.Items[itemNum]; ITEM_INFO* item = &g_Level.Items[itemNum];
SoundEffect(SFX_TR4_METAL_SCRAPE_LOOP1, &item->pos, 0); SoundEffect(SFX_TR4_METAL_SCRAPE_LOOP1, &item->pos, 0);
SoundEffect(SFX_TR4_METAL_SCRAPE_LOOP, &item->pos, 0); SoundEffect(SFX_TR4_METAL_SCRAPE_LOOP2, &item->pos, 0);
int factor = 4608 * phd_cos(item->triggerFlags) * phd_cos(item->pos.yRot); int factor = 4608 * phd_cos(item->triggerFlags) * phd_cos(item->pos.yRot);

View file

@ -23,7 +23,7 @@ void ControlSpikyWall(short itemNum)
if (GetFloorHeight(floor, x, item->pos.yPos, z) != item->pos.yPos) if (GetFloorHeight(floor, x, item->pos.yPos, z) != item->pos.yPos)
{ {
item->status = ITEM_DEACTIVATED; item->status = ITEM_DEACTIVATED;
StopSoundEffect(SFX_ROLLING_BALL); StopSoundEffect(SFX_TR4_ROLLING_BALL);
} }
else else
{ {
@ -31,7 +31,7 @@ void ControlSpikyWall(short itemNum)
item->pos.zPos = z; item->pos.zPos = z;
if (roomNumber != item->roomNumber) if (roomNumber != item->roomNumber)
ItemNewRoom(itemNum, roomNumber); ItemNewRoom(itemNum, roomNumber);
SoundEffect(SFX_ROLLING_BALL, &item->pos, 0); SoundEffect(SFX_TR4_ROLLING_BALL, &item->pos, 0);
} }
} }

View file

@ -667,8 +667,8 @@ static void JeepExplode(ITEM_INFO* item)
ExplodingDeath(Lara.Vehicle, -1, 256); ExplodingDeath(Lara.Vehicle, -1, 256);
KillItem(Lara.Vehicle); KillItem(Lara.Vehicle);
item->status = ITEM_DEACTIVATED; item->status = ITEM_DEACTIVATED;
SoundEffect(SFX_EXPLOSION1, 0, 0); SoundEffect(SFX_TR4_EXPLOSION1, 0, 0);
SoundEffect(SFX_EXPLOSION2, 0, 0); SoundEffect(SFX_TR4_EXPLOSION2, 0, 0);
Lara.Vehicle = NO_ITEM; Lara.Vehicle = NO_ITEM;
} }

View file

@ -548,8 +548,8 @@ static void MotorBikeExplode(ITEM_INFO* item)
LaraItem->hitPoints = 0; LaraItem->hitPoints = 0;
item->status = ITEM_DEACTIVATED; item->status = ITEM_DEACTIVATED;
SoundEffect(SFX_EXPLOSION1, NULL, 0); SoundEffect(SFX_TR4_EXPLOSION1, NULL, 0);
SoundEffect(SFX_EXPLOSION2, NULL, 0); SoundEffect(SFX_TR4_EXPLOSION2, NULL, 0);
Lara.Vehicle = NO_ITEM; Lara.Vehicle = NO_ITEM;
} }

View file

@ -225,6 +225,6 @@ void UpdateBats()
{ {
BAT_STRUCT* bat = &Bats[minIndex]; BAT_STRUCT* bat = &Bats[minIndex];
if (!(GetRandomControl() & 4)) if (!(GetRandomControl() & 4))
SoundEffect(SFX_BATS_1, &bat->pos, 0); SoundEffect(SFX_TR5_BATS_1, &bat->pos, 0);
} }
} }

View file

@ -136,6 +136,6 @@ void DartEmitterControl(short itemNumber)
AddActiveItem(dartItemNumber); AddActiveItem(dartItemNumber);
dartItem->status = ITEM_ACTIVE; dartItem->status = ITEM_ACTIVE;
SoundEffect(SFX_LIFT_DOORS, &dartItem->pos, 0); SoundEffect(SFX_TR4_DART_SPITT, &dartItem->pos, 0);
} }
} }

View file

@ -286,12 +286,12 @@ void UpdateRats()
{ {
AddWaterSparks(rat->pos.xPos, r->maxceiling, rat->pos.zPos, 16); AddWaterSparks(rat->pos.xPos, r->maxceiling, rat->pos.zPos, 16);
SetupRipple(rat->pos.xPos, r->maxceiling, rat->pos.zPos, (GetRandomControl() & 3) + 48, 2, Objects[ID_DEFAULT_SPRITES].meshIndex + SPR_RIPPLES); SetupRipple(rat->pos.xPos, r->maxceiling, rat->pos.zPos, (GetRandomControl() & 3) + 48, 2, Objects[ID_DEFAULT_SPRITES].meshIndex + SPR_RIPPLES);
SoundEffect(SFX_RATSPLASH, &rat->pos, 0); SoundEffect(SFX_TR5_RATSPLASH, &rat->pos, 0);
} }
} }
if (!i && !(GetRandomControl() & 4)) if (!i && !(GetRandomControl() & 4))
SoundEffect(SFX_RATS_1, &rat->pos, 0); SoundEffect(SFX_TR5_RATS_1, &rat->pos, 0);
} }
} }
} }

View file

@ -253,7 +253,7 @@ void UpdateSpiders()
} }
if (!i && !(GetRandomControl() & 4)) if (!i && !(GetRandomControl() & 4))
SoundEffect(SFX_BEETLES, &spider->pos, 0); SoundEffect(SFX_TR5_BEETLES, &spider->pos, 0);
} }
} }
} }

View file

@ -100,7 +100,7 @@ void AutoGunsControl(short itemNumber)
if (abs(angle1) < 1024 && abs(angle2) < 1024 && los) if (abs(angle1) < 1024 && abs(angle2) < 1024 && los)
{ {
SoundEffect(SFX_HK_FIRE, &item->pos, 0xC00004); SoundEffect(SFX_TR5_HK_FIRE, &item->pos, 0xC00004);
if (GlobalCounter & 1) if (GlobalCounter & 1)
{ {

View file

@ -109,7 +109,7 @@ void ControlBrowsBeast(short itemNumber)
case 3: case 3:
if (distance < SQUARE(1024) || creature->mood != ATTACK_MOOD) if (distance < SQUARE(1024) || creature->mood != ATTACK_MOOD)
item->goalAnimState = 1; item->goalAnimState = 1;
SoundEffect(SFX_IMP_BARREL_ROLL, &item->pos, 0); SoundEffect(SFX_TR5_IMP_BARREL_ROLL, &item->pos, 0);
break; break;
case 4: case 4:

View file

@ -156,7 +156,7 @@ void ControlChef(short itemNumber)
LaraItem->hitPoints -= 80; LaraItem->hitPoints -= 80;
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect2(item, &ChefBite, 20, item->pos.yRot, DoBloodSplat); CreatureEffect2(item, &ChefBite, 20, item->pos.yRot, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
creature->flags = 1; creature->flags = 1;
} }
} }

View file

@ -182,7 +182,7 @@ void HitmanControl(short itemNumber)
TriggerHitmanSparks(pos.x, pos.y, pos.z, -1, -1, -1); TriggerHitmanSparks(pos.x, pos.y, pos.z, -1, -1, -1);
TriggerDynamicLight(pos.x, pos.y, pos.z, (GetRandomControl() & 3) + 16, 31, 63, 127); TriggerDynamicLight(pos.x, pos.y, pos.z, (GetRandomControl() & 3) + 16, 31, 63, 127);
SoundEffect(SFX_HITMAN_ELEC_SHORT, &item->pos, 0); SoundEffect(SFX_TR5_HITMAN_ELEC_SHORT, &item->pos, 0);
if (random == 5 || random == 7 || random == 10) if (random == 5 || random == 7 || random == 10)
{ {

View file

@ -108,7 +108,7 @@ void InvisibleGhostControl(short itemNumber)
if (item->itemFlags[0] == 0) if (item->itemFlags[0] == 0)
{ {
item->itemFlags[0] = 1; item->itemFlags[0] = 1;
SoundEffect(SFX_SKELETON_APPEAR, &item->pos, 0); SoundEffect(SFX_TR5_SKELETON_APPEAR, &item->pos, 0);
} }
} }

View file

@ -345,7 +345,7 @@ void ControlGladiator(short itemNumber)
LaraItem->hitPoints -= 120; LaraItem->hitPoints -= 120;
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect2(item, &GladiatorBite, 10, item->pos.yRot, DoBloodSplat); CreatureEffect2(item, &GladiatorBite, 10, item->pos.yRot, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
creature->flags = 1; creature->flags = 1;
} }
} }

View file

@ -310,7 +310,7 @@ void GuardControl(short itemNum)
item->itemFlags[0]++; item->itemFlags[0]++;
if (item->itemFlags[0] > 60 && !(GetRandomControl() & 0xF)) if (item->itemFlags[0] > 60 && !(GetRandomControl() & 0xF))
{ {
SoundEffect(SFX_BIO_BREATHE_OUT, &item->pos, 0); SoundEffect(SFX_TR5_BIO_BREATHE_OUT, &item->pos, 0);
item->itemFlags[0] = 0; item->itemFlags[0] = 0;
} }
} }
@ -616,7 +616,7 @@ void GuardControl(short itemNum)
floor = GetFloor(item->pos.xPos, item->pos.yPos, item->pos.zPos, &roomNumber); floor = GetFloor(item->pos.xPos, item->pos.yPos, item->pos.zPos, &roomNumber);
GetFloorHeight(floor, item->pos.xPos, item->pos.yPos, item->pos.zPos); GetFloorHeight(floor, item->pos.xPos, item->pos.yPos, item->pos.zPos);
TestTriggers(TriggerIndex, 1, 0); TestTriggers(TriggerIndex, 1, 0);
SoundEffect(SFX_LARA_ROPEDOWN_LOOP, &item->pos, 0); SoundEffect(SFX_TR4_LARA_POLE_LOOP, &item->pos, 0);
} }
if (abs(info.angle) >= 364) if (abs(info.angle) >= 364)
{ {

View file

@ -20,7 +20,7 @@ void ControlGunShip(short itemNumber)
if (TriggerActive(item)) if (TriggerActive(item))
{ {
SoundEffect(SFX_HELICOPTER_LOOP, &item->pos, 0); SoundEffect(SFX_TR4_HELICOPTER_LOOP, &item->pos, 0);
GAME_VECTOR pos; GAME_VECTOR pos;
pos.x = ((GetRandomControl() & 0x1FF) - 255); pos.x = ((GetRandomControl() & 0x1FF) - 255);
@ -74,7 +74,7 @@ void ControlGunShip(short itemNumber)
item->meshBits &= 0xFEFF; item->meshBits &= 0xFEFF;
if (GunShipCounter < 15) if (GunShipCounter < 15)
SoundEffect(SFX_HK_FIRE, &item->pos, 0xC00004); SoundEffect(SFX_TR5_HK_FIRE, &item->pos, 0xC00004);
if (!(GlobalCounter & 1)) if (!(GlobalCounter & 1))
return AnimateItem(item); return AnimateItem(item);

View file

@ -407,7 +407,7 @@ void HydraControl(short itemNumber)
if (item->itemFlags[3] < 12) if (item->itemFlags[3] < 12)
{ {
ExplodeItemNode(item, 11 - item->itemFlags[3], 0, 64); ExplodeItemNode(item, 11 - item->itemFlags[3], 0, 64);
SoundEffect(SFX_SMASH_ROCK, &item->pos, 0); SoundEffect(SFX_TR4_HIT_ROCK, &item->pos, 0);
item->itemFlags[3]++; item->itemFlags[3]++;
} }
} }

View file

@ -231,7 +231,7 @@ void LaserHeadControl(short itemNumber)
&& tentacleItem->frameNumber == g_Level.Anims[tentacleItem->animNumber].frameEnd && tentacleItem->frameNumber == g_Level.Anims[tentacleItem->animNumber].frameEnd
&& tentacleItem->meshBits & 1) && tentacleItem->meshBits & 1)
{ {
SoundEffect(SFX_SMASH_ROCK, &item->pos, 0); SoundEffect(SFX_TR4_HIT_ROCK, &item->pos, 0);
ExplodeItemNode(tentacleItem, 0, 0, 128); ExplodeItemNode(tentacleItem, 0, 0, 128);
KillItem(creature->tentacles[i]); KillItem(creature->tentacles[i]);
} }
@ -269,10 +269,10 @@ void LaserHeadControl(short itemNumber)
g_Level.Items[creature->puzzleItem].pos.yPos = item->pos.yPos; g_Level.Items[creature->puzzleItem].pos.yPos = item->pos.yPos;
TestTriggersAtXYZ(item->pos.xPos, item->pos.yPos, item->pos.zPos, item->roomNumber, 1, 0); TestTriggersAtXYZ(item->pos.xPos, item->pos.yPos, item->pos.zPos, item->roomNumber, 1, 0);
SoundEffect(SFX_GOD_HEAD_BLAST, &item->pos, 0x800004); SoundEffect(SFX_TR5_GOD_HEAD_BLAST, &item->pos, 0x800004);
SoundEffect(SFX_EXPLOSION2, &item->pos, 20971524); SoundEffect(SFX_TR4_EXPLOSION2, &item->pos, 20971524);
SoundEffect(SFX_EXPLOSION1, &item->pos, 0); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, 0);
SoundEffect(SFX_EXPLOSION1, &item->pos, 4194308); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, 4194308);
KillItem(itemNumber); KillItem(itemNumber);
} }
@ -420,7 +420,7 @@ void LaserHeadControl(short itemNumber)
bool condition = false; bool condition = false;
if (item->itemFlags[3] <= 90) if (item->itemFlags[3] <= 90)
{ {
SoundEffect(SFX_GOD_HEAD_CHARGE, &item->pos, 0); SoundEffect(SFX_TR5_GOD_HEAD_CHARGE, &item->pos, 0);
LaserHeadCharge(item); LaserHeadCharge(item);
item->itemFlags[3]++; item->itemFlags[3]++;
condition = item->itemFlags[3] >= 90; condition = item->itemFlags[3] >= 90;
@ -479,7 +479,7 @@ void LaserHeadControl(short itemNumber)
&& LaserHeadData.fireArcs[j] != NULL) && LaserHeadData.fireArcs[j] != NULL)
{ {
// Eye is aready firing // Eye is aready firing
SoundEffect(SFX_GOD_HEAD_LASER_LOOPS, &item->pos, 0); SoundEffect(SFX_TR5_GOD_HEAD_LASER_LOOPS, &item->pos, 0);
LaserHeadData.fireArcs[j]->pos1.x = src.x; LaserHeadData.fireArcs[j]->pos1.x = src.x;
LaserHeadData.fireArcs[j]->pos1.y = src.y; LaserHeadData.fireArcs[j]->pos1.y = src.y;
@ -491,8 +491,8 @@ void LaserHeadControl(short itemNumber)
src.roomNumber = item->roomNumber; src.roomNumber = item->roomNumber;
LaserHeadData.LOS = LOS(&src, &dest); LaserHeadData.LOS = LOS(&src, &dest);
LaserHeadData.fireArcs[j] = TriggerEnergyArc((PHD_VECTOR*)& src, (PHD_VECTOR*)& dest, 128, g, b, 32, 64, 64, ENERGY_ARC_NO_RANDOMIZE, ENERGY_ARC_STRAIGHT_LINE); // (GetRandomControl() & 7) + 4, b | ((&unk_640000 | g) << 8), 12, 64, 5); LaserHeadData.fireArcs[j] = TriggerEnergyArc((PHD_VECTOR*)& src, (PHD_VECTOR*)& dest, 128, g, b, 32, 64, 64, ENERGY_ARC_NO_RANDOMIZE, ENERGY_ARC_STRAIGHT_LINE); // (GetRandomControl() & 7) + 4, b | ((&unk_640000 | g) << 8), 12, 64, 5);
StopSoundEffect(SFX_GOD_HEAD_CHARGE); StopSoundEffect(SFX_TR5_GOD_HEAD_CHARGE);
SoundEffect(SFX_GOD_HEAD_BLAST, &item->pos, 0); SoundEffect(SFX_TR5_GOD_HEAD_BLAST, &item->pos, 0);
} }
ENERGY_ARC* currentArc = LaserHeadData.fireArcs[j]; ENERGY_ARC* currentArc = LaserHeadData.fireArcs[j];

View file

@ -635,7 +635,7 @@ void RomanStatueControl(short itemNumber)
LaraItem->hitPoints -= 200; LaraItem->hitPoints -= 200;
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
CreatureEffect2(item, &RomanStatueBite, 20, item->pos.yRot, DoBloodSplat); CreatureEffect2(item, &RomanStatueBite, 20, item->pos.yRot, DoBloodSplat);
SoundEffect(SFX_LARA_THUD, &item->pos, 0); SoundEffect(SFX_TR4_LARA_THUD, &item->pos, 0);
creature->flags = 1; creature->flags = 1;
} }
} }

View file

@ -119,7 +119,7 @@ static void SubmarineAttack(ITEM_INFO* item)
{ {
ITEM_INFO* torpedoItem = &g_Level.Items[itemNumber]; ITEM_INFO* torpedoItem = &g_Level.Items[itemNumber];
SoundEffect(SFX_UNDERWATER_TORPEDO, &torpedoItem->pos, 2); SoundEffect(SFX_TR5_UNDERWATER_TORPEDO, &torpedoItem->pos, 2);
torpedoItem->objectNumber = ID_TORPEDO; torpedoItem->objectNumber = ID_TORPEDO;
torpedoItem->shade = -15856; torpedoItem->shade = -15856;
@ -260,7 +260,7 @@ void SubmarineControl(short itemNumber)
if (laraInfo.distance >= SQUARE(3072)) if (laraInfo.distance >= SQUARE(3072))
{ {
item->goalAnimState = 1; item->goalAnimState = 1;
SoundEffect(SFX_MINI_SUB_LOOP, &item->pos, 2); SoundEffect(SFX_TR5_MINI_SUB_LOOP, &item->pos, 2);
} }
else else
{ {
@ -461,7 +461,7 @@ void TorpedoControl(short itemNumber)
{ {
ITEM_INFO* item = &g_Level.Items[itemNumber]; ITEM_INFO* item = &g_Level.Items[itemNumber];
SoundEffect(SFX_SWIMSUIT_METAL_CLASH, &item->pos, 2); SoundEffect(SFX_TR5_SWIMSUIT_METAL_CLASH, &item->pos, 2);
PHD_VECTOR pos; PHD_VECTOR pos;
@ -587,8 +587,8 @@ void TorpedoControl(short itemNumber)
LaraItem->hitStatus = true; LaraItem->hitStatus = true;
KillItem(itemNumber); KillItem(itemNumber);
TriggerUnderwaterExplosion(item, 1); TriggerUnderwaterExplosion(item, 1);
SoundEffect(SFX_UNDERWATER_EXPLOSION, &item->pos, 2); SoundEffect(SFX_TR5_UNDERWATER_EXPLOSION, &item->pos, 2);
SoundEffect(SFX_LARA_UNDERWATER_HIT, &LaraItem->pos, 2); SoundEffect(SFX_TR5_LARA_UNDERWATER_HIT, &LaraItem->pos, 2);
LaraItem->hitPoints -= 200; LaraItem->hitPoints -= 200;
if (Lara.anxiety >= 0x7F) if (Lara.anxiety >= 0x7F)
Lara.anxiety--; Lara.anxiety--;
@ -624,7 +624,7 @@ void TorpedoControl(short itemNumber)
item->pos.yPos = y; item->pos.yPos = y;
item->pos.zPos = z; item->pos.zPos = z;
TriggerUnderwaterExplosion(item, 1); TriggerUnderwaterExplosion(item, 1);
SoundEffect(SFX_UNDERWATER_EXPLOSION, &item->pos, 2); SoundEffect(SFX_TR5_UNDERWATER_EXPLOSION, &item->pos, 2);
KillItem(itemNumber); KillItem(itemNumber);
} }
} }

View file

@ -164,7 +164,7 @@ void ElectricalLightControl(short itemNumber)
intensity = item->itemFlags[1] - (GetRandomControl() & 0x7F); intensity = item->itemFlags[1] - (GetRandomControl() & 0x7F);
if (intensity > 64) if (intensity > 64)
SoundEffect(SFX_ELEC_LIGHT_CRACKLES, &item->pos, 32 * (intensity & 0xFFFFFFF8) | 8); SoundEffect(SFX_TR5_ELEC_LIGHT_CRACKLES, &item->pos, 32 * (intensity & 0xFFFFFFF8) | 8);
} }
else else
{ {

View file

@ -69,7 +69,7 @@ void ControlBodyPart(short fxNumber)
KillEffect(fxNumber); KillEffect(fxNumber);
if (fx->flag2 & 0x800) if (fx->flag2 & 0x800)
SoundEffect(SFX_ROCK_FALL_LAND, &fx->pos, 0); SoundEffect(SFX_TR4_ROCK_FALL_LAND, &fx->pos, 0);
return; return;
} }

View file

@ -108,7 +108,7 @@ void ControlHighObject1(short itemNumber)
flags = item->itemFlags[1] / 8; flags = item->itemFlags[1] / 8;
} }
SoundEffect(SFX_BLK_PLAT_RAISE_LOW, &item->pos, (flags * 256) | 8); SoundEffect(SFX_TR4_BLK_PLAT_RAISE_AND_LOW, &item->pos, (flags * 256) | 8);
item->pos.yPos += 8; item->pos.yPos += 8;
@ -200,7 +200,7 @@ void ControlHighObject1(short itemNumber)
flags = item->itemFlags[1]; flags = item->itemFlags[1];
} }
SoundEffect(SFX_BLK_PLAT_RAISE_LOW, &item->pos, (flags * 256) | 8); SoundEffect(SFX_TR4_BLK_PLAT_RAISE_AND_LOW, &item->pos, (flags * 256) | 8);
item->itemFlags[1] += 16; item->itemFlags[1] += 16;
item->pos.yPos -= 16; item->pos.yPos -= 16;

View file

@ -171,8 +171,8 @@ void MissileControl(short itemNumber)
ExplodeFX(fx, 0, 32); ExplodeFX(fx, 0, 32);
LaraItem->hitPoints -= 50; LaraItem->hitPoints -= 50;
DoBloodSplat(fx->pos.xPos, fx->pos.yPos, fx->pos.zPos, (GetRandomControl() & 3) + 2, LaraItem->pos.yRot, LaraItem->roomNumber); DoBloodSplat(fx->pos.xPos, fx->pos.yPos, fx->pos.zPos, (GetRandomControl() & 3) + 2, LaraItem->pos.yRot, LaraItem->roomNumber);
SoundEffect(SFX_IMP_STONE_HIT, &fx->pos, 0); SoundEffect(SFX_TR5_IMP_STONE_HIT, &fx->pos, 0);
SoundEffect(SFX_LARA_INJURY_RND, &LaraItem->pos, 0); SoundEffect(SFX_TR4_LARA_INJURY, &LaraItem->pos, 0);
} }
KillEffect(itemNumber); KillEffect(itemNumber);

View file

@ -105,8 +105,8 @@ void InitialisePushableBlock(short itemNum)
pushable->height = height; pushable->height = height;
pushable->loopSound = SFX_PUSHABLE_SOUND; // LUA pushable->loopSound = SFX_TR4_PUSHABLE_SOUND; // LUA
pushable->stopSound = SFX_PUSH_BLOCK_END; // LUA pushable->stopSound = SFX_TR4_PUSH_BLOCK_END; // LUA
pushable->fallSound = SFX_TR4_BOULDER_FALL; // LUA pushable->fallSound = SFX_TR4_BOULDER_FALL; // LUA
item->data = (void*) pushable; item->data = (void*) pushable;

View file

@ -66,7 +66,7 @@ void ControlRaisingBlock(short itemNumber)
} }
else if (item->itemFlags[1] < 4096) else if (item->itemFlags[1] < 4096)
{ {
SoundEffect(SFX_BLK_PLAT_RAISE_LOW, &item->pos, 0); SoundEffect(SFX_TR4_BLK_PLAT_RAISE_AND_LOW, &item->pos, 0);
item->itemFlags[1] += 64; item->itemFlags[1] += 64;
@ -117,7 +117,7 @@ void ControlRaisingBlock(short itemNumber)
} }
else else
{ {
SoundEffect(SFX_BLK_PLAT_RAISE_LOW, &item->pos, 0); SoundEffect(SFX_TR4_BLK_PLAT_RAISE_AND_LOW, &item->pos, 0);
if (item->triggerFlags >= 0) if (item->triggerFlags >= 0)
{ {

View file

@ -184,8 +184,8 @@ void ControlTeleporter(short itemNumber)
} }
else if (item->itemFlags[0] == 70) else if (item->itemFlags[0] == 70)
{ {
SoundEffect(SFX_LIFT_HIT_FLOOR1, 0, 0); SoundEffect(SFX_TR5_LIFT_HIT_FLOOR1, 0, 0);
SoundEffect(SFX_LIFT_HIT_FLOOR2, 0, 0); SoundEffect(SFX_TR5_LIFT_HIT_FLOOR2, 0, 0);
} }
LaraItem->animNumber = LA_ELEVATOR_RECOVER; LaraItem->animNumber = LA_ELEVATOR_RECOVER;

View file

@ -92,7 +92,7 @@ void TwoBlocksPlatformControl(short itemNumber)
} }
else else
{ {
SoundEffect(SFX_2GUNTEX_FALL_BIG, &item->pos, 0); SoundEffect(SFX_TR4_RUMBLE_NEXTDOOR, &item->pos, 0);
item->pos.yPos -= 4; item->pos.yPos -= 4;
} }
} }
@ -105,7 +105,7 @@ void TwoBlocksPlatformControl(short itemNumber)
} }
else else
{ {
SoundEffect(SFX_2GUNTEX_FALL_BIG, &item->pos, 0); SoundEffect(SFX_TR4_RUMBLE_NEXTDOOR, &item->pos, 0);
item->pos.yPos += 4; item->pos.yPos += 4;
} }
} }

View file

@ -30,7 +30,7 @@ void SmashObject(short itemNumber)
if (box->flags & 0x8000) if (box->flags & 0x8000)
box->flags &= ~BOX_BLOCKED; box->flags &= ~BOX_BLOCKED;
SoundEffect(SFX_SMASH_GLASS, &item->pos, 0); SoundEffect(SFX_TR5_SMASH_GLASS, &item->pos, 0);
item->collidable = 0; item->collidable = 0;
item->meshBits = 0xFFFE; item->meshBits = 0xFFFE;

View file

@ -111,7 +111,7 @@ void RaisingCogControl(short itemNumber)
flags = item->itemFlags[2]; flags = item->itemFlags[2];
} }
SoundEffect(SFX_BLK_PLAT_RAISE_LOW, &item->pos, (flags * 256) | 8); SoundEffect(SFX_TR4_BLK_PLAT_RAISE_AND_LOW, &item->pos, (flags * 256) | 8);
item->itemFlags[2] += 2; item->itemFlags[2] += 2;
item->pos.yPos -= 2; item->pos.yPos -= 2;

View file

@ -121,9 +121,8 @@ void ControlDeathSlide(short itemNumber)
LaraItem->fallspeed = item->fallspeed / 4; LaraItem->fallspeed = item->fallspeed / 4;
} }
// TODO: sounds
// Stop // Stop
SoundEffect(SFX_COGS_ROME, &item->pos, 0); SoundEffect(SFX_TR4_VONCROY_KNIFE_SWISH, &item->pos, 0);
RemoveActiveItem(itemNumber); RemoveActiveItem(itemNumber);
item->status = ITEM_NOT_ACTIVE; item->status = ITEM_NOT_ACTIVE;
item->flags -= ONESHOT; item->flags -= ONESHOT;
@ -131,7 +130,7 @@ void ControlDeathSlide(short itemNumber)
else else
{ {
// Whizz // Whizz
SoundEffect(SFX_GOD_HEAD_LASER_LOOPS, &item->pos, 0); SoundEffect(SFX_TR4_TRAIN_DOOR_CLOSE, &item->pos, 0);
} }
} }
} }

View file

@ -71,8 +71,8 @@ void ExplosionControl(short itemNumber)
{ {
flag = item->itemFlags[1] == 1 ? 2 : 0; flag = item->itemFlags[1] == 1 ? 2 : 0;
} }
SoundEffect(SFX_EXPLOSION1, &item->pos, 25165828); SoundEffect(SFX_TR4_EXPLOSION1, &item->pos, 25165828);
SoundEffect(SFX_EXPLOSION2, &item->pos, 0); SoundEffect(SFX_TR4_EXPLOSION2, &item->pos, 0);
TriggerExplosionSparks(item->pos.xPos, item->pos.yPos, item->pos.zPos, 3, -2, flag, item->roomNumber); TriggerExplosionSparks(item->pos.xPos, item->pos.yPos, item->pos.zPos, 3, -2, flag, item->roomNumber);
for (i = 0; i < item->itemFlags[2]; ++i) for (i = 0; i < item->itemFlags[2]; ++i)
TriggerExplosionSparks(item->pos.xPos + (GetRandomControl() % 128 - 64) * item->itemFlags[2], item->pos.yPos + (GetRandomControl() % 128 - 64) * item->itemFlags[2], item->pos.zPos + (GetRandomControl() % 128 - 64) * item->itemFlags[2], 2, 0, i, item->roomNumber); TriggerExplosionSparks(item->pos.xPos + (GetRandomControl() % 128 - 64) * item->itemFlags[2], item->pos.yPos + (GetRandomControl() % 128 - 64) * item->itemFlags[2], item->pos.zPos + (GetRandomControl() % 128 - 64) * item->itemFlags[2], 2, 0, i, item->roomNumber);

View file

@ -144,7 +144,7 @@ void ControlTeethSpikes(short itemNumber)
else else
{ {
if (item->itemFlags[0] == 1024) if (item->itemFlags[0] == 1024)
SoundEffect(SFX_TEETH_SPIKES, &item->pos, 0); SoundEffect(SFX_TR4_TEETH_SPIKES, &item->pos, 0);
item->status = ITEM_ACTIVE; item->status = ITEM_ACTIVE;

View file

@ -3031,7 +3031,7 @@ namespace T5M::Renderer
if (StormTimer > -1) if (StormTimer > -1)
StormTimer--; StormTimer--;
if (!StormTimer) if (!StormTimer)
SoundEffect(SFX_THUNDER_RUMBLE, NULL, 0); SoundEffect(SFX_TR4_THUNDER_RUMBLE, NULL, 0);
} }
else if (!(rand() & 0x7F)) else if (!(rand() & 0x7F))
{ {

View file

@ -221,7 +221,7 @@ int S_UpdateInput()
LaraItem->currentAnimState == LS_CRAWL_BACK || LaraItem->currentAnimState == LS_CRAWL_BACK ||
LaraItem->currentAnimState == LS_CRAWL_TO_HANG) LaraItem->currentAnimState == LS_CRAWL_TO_HANG)
{ {
SoundEffect(SFX_LARA_NO, nullptr, 2); SoundEffect(SFX_TR4_LARA_NO, nullptr, 2);
flare_no = true; flare_no = true;
} }
else else
@ -329,12 +329,12 @@ int S_UpdateInput()
Lara.dpoisoned = 0; Lara.dpoisoned = 0;
LaraItem->hitPoints += 500; LaraItem->hitPoints += 500;
SoundEffect(SFX_MENU_MEDI, nullptr, 2);//Fix heal sound not triggering if small medi doesn't top off Lara's health. original tr4/5 issue SoundEffect(SFX_TR4_MENU_MEDI, nullptr, 2);//Fix heal sound not triggering if small medi doesn't top off Lara's health. original tr4/5 issue
if (LaraItem->hitPoints > 1000) if (LaraItem->hitPoints > 1000)
{ {
LaraItem->hitPoints = 1000; LaraItem->hitPoints = 1000;
SoundEffect(SFX_MENU_MEDI, nullptr, 2); SoundEffect(SFX_TR4_MENU_MEDI, nullptr, 2);
Savegame.Game.HealthUsed++; Savegame.Game.HealthUsed++;
} }
} }
@ -360,7 +360,7 @@ int S_UpdateInput()
if (LaraItem->hitPoints > 1000) if (LaraItem->hitPoints > 1000)
{ {
LaraItem->hitPoints = 1000; LaraItem->hitPoints = 1000;
SoundEffect(SFX_MENU_MEDI, nullptr, 2); SoundEffect(SFX_TR4_MENU_MEDI, nullptr, 2);
Savegame.Game.HealthUsed++; Savegame.Game.HealthUsed++;
} }
} }