diff options
author | aap <aap@papnet.eu> | 2019-07-09 18:50:35 +0200 |
---|---|---|
committer | aap <aap@papnet.eu> | 2019-07-09 18:50:35 +0200 |
commit | a65dd41da736a12866526abc1405cbaa154771a8 (patch) | |
tree | 387f8103d69d373341e67a6373f681a454aa06db /src/core | |
parent | more CAutomobile (diff) | |
download | re3-a65dd41da736a12866526abc1405cbaa154771a8.tar re3-a65dd41da736a12866526abc1405cbaa154771a8.tar.gz re3-a65dd41da736a12866526abc1405cbaa154771a8.tar.bz2 re3-a65dd41da736a12866526abc1405cbaa154771a8.tar.lz re3-a65dd41da736a12866526abc1405cbaa154771a8.tar.xz re3-a65dd41da736a12866526abc1405cbaa154771a8.tar.zst re3-a65dd41da736a12866526abc1405cbaa154771a8.zip |
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/Camera.cpp | 1 | ||||
-rw-r--r-- | src/core/Camera.h | 2 | ||||
-rw-r--r-- | src/core/Explosion.cpp | 5 | ||||
-rw-r--r-- | src/core/Explosion.h | 15 | ||||
-rw-r--r-- | src/core/Fire.cpp | 6 | ||||
-rw-r--r-- | src/core/Fire.h | 21 | ||||
-rw-r--r-- | src/core/Wanted.cpp | 10 | ||||
-rw-r--r-- | src/core/Wanted.h | 1 |
8 files changed, 51 insertions, 10 deletions
diff --git a/src/core/Camera.cpp b/src/core/Camera.cpp index 832f9455..0f4503bb 100644 --- a/src/core/Camera.cpp +++ b/src/core/Camera.cpp @@ -18,6 +18,7 @@ const float DefaultFOV = 70.0f; // beta: 80.0f CCamera &TheCamera = *(CCamera*)0x6FACF8; bool &CCamera::m_bUseMouse3rdPerson = *(bool *)0x5F03D8; +WRAPPER void CCamera::CamShake(float strength, float x, float y, float z) { EAXJMP(0x46B200); } WRAPPER void CCamera::DrawBordersForWideScreen(void) { EAXJMP(0x46B430); } WRAPPER void CCamera::CalculateDerivedValues(void) { EAXJMP(0x46EEA0); } WRAPPER void CCamera::Restore(void) { EAXJMP(0x46F990); } diff --git a/src/core/Camera.h b/src/core/Camera.h index db5fff46..f00a213e 100644 --- a/src/core/Camera.h +++ b/src/core/Camera.h @@ -454,6 +454,8 @@ int m_iModeObbeCamIsInForCar; void ProcessMusicFade(void); void SetFadeColour(uint8 r, uint8 g, uint8 b); + void CamShake(float strength, float x, float y, float z); + void SetMotionBlur(int r, int g, int b, int a, int type); void SetMotionBlurAlpha(int a); void RenderMotionBlur(void); diff --git a/src/core/Explosion.cpp b/src/core/Explosion.cpp new file mode 100644 index 00000000..f55cbcd6 --- /dev/null +++ b/src/core/Explosion.cpp @@ -0,0 +1,5 @@ +#include "common.h" +#include "patcher.h" +#include "Explosion.h" + +WRAPPER void CExplosion::AddExplosion(CEntity *explodingEntity, CEntity *culprit, eExplosionType type, const CVector &pos, uint32) { EAXJMP(0x5591C0); } diff --git a/src/core/Explosion.h b/src/core/Explosion.h new file mode 100644 index 00000000..69508490 --- /dev/null +++ b/src/core/Explosion.h @@ -0,0 +1,15 @@ +#pragma once + +class CEntity; + +enum eExplosionType +{ + EXPLOSION_3 = 3, + EXPLOSION_4 +}; + +class CExplosion +{ +public: + static void AddExplosion(CEntity *explodingEntity, CEntity *culprit, eExplosionType type, const CVector &pos, uint32); +}; diff --git a/src/core/Fire.cpp b/src/core/Fire.cpp index 05d72199..bc59de2f 100644 --- a/src/core/Fire.cpp +++ b/src/core/Fire.cpp @@ -2,4 +2,8 @@ #include "patcher.h" #include "Fire.h" -WRAPPER void CFire::Extinguish(void) { EAXJMP(0x479D40); }
\ No newline at end of file +CFireManager &gFireManager = *(CFireManager*)0x8F31D0; + +WRAPPER void CFire::Extinguish(void) { EAXJMP(0x479D40); } + +WRAPPER void CFireManager::StartFire(CEntity *entityOnFire, CEntity *culprit, float, uint32) { EAXJMP(0x479590); } diff --git a/src/core/Fire.h b/src/core/Fire.h index c7f83fd8..9c9e1dec 100644 --- a/src/core/Fire.h +++ b/src/core/Fire.h @@ -1,13 +1,13 @@ #pragma once -#include "common.h" -#include "Entity.h" + +class CEntity; class CFire { - char m_bIsOngoing; - char m_bExists; - char m_bPropogationFlag; - char m_bAudioSet; + bool m_bIsOngoing; + bool m_bExists; + bool m_bPropogationFlag; + bool m_bAudioSet; CVector m_vecPos; CEntity *m_pEntity; CEntity *m_pSource; @@ -20,4 +20,11 @@ class CFire public: void Extinguish(void); -};
\ No newline at end of file +}; + +class CFireManager +{ +public: + void StartFire(CEntity *entityOnFire, CEntity *culprit, float, uint32); +}; +extern CFireManager &gFireManager; diff --git a/src/core/Wanted.cpp b/src/core/Wanted.cpp index 21853308..4608bfef 100644 --- a/src/core/Wanted.cpp +++ b/src/core/Wanted.cpp @@ -34,7 +34,7 @@ int CWanted::NumOfHelisRequired() return 2; default: return 0; - }; + } } void CWanted::SetWantedLevel(int32 level) @@ -70,11 +70,17 @@ void CWanted::SetWantedLevel(int32 level) UpdateWantedLevel(); } +void CWanted::SetWantedLevelNoDrop(int32 level) +{ + if (level > m_nWantedLevel) + SetWantedLevel(level); +} + void CWanted::ClearQdCrimes() { for (int i = 0; i < 16; i++) { m_sCrimes[i].m_eCrimeType = CRIME_NONE; - }; + } } void CWanted::UpdateWantedLevel() diff --git a/src/core/Wanted.h b/src/core/Wanted.h index d14bb905..d3f6638b 100644 --- a/src/core/Wanted.h +++ b/src/core/Wanted.h @@ -42,6 +42,7 @@ public: bool AreArmyRequired(); int NumOfHelisRequired(); void SetWantedLevel(int32); + void SetWantedLevelNoDrop(int32 level); void ClearQdCrimes(); void UpdateWantedLevel(); }; |