Merge branch 'miami' of github.com:GTAmodding/re3 into miami

This commit is contained in:
aap 2020-06-01 18:05:24 +02:00
commit 25273485d9
25 changed files with 663 additions and 148 deletions

View file

@ -3123,7 +3123,7 @@ CCamera::Fade(float timeout, int16 direction)
void
CCamera::SetFadeColour(uint8 r, uint8 g, uint8 b)
{
m_FadeTargetIsSplashScreen = r == 0 && g == 0 && b == 0;
m_FadeTargetIsSplashScreen = r == 2 && g == 2 && b == 2;
CDraw::FadeRed = r;
CDraw::FadeGreen = g;
CDraw::FadeBlue = b;

View file

@ -15,6 +15,7 @@
#include "DamageManager.h"
#include "Ped.h"
#include "Fire.h"
#include "GameLogic.h"
CFireManager gFireManager;
@ -59,6 +60,12 @@ CFire::ProcessFire(void)
Extinguish();
return;
}
#if defined GTAVC_JP_PATCH && !defined FIX_BUGS
if (m_pEntity == CGameLogic::pShortCutTaxi && CGameLogic::ShortCutState == CGameLogic::SHORTCUT_TRANSITION) {
Extinguish();
return;
}
#endif
if (ped->m_nMoveState != PEDMOVE_RUN)
m_vecPos.z -= 1.0f;
if (ped->bInVehicle && ped->m_pMyVehicle) {
@ -84,6 +91,12 @@ CFire::ProcessFire(void)
Extinguish();
return;
}
#ifdef FIX_BUGS
if (m_pEntity == CGameLogic::pShortCutTaxi && CGameLogic::ShortCutState == CGameLogic::SHORTCUT_TRANSITION) {
Extinguish();
return;
}
#endif
if (!m_bIsScriptFire) {
fDamageVehicle = 1.2f * CTimer::GetTimeStep();
veh->InflictDamage((CVehicle *)m_pSource, WEAPONTYPE_FLAMETHROWER, fDamageVehicle);

View file

@ -523,6 +523,7 @@ void CGame::ShutDownForRestart(void)
CTheScripts::UndoBuildingSwaps();
CTheScripts::UndoEntityInvisibilitySettings();
CWorld::ClearForRestart();
CGameLogic::ClearShortCut();
CTimer::Shutdown();
CStreaming::FlushRequestList();
CStreaming::DeleteAllRwObjects();

View file

@ -10,6 +10,7 @@ enum {
PLAYERCONTROL_DISABLED_20 = 32, // used on CPlayerInfo::MakePlayerSafe
PLAYERCONTROL_DISABLED_40 = 64, // used on phone calls
PLAYERCONTROL_DISABLED_80 = 128,// used on cutscenes
PLAYERCONTROL_SHORTCUT_TAXI = 256,
};
class CControllerState
@ -150,10 +151,10 @@ public:
int16 Phase;
int16 Mode;
int16 ShakeDur;
uint16 DisablePlayerControls;
uint8 ShakeFreq;
bool bHornHistory[HORNHISTORY_SIZE];
uint8 iCurrHornHistory;
uint8 DisablePlayerControls;
int8 bApplyBrakes;
char CheatString[12];
int32 LastTimeTouched;
@ -449,9 +450,9 @@ public:
int16 GetRightStickY(void) { return NewState.RightStickY; }
bool ArePlayerControlsDisabled(void) { return DisablePlayerControls != PLAYERCONTROL_ENABLED; }
void SetDisablePlayerControls(uint8 who) { DisablePlayerControls |= who; }
void SetEnablePlayerControls(uint8 who) { DisablePlayerControls &= ~who; }
bool IsPlayerControlsDisabledBy(uint8 who) { return DisablePlayerControls & who; }
void SetDisablePlayerControls(uint16 who) { DisablePlayerControls |= who; }
void SetEnablePlayerControls(uint16 who) { DisablePlayerControls &= ~who; }
bool IsPlayerControlsDisabledBy(uint16 who) { return DisablePlayerControls & who; }
};
VALIDATE_SIZE(CPad, 0xFC);

View file

@ -146,6 +146,8 @@ CPlayerInfo::Clear(void)
m_bDriveByAllowed = true;
m_nPreviousTimeRewardedForExplosion = 0;
m_nExplosionsSinceLastReward = 0;
m_nCurrentBustedAudio = 1;
m_nBustedAudioStatus = BUSTEDAUDIO_NONE;
}
void

View file

@ -10,6 +10,13 @@ enum eWastedBustedState
WBSTATE_FAILED_CRITICAL_MISSION,
};
enum eBustedAudioState : uint8
{
BUSTEDAUDIO_NONE,
BUSTEDAUDIO_LOADING,
BUSTEDAUDIO_DONE
};
class CEntity;
class CPed;
class CVehicle;
@ -61,6 +68,8 @@ public:
bool m_bGetOutOfJailFree;
bool m_bGetOutOfHospitalFree;
bool m_bDriveByAllowed;
eBustedAudioState m_nBustedAudioStatus;
int16 m_nCurrentBustedAudio;
char m_aSkinName[32];
RwTexture *m_pSkinTexture;

View file

@ -1,6 +1,6 @@
#include "common.h"
#include "GameLogic.h"
#include "Hud.h"
#include "PlayerPed.h"
#include "Replay.h"
@ -99,7 +99,7 @@ void
CCurrentVehicle::Display()
{
wchar *text = nil;
if (m_pCurrentVehicle != nil)
if (m_pCurrentVehicle != nil && m_pCurrentVehicle != CGameLogic::pShortCutTaxi)
text = TheText.Get(((CVehicleModelInfo*)CModelInfo::GetModelInfo(m_pCurrentVehicle->GetModelIndex()))->m_gameName);
CHud::SetVehicleName(text);
}

View file

@ -115,6 +115,7 @@ enum Config {
NUMSHOTINFOS = 100,
NUMROADBLOCKS = 300,
NUM_SCRIPT_ROADBLOCKS = 16,
NUMVISIBLEENTITIES = 2000,
NUMINVISIBLEENTITIES = 150,
@ -136,7 +137,8 @@ enum Config {
NUM_EXPLOSIONS = 48,
NUM_SETPIECES = 96
NUM_SETPIECES = 96,
NUM_SHORTCUT_START_POINTS = 16
};
// We'll use this once we're ready to become independent of the game
@ -166,6 +168,7 @@ enum Config {
#elif defined GTA_PC
# define GTA3_1_1_PATCH
//# define GTA3_STEAM_PATCH
//# define GTAVC_JP_PATCH
# ifdef GTA_PS2_STUFF
# define USE_PS2_RAND
# define RANDOMSPLASH // use random splash as on PS2