Skip to content

Commit df86690

Browse files
committed
3m30 to 3m18 compilation
1 parent d82375e commit df86690

16 files changed

+82
-15
lines changed

Source/Entities/ADoor.cpp

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,26 @@
55
#include "SLTerrain.h"
66
#include "PresetMan.h"
77
#include "SettingsMan.h"
8+
#include "SoundContainer.h"
89

910
#include "tracy/Tracy.hpp"
1011

1112
namespace RTE {
1213

1314
ConcreteClassInfo(ADoor, Actor, 20);
1415

16+
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
17+
18+
ADoor::ADoor() {
19+
Clear();
20+
}
21+
22+
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
23+
24+
ADoor::~ADoor() {
25+
Destroy(true);
26+
}
27+
1528
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
1629

1730
void ADoor::Clear() {
@@ -270,6 +283,32 @@ namespace RTE {
270283
return false;
271284
}
272285

286+
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
287+
288+
void ADoor::SetDoorMoveStartSound(SoundContainer *newSound) {
289+
m_DoorMoveStartSound.reset(newSound);
290+
}
291+
292+
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
293+
294+
void ADoor::SetDoorMoveSound(SoundContainer *newSound) {
295+
m_DoorMoveSound.reset(newSound);
296+
}
297+
298+
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
299+
300+
void ADoor::SetDoorDirectionChangeSound(SoundContainer *newSound)
301+
{
302+
m_DoorDirectionChangeSound.reset(newSound);
303+
}
304+
305+
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
306+
307+
void ADoor::SetDoorMoveEndSound(SoundContainer *newSound)
308+
{
309+
m_DoorMoveEndSound.reset(newSound);
310+
}
311+
273312
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
274313

275314
void ADoor::TempEraseOrRedrawDoorMaterial(bool erase) {

Source/Entities/ADoor.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ namespace RTE {
3232
/// <summary>
3333
/// Constructor method used to instantiate a ADoor object in system memory. Create() should be called before using the object.
3434
/// </summary>
35-
ADoor() { Clear(); }
35+
ADoor();
3636

3737
/// <summary>
3838
/// Makes the ADoor object ready for use.
@@ -52,7 +52,7 @@ namespace RTE {
5252
/// <summary>
5353
/// Destructor method used to clean up a ADoor object before deletion from system memory.
5454
/// </summary>
55-
~ADoor() override { Destroy(true); }
55+
~ADoor() override;
5656

5757
/// <summary>
5858
/// Destroys and resets (through Clear()) the ADoor object.
@@ -113,7 +113,7 @@ namespace RTE {
113113
/// Sets this ADoor's door move start sound. Ownership IS transferred!
114114
/// </summary>
115115
/// <param name="newSound">The new SoundContainer for this ADoor's door move start sound.</param>
116-
void SetDoorMoveStartSound(SoundContainer *newSound) { m_DoorMoveStartSound.reset(newSound); }
116+
void SetDoorMoveStartSound(SoundContainer *newSound);
117117

118118
/// <summary>
119119
/// Gets this ADoor's door move sound. Ownership is NOT transferred!
@@ -125,7 +125,7 @@ namespace RTE {
125125
/// Sets this ADoor's door move sound. Ownership IS transferred!
126126
/// </summary>
127127
/// <param name="newSound">The new SoundContainer for this ADoor's door move sound.</param>
128-
void SetDoorMoveSound(SoundContainer *newSound) { m_DoorMoveSound.reset(newSound); }
128+
void SetDoorMoveSound(SoundContainer *newSound);
129129

130130
/// <summary>
131131
/// Gets this ADoor's door direction change sound. Ownership is NOT transferred!
@@ -137,7 +137,7 @@ namespace RTE {
137137
/// Sets this ADoor's door direction change sound. Ownership IS transferred!
138138
/// </summary>
139139
/// <param name="newSound">The new SoundContainer for this ADoor's door direction change sound.</param>
140-
void SetDoorDirectionChangeSound(SoundContainer *newSound) { m_DoorDirectionChangeSound.reset(newSound); }
140+
void SetDoorDirectionChangeSound(SoundContainer *newSound);
141141

142142
/// <summary>
143143
/// Gets this ADoor's door move end sound. Ownership is NOT transferred!
@@ -149,7 +149,7 @@ namespace RTE {
149149
/// Sets this ADoor's door move end sound. Ownership IS transferred!
150150
/// </summary>
151151
/// <param name="newSound">The new SoundContainer for this ADoor's door move end sound.</param>
152-
void SetDoorMoveEndSound(SoundContainer *newSound) { m_DoorMoveEndSound.reset(newSound); }
152+
void SetDoorMoveEndSound(SoundContainer *newSound);
153153
#pragma endregion
154154

155155
#pragma region Concrete Methods

Source/Entities/AEmitter.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
#include "Atom.h"
1616
#include "Emission.h"
1717
#include "PresetMan.h"
18+
#include "SoundContainer.h"
19+
#include "PostProcessMan.h"
1820

1921
namespace RTE {
2022

Source/Entities/AHuman.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
#include "PresetMan.h"
2727
#include "Scene.h"
2828
#include "SettingsMan.h"
29+
#include "PostProcessMan.h"
2930

3031
#include "GUI.h"
3132
#include "AllegroBitmap.h"

Source/Entities/Actor.cpp

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
#include "SettingsMan.h"
3434
#include "FrameMan.h"
3535
#include "PerformanceMan.h"
36+
#include "PostProcessMan.h"
3637

3738
#include "GUI.h"
3839
#include "AllegroBitmap.h"
@@ -762,6 +763,21 @@ void Actor::AddAIMOWaypoint(const MovableObject *pMOWaypoint)
762763
m_Waypoints.push_back(std::pair<Vector, const MovableObject *>(pMOWaypoint->GetPos(), pMOWaypoint));
763764
}
764765

766+
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
767+
768+
void Actor::AlarmPoint(const Vector &alarmPoint)
769+
{
770+
if (m_AlarmSound && m_AlarmTimer.IsPastSimTimeLimit())
771+
{
772+
m_AlarmSound->Play(alarmPoint);
773+
}
774+
775+
if (m_AlarmTimer.GetElapsedSimTimeMS() > 50)
776+
{
777+
m_AlarmTimer.Reset();
778+
m_LastAlarmPos = m_PointingTarget = alarmPoint;
779+
}
780+
}
765781

766782
//////////////////////////////////////////////////////////////////////////////////////////
767783
// Method: SwapNextInventory

Source/Entities/Actor.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#include "MOSRotating.h"
1818
#include "PieMenu.h"
1919
#include "PathFinder.h"
20+
#include "SceneMan.h"
2021

2122
namespace RTE
2223
{
@@ -867,7 +868,7 @@ ClassInfoGetters;
867868
// is there.
868869
// Return value: None.
869870

870-
void AlarmPoint(const Vector &alarmPoint) { if (m_AlarmSound && m_AlarmTimer.IsPastSimTimeLimit()) { m_AlarmSound->Play(alarmPoint); } if (m_AlarmTimer.GetElapsedSimTimeMS() > 50) { m_AlarmTimer.Reset(); m_LastAlarmPos = m_PointingTarget = alarmPoint; } }
871+
void AlarmPoint(const Vector &alarmPoint);
871872

872873

873874
//////////////////////////////////////////////////////////////////////////////////////////

Source/Entities/HDFirearm.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#include "CameraMan.h"
1818
#include "FrameMan.h"
1919
#include "PresetMan.h"
20+
#include "PostProcessMan.h"
2021

2122
#include "Magazine.h"
2223
#include "ThrownDevice.h"

Source/Entities/MOSRotating.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
#include "AEmitter.h"
2424
#include "Attachable.h"
2525
#include "HDFirearm.h"
26+
#include "SoundContainer.h"
27+
#include "PostProcessMan.h"
2628

2729
#include "RTEError.h"
2830

Source/Entities/MOSRotating.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@
1616

1717
#include "MOSprite.h"
1818
#include "Gib.h"
19-
#include "PostProcessMan.h"
20-
#include "SoundContainer.h"
2119

2220
namespace RTE
2321
{
@@ -26,6 +24,7 @@ class AtomGroup;
2624
struct HitData;
2725
class AEmitter;
2826
class Attachable;
27+
struct SoundContainer;
2928

3029
//////////////////////////////////////////////////////////////////////////////////////////
3130
// Class: MOSRotating

Source/Entities/MOSprite.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515

1616
#include "AEmitter.h"
1717
#include "PresetMan.h"
18+
#include "SceneMan.h"
1819

1920
namespace RTE {
2021

0 commit comments

Comments
 (0)