1
0
Fork 0
mirror of https://git.rip/DMCA_FUCKER/re3.git synced 2024-12-25 02:30:01 +00:00

return bridge, crane and fix structures in fluff.h

This commit is contained in:
Roman Masanin 2020-09-26 21:07:51 +03:00
parent 356c50ec1e
commit 4c220b1f95
2 changed files with 22 additions and 5 deletions

View file

@ -366,12 +366,26 @@ cAudioManager::ProcessEntity(int32 id)
ProcessWeather(id); ProcessWeather(id);
} }
break; break;
/* case AUDIOTYPE_CRANE:
if (!m_nUserPause) {
m_sQueueSample.m_bReverbFlag = true;
ProcessCrane();
}
break;*/
case AUDIOTYPE_SCRIPTOBJECT: case AUDIOTYPE_SCRIPTOBJECT:
if (!m_nUserPause) { if (!m_nUserPause) {
m_sQueueSample.m_bReverbFlag = true; m_sQueueSample.m_bReverbFlag = true;
ProcessScriptObject(id); ProcessScriptObject(id);
} }
break; break;
#ifdef GTA_BRIDGE
case AUDIOTYPE_BRIDGE:
if (!m_nUserPause) {
m_sQueueSample.m_bReverbFlag = true;
ProcessBridge();
}
break;
#endif
case AUDIOTYPE_FRONTEND: case AUDIOTYPE_FRONTEND:
m_sQueueSample.m_bReverbFlag = false; m_sQueueSample.m_bReverbFlag = false;
ProcessFrontEnd(); ProcessFrontEnd();
@ -4973,9 +4987,9 @@ cAudioManager::ProcessEscalators()
float distance; float distance;
for (int i = 0; i < CEscalators::NumEscalators; i++) { for (int i = 0; i < CEscalators::NumEscalators; i++) {
if (!CEscalators::aEscalators[i].m_bIsActive) if (!CEscalators::GetEscalator(i).IsActive())
continue; continue;
m_sQueueSample.m_vecPos = CEscalators::aEscalators[i].m_midPoint; m_sQueueSample.m_vecPos = CEscalators::GetEscalator(i).GetPosition();
distance = GetDistanceSquared(m_sQueueSample.m_vecPos); distance = GetDistanceSquared(m_sQueueSample.m_vecPos);
if (distance < SQR(SOUND_INTENSITY)) { if (distance < SQR(SOUND_INTENSITY)) {
if (distance > 0.0f) if (distance > 0.0f)

View file

@ -90,30 +90,33 @@ class CEscalator
CVector m_pos2; CVector m_pos2;
CVector m_pos3; CVector m_pos3;
CMatrix m_matrix; CMatrix m_matrix;
bool m_bIsActive;
bool m_bIsMovingDown; bool m_bIsMovingDown;
int32 m_stepsCount; int32 m_stepsCount;
float m_lowerEnd; float m_lowerEnd;
float m_upperEnd; float m_upperEnd;
CVector m_midPoint;
float m_radius; float m_radius;
CObject *m_pSteps[24]; CObject *m_pSteps[24];
public: public:
bool m_bIsActive;//TODO also recheck!
CVector m_midPoint;
CEscalator(); CEscalator();
void Update(void); void Update(void);
void SwitchOff(void); void SwitchOff(void);
void AddThisOne(CVector pos0, CVector pos1, CVector pos2, CVector pos3, bool b_isMovingDown); void AddThisOne(CVector pos0, CVector pos1, CVector pos2, CVector pos3, bool b_isMovingDown);
bool IsActive() { return m_bIsActive; };
CVector GetPosition() { return m_midPoint; };
}; };
class CEscalators class CEscalators
{ {
static CEscalator aEscalators[NUM_ESCALATORS];
public: public:
static CEscalator aEscalators[NUM_ESCALATORS];//TODO need recheck this!
static int32 NumEscalators; static int32 NumEscalators;
static void Init(void); static void Init(void);
static void Update(void); static void Update(void);
static void AddOne(CVector pos0, CVector pos1, CVector pos2, CVector pos3, bool b_isMovingDown); static void AddOne(CVector pos0, CVector pos1, CVector pos2, CVector pos3, bool b_isMovingDown);
static void Shutdown(void); static void Shutdown(void);
static CEscalator GetEscalator(int ind) { return aEscalators[ind]; };
}; };
class CMovingThing class CMovingThing