Merge branch 'miami' into lcs

# Conflicts:
#	premake5.lua
This commit is contained in:
Sergeanur 2021-07-03 16:39:22 +03:00
commit 5d5e0f62e8
18 changed files with 152 additions and 103 deletions

View file

@ -34,7 +34,7 @@ jobs:
7z x ${{env.GLFW_FILE}}
- name: Configure build
run: |
./premake5 vs2019 --with-librw --glfwdir64=${{env.GLFW_BASE}}
./premake5 vs2019 --with-librw --no-full-paths --glfwdir64=${{env.GLFW_BASE}}
- name: Build
run: |
msbuild -m build/reLCS.sln /property:Configuration=${{matrix.buildtype}} /property:Platform=${{matrix.platform}}

View file

@ -34,7 +34,7 @@ jobs:
7z x ${{env.GLFW_FILE}}
- name: Configure build
run: |
./premake5 vs2019 --with-librw --glfwdir32=${{env.GLFW_BASE}}
./premake5 vs2019 --with-librw --no-full-paths --glfwdir32=${{env.GLFW_BASE}}
- name: Build
run: |
msbuild -m build/reLCS.sln /property:Configuration=${{matrix.buildtype}} /property:Platform=${{matrix.platform}}

View file

@ -27,14 +27,19 @@ newoption {
description = "Build with opus"
}
newoption {
trigger = "with-lto",
description = "Build with link time optimization"
}
newoption {
trigger = "no-git-hash",
description = "Don't print git commit hash into binary"
}
newoption {
trigger = "lto",
description = "Use link time optimization"
trigger = "no-full-paths",
description = "Don't print full paths into binary"
}
if(_OPTIONS["with-librw"]) then
@ -121,7 +126,7 @@ workspace "reLCS"
filter "configurations:not Debug"
defines { "NDEBUG" }
optimize "Speed"
if(_OPTIONS["lto"]) then
if(_OPTIONS["with-lto"]) then
flags { "LinkTimeOptimization" }
end
@ -338,6 +343,10 @@ project "reLCS"
linkoptions "/SAFESEH:NO"
characterset ("MBCS")
targetextension ".exe"
if(_OPTIONS["no-full-paths"]) then
usefullpaths "off"
linkoptions "/PDBALTPATH:%_PDB%"
end
if(_OPTIONS["with-librw"]) then
-- external librw is dynamic
staticruntime "on"

View file

@ -1078,7 +1078,7 @@ void
cAudioManager::AdjustSamplesVolume()
{
for (int i = 0; i < m_SampleRequestQueuesStatus[m_nActiveSampleQueue]; i++) {
tSound *pSample = &m_asSamples[m_nActiveSampleQueue][m_abSampleQueueIndexTable[m_nActiveSampleQueue][i] + 1];
tSound *pSample = &m_asSamples[m_nActiveSampleQueue][m_abSampleQueueIndexTable[m_nActiveSampleQueue][i]];
if (!pSample->m_bIs2D)
pSample->m_nEmittingVolume = ComputeEmittingVolume(pSample->m_nEmittingVolume, pSample->m_fSoundIntensity, pSample->m_fDistance);

View file

@ -292,7 +292,7 @@ CColStore::LoadCollision(const CVector &pos, eLevelName level)
}else{
for (int j = 0; j < MAX_CLEANUP; j++) {
CPhysical* pEntity = nil;
cleanup_entity_struct* pCleanup = &CTheScripts::MissionCleanUp.m_sEntities[i];
cleanup_entity_struct* pCleanup = &CTheScripts::MissionCleanUp.m_sEntities[j];
if (pCleanup->type == CLEANUP_CAR) {
pEntity = CPools::GetVehiclePool()->GetAt(pCleanup->id);
if (!pEntity || pEntity->GetStatus() == STATUS_WRECKED)

View file

@ -159,7 +159,7 @@ CGameLogic::Update()
#endif
CMessages::ClearMessages();
CCarCtrl::ClearInterestingVehicleList();
CWorld::ClearExcitingStuffFromArea(pPlayerInfo.GetPos(), 4000.0f, 1);
CWorld::ClearExcitingStuffFromArea(pPlayerInfo.GetPos(), 4000.0f, true);
CRestart::FindClosestHospitalRestartPoint(pPlayerInfo.GetPos(), &vecRestartPos, &fRestartFloat);
CRestart::OverrideHospitalLevel = LEVEL_GENERIC;
CRestart::OverridePoliceStationLevel = LEVEL_GENERIC;
@ -192,7 +192,7 @@ CGameLogic::Update()
}
if (!CTheScripts::IsPlayerOnAMission() && pPlayerInfo.m_nBustedAudioStatus == 0) {
if (!CTheScripts::IsPlayerOnAMission() && pPlayerInfo.m_nBustedAudioStatus == BUSTEDAUDIO_NONE) {
if (CGeneral::GetRandomNumberInRange(0, 4) == 0)
pPlayerInfo.m_nBustedAudioStatus = BUSTEDAUDIO_DONE;
else {
@ -268,7 +268,7 @@ CGameLogic::Update()
#endif
CMessages::ClearMessages();
CCarCtrl::ClearInterestingVehicleList();
CWorld::ClearExcitingStuffFromArea(pPlayerInfo.GetPos(), 4000.0f, 1);
CWorld::ClearExcitingStuffFromArea(pPlayerInfo.GetPos(), 4000.0f, true);
CRestart::FindClosestPoliceRestartPoint(pPlayerInfo.GetPos(), &vecRestartPos, &fRestartFloat);
CRestart::OverrideHospitalLevel = LEVEL_GENERIC;
CRestart::OverridePoliceStationLevel = LEVEL_GENERIC;
@ -323,7 +323,7 @@ CGameLogic::Update()
#endif
CMessages::ClearMessages();
CCarCtrl::ClearInterestingVehicleList();
CWorld::ClearExcitingStuffFromArea(pPlayerInfo.GetPos(), 4000.0f, 1);
CWorld::ClearExcitingStuffFromArea(pPlayerInfo.GetPos(), 4000.0f, true);
CRestart::FindClosestPoliceRestartPoint(pPlayerInfo.GetPos(), &vecRestartPos, &fRestartFloat);
CRestart::OverridePoliceStationLevel = LEVEL_GENERIC;
CRestart::OverrideHospitalLevel = LEVEL_GENERIC;
@ -380,10 +380,10 @@ CGameLogic::RestorePlayerStuffDuringResurrection(CPlayerPed *pPlayerPed, CVector
pPlayerPed->m_fRotationDest = pPlayerPed->m_fRotationCur;
pPlayerPed->SetHeading(pPlayerPed->m_fRotationCur);
CTheScripts::ClearSpaceForMissionEntity(pos, pPlayerPed);
CWorld::ClearExcitingStuffFromArea(pos, 4000.0, 1);
CWorld::ClearExcitingStuffFromArea(pos, 4000.0f, true);
pPlayerPed->RestoreHeadingRate();
CGame::currArea = AREA_MAIN_MAP;
CStreaming::RemoveBuildingsNotInArea(0);
CStreaming::RemoveBuildingsNotInArea(AREA_MAIN_MAP);
TheCamera.SetCameraDirectlyInFrontForFollowPed_CamOnAString();
TheCamera.Restore();
CReferences::RemoveReferencesToPlayer();
@ -490,7 +490,7 @@ CGameLogic::UpdateShortCut()
pShortCutTaxi->AutoPilot.m_nTempAction = TEMPACT_GOFORWARD;
pShortCutTaxi->AutoPilot.m_nTimeTempAction = CTimer::GetTimeInMilliseconds() + 2500;
TheCamera.SetFadeColour(0, 0, 0);
TheCamera.Fade(2.5f, 0);
TheCamera.Fade(2.5f, FADE_OUT);
ShortCutState = SHORTCUT_TRANSITION;
ShortCutTimer = CTimer::GetTimeInMilliseconds() + 3000;
CMessages::AddBigMessage(TheText.Get("TAXI"), 4500, 1);
@ -510,7 +510,7 @@ CGameLogic::UpdateShortCut()
pShortCutTaxi->SetMoveSpeed(pShortCutTaxi->GetForward() * 0.4f);
ShortCutTimer = CTimer::GetTimeInMilliseconds() + 1500;
TheCamera.SetFadeColour(0, 0, 0);
TheCamera.Fade(1.0f, 1);
TheCamera.Fade(1.0f, FADE_IN);
ShortCutState = SHORTCUT_ARRIVING;
CTimer::Resume();
}

View file

@ -9,14 +9,15 @@
#include "OnscreenTimer.h"
#include "Camera.h"
void COnscreenTimer::Init() {
void
COnscreenTimer::Init()
{
m_bDisabled = false;
for(uint32 i = 0; i < NUMONSCREENCOUNTERS; i++) {
m_sCounters[i].m_nCounterOffset = 0;
for(uint32 j = 0; j < ARRAY_SIZE(m_sCounters[0].m_aCounterText); j++) {
m_sCounters[i].m_aCounterText[j] = 0;
}
for(uint32 j = 0; j < ARRAY_SIZE(m_sCounters[0].m_aCounterText); j++)
m_sCounters[i].m_aCounterText[j] = '\0';
m_sCounters[i].m_nType = COUNTER_DISPLAY_NUMBER;
m_sCounters[i].m_bCounterProcessed = false;
@ -24,24 +25,25 @@ void COnscreenTimer::Init() {
for(uint32 i = 0; i < NUMONSCREENCLOCKS; i++) {
m_sClocks[i].m_nClockOffset = 0;
for(uint32 j = 0; j < ARRAY_SIZE(m_sClocks[0].m_aClockText); j++) {
m_sClocks[i].m_aClockText[j] = 0;
}
for(uint32 j = 0; j < ARRAY_SIZE(m_sClocks[0].m_aClockText); j++)
m_sClocks[i].m_aClockText[j] = '\0';
m_sClocks[i].m_bClockProcessed = false;
m_sClocks[i].m_bClockGoingDown = true;
}
}
void COnscreenTimer::Process() {
if(!CReplay::IsPlayingBack() && !m_bDisabled) {
for(uint32 i = 0; i < NUMONSCREENCLOCKS; i++) {
void
COnscreenTimer::Process()
{
if(!CReplay::IsPlayingBack() && !m_bDisabled)
for(uint32 i = 0; i < NUMONSCREENCLOCKS; i++)
m_sClocks[i].Process();
}
}
}
void COnscreenTimer::ProcessForDisplay() {
void
COnscreenTimer::ProcessForDisplay()
{
if(CHud::m_Wants_To_Draw_Hud) {
m_bProcessed = false;
for(uint32 i = 0; i < NUMONSCREENCLOCKS; i++) {
@ -63,67 +65,67 @@ void COnscreenTimer::ProcessForDisplay() {
}
}
void COnscreenTimer::ClearCounter(uint32 offset) {
void
COnscreenTimer::ClearCounter(uint32 offset)
{
for(uint32 i = 0; i < NUMONSCREENCOUNTERS; i++) {
if(offset == m_sCounters[i].m_nCounterOffset) {
m_sCounters[i].m_nCounterOffset = 0;
m_sCounters[i].m_aCounterText[0] = 0;
m_sCounters[i].m_aCounterText[0] = '\0';
m_sCounters[i].m_nType = COUNTER_DISPLAY_NUMBER;
m_sCounters[i].m_bCounterProcessed = 0;
m_sCounters[i].m_bCounterProcessed = false;
}
}
}
void COnscreenTimer::ClearClock(uint32 offset) {
for(uint32 i = 0; i < NUMONSCREENCLOCKS; i++) {
void
COnscreenTimer::ClearClock(uint32 offset)
{
for(uint32 i = 0; i < NUMONSCREENCLOCKS; i++)
if(offset == m_sClocks[i].m_nClockOffset) {
m_sClocks[i].m_nClockOffset = 0;
m_sClocks[i].m_aClockText[0] = 0;
m_sClocks[i].m_bClockProcessed = 0;
m_sClocks[i].m_aClockText[0] = '\0';
m_sClocks[i].m_bClockProcessed = false;
m_sClocks[i].m_bClockGoingDown = true;
}
}
}
void COnscreenTimer::AddCounter(uint32 offset, uint16 type, char* text, uint16 pos) {
void
COnscreenTimer::AddCounter(uint32 offset, uint16 type, char* text, uint16 pos)
{
if (m_sCounters[pos].m_aCounterText[0] != '\0')
return;
m_sCounters[pos].m_nCounterOffset = offset;
if(text) {
if(text)
strncpy(m_sCounters[pos].m_aCounterText, text, ARRAY_SIZE(m_sCounters[0].m_aCounterText));
} else {
m_sCounters[pos].m_aCounterText[0] = 0;
}
else
m_sCounters[pos].m_aCounterText[0] = '\0';
m_sCounters[pos].m_nType = type;
}
void COnscreenTimer::AddClock(uint32 offset, char* text, bool bGoingDown) {
// dead code in here
uint32 i;
for(i = 0; i < NUMONSCREENCLOCKS; i++) {
void
COnscreenTimer::AddClock(uint32 offset, char* text, bool bGoingDown)
{
for(uint32 i = 0; i < NUMONSCREENCLOCKS; i++) {
if(m_sClocks[i].m_nClockOffset == 0) {
m_sClocks[i].m_nClockOffset = offset;
m_sClocks[i].m_bClockGoingDown = bGoingDown;
if(text)
strncpy(m_sClocks[i].m_aClockText, text, ARRAY_SIZE(m_sClocks[0].m_aClockText));
else
m_sClocks[i].m_aClockText[0] = '\0';
break;
}
return;
}
m_sClocks[i].m_nClockOffset = offset;
m_sClocks[i].m_bClockGoingDown = bGoingDown;
if(text) {
strncpy(m_sClocks[i].m_aClockText, text, ARRAY_SIZE(m_sClocks[0].m_aClockText));
} else {
m_sClocks[i].m_aClockText[0] = 0;
}
}
void COnscreenTimerEntry::Process() {
if(m_nClockOffset == 0) {
void
COnscreenTimerEntry::Process()
{
if(m_nClockOffset == 0)
return;
}
int32* timerPtr = CTheScripts::GetPointerToScriptVariable(m_nClockOffset);
int32 oldTime = *timerPtr;
@ -147,13 +149,17 @@ void COnscreenTimerEntry::Process() {
*timerPtr = oldTime + int32(CTimer::GetTimeStepInMilliseconds());
}
void COnscreenTimerEntry::ProcessForDisplayClock() {
void
COnscreenTimerEntry::ProcessForDisplayClock()
{
uint32 time = *CTheScripts::GetPointerToScriptVariable(m_nClockOffset);
sprintf(m_aClockBuffer, "%02d:%02d", time / 1000 / 60 % 100,
time / 1000 % 60);
}
void COnscreenCounterEntry::ProcessForDisplayCounter() {
void
COnscreenCounterEntry::ProcessForDisplayCounter()
{
uint32 counter = *CTheScripts::GetPointerToScriptVariable(m_nCounterOffset);
sprintf(m_aCounterBuffer, "%d", counter);
}

View file

@ -28,7 +28,7 @@ class CCrimeBeingQd
{
public:
eCrimeType m_nType;
uint32 m_nId;
int32 m_nId;
uint32 m_nTime;
CVector m_vecPosn;
bool m_bReported;

View file

@ -26,6 +26,7 @@
#include "ModelInfo.h"
#include "Pad.h"
#include "ControllerConfig.h"
#include "DMAudio.h"
// Menu screens array is at the bottom of the file.
@ -194,6 +195,8 @@ void MultiSamplingButtonPress(int8 action) {
if (FrontEndMenuManager.m_nDisplayMSAALevel != FrontEndMenuManager.m_nPrefsMSAALevel) {
FrontEndMenuManager.m_nPrefsMSAALevel = FrontEndMenuManager.m_nDisplayMSAALevel;
_psSelectScreenVM(FrontEndMenuManager.m_nPrefsVideoMode);
DMAudio.ChangeMusicMode(MUSICMODE_FRONTEND);
DMAudio.Service();
FrontEndMenuManager.SetHelperText(0);
FrontEndMenuManager.SaveSettings();
}
@ -255,6 +258,8 @@ const char* screenModes[] = { "FED_FLS", "FED_WND" };
void ScreenModeAfterChange(int8 before, int8 after)
{
_psSelectScreenVM(FrontEndMenuManager.m_nPrefsVideoMode); // apply same resolution
DMAudio.ChangeMusicMode(MUSICMODE_FRONTEND);
DMAudio.Service();
FrontEndMenuManager.SetHelperText(0);
}

View file

@ -644,9 +644,6 @@ CCopPed::ProcessControl(void)
int numCopsNear = 0;
for (int i = 0; i < player->m_numNearPeds; ++i) {
CPed *nearPed = player->m_nearPeds[i];
#ifdef FIX_BUGS
if (nearPed)
#endif
if (nearPed->m_nPedType == PEDTYPE_COP && nearPed->m_nPedState != PED_DEAD)
++numCopsNear;
}

View file

@ -403,6 +403,30 @@ CPed::~CPed(void)
CPopulation::NumMiamiViceCops--;
CPopulation::UpdatePedCount((ePedType)m_nPedType, true);
DMAudio.DestroyEntity(m_audioEntityId);
// Because of the nature of ped lists in GTA, it can sometimes be outdated.
// Remove ourself from nearPeds list of the Peds in our nearPeds list.
#ifdef FIX_BUGS
for(int i = 0; i < m_numNearPeds; i++) {
CPed *nearPed = m_nearPeds[i];
assert(nearPed != nil);
if (!nearPed->IsPointerValid())
continue;
for(int j = 0; j < nearPed->m_numNearPeds;) {
assert(j == ARRAY_SIZE(m_nearPeds) - 1 || nearPed->m_nearPeds[j] || !nearPed->m_nearPeds[j+1]); // ensure nil comes after nil
if (nearPed->m_nearPeds[j] == this) {
for (int k = j; k < ARRAY_SIZE(m_nearPeds) - 1; k++) {
nearPed->m_nearPeds[k] = nearPed->m_nearPeds[k + 1];
nearPed->m_nearPeds[k + 1] = nil;
}
nearPed->m_numNearPeds--;
} else
j++;
}
}
#endif
}
void
@ -519,13 +543,15 @@ CPed::BuildPedLists(void)
removePed = true;
}
}
assert(i == ARRAY_SIZE(m_nearPeds) - 1 || m_nearPeds[i] || !m_nearPeds[i+1]); // ensure nil comes after nil
if (removePed) {
// If we arrive here, the ped we're checking isn't "near", so we should remove it.
for (int j = i; j < ARRAY_SIZE(m_nearPeds) - 1; j++) {
m_nearPeds[j] = m_nearPeds[j + 1];
m_nearPeds[j + 1] = nil;
}
// Above loop won't work on last slot, so we need to empty it.
m_nearPeds[ARRAY_SIZE(m_nearPeds) - 1] = nil;
m_numNearPeds--;
} else
@ -2861,7 +2887,7 @@ CPed::ProcessEntityCollision(CEntity *collidingEnt, CColPoint *collidingPoints)
CColModel *hisCol = CModelInfo::GetModelInfo(collidingEnt->GetModelIndex())->GetColModel();
if (!bUsesCollision && !bJustCheckCollision)
return false;
return 0;
if (collidingEnt->IsVehicle() && ((CVehicle*)collidingEnt)->IsBoat())
collidedWithBoat = true;
@ -6749,7 +6775,7 @@ CPed::FollowPath(void)
}
void
CPed::SetEvasiveStep(CEntity *reason, uint8 animType)
CPed::SetEvasiveStep(CPhysical *reason, uint8 animType)
{
AnimationId stepAnim;
@ -6767,22 +6793,23 @@ CPed::SetEvasiveStep(CEntity *reason, uint8 animType)
if (neededTurn > PI)
neededTurn = TWOPI - neededTurn;
CVehicle *veh = (CVehicle*)reason;
if (reason->IsVehicle() && veh->IsCar()) {
if (reason->IsVehicle() && ((CVehicle*)reason)->IsCar()) {
CVehicle *veh = (CVehicle*)reason;
if (veh->m_nCarHornTimer != 0) {
vehPressedHorn = true;
if (!IsPlayer())
animType = 1;
}
}
if (neededTurn <= DEGTORAD(90.0f) || veh->GetModelIndex() == MI_RCBANDIT || vehPressedHorn || animType != 0) {
SetLookFlag(veh, true);
if ((CGeneral::GetRandomNumber() & 1) && veh->GetModelIndex() != MI_RCBANDIT && animType == 0) {
if (neededTurn <= DEGTORAD(90.0f) || reason->GetModelIndex() == MI_RCBANDIT || vehPressedHorn || animType != 0) {
SetLookFlag(reason, true);
if ((CGeneral::GetRandomNumber() & 1) && reason->GetModelIndex() != MI_RCBANDIT && animType == 0) {
stepAnim = ANIM_STD_HAILTAXI;
} else {
float vehDirection = CGeneral::GetRadianAngleBetweenPoints(
veh->m_vecMoveSpeed.x, veh->m_vecMoveSpeed.y,
float dangerDirection = CGeneral::GetRadianAngleBetweenPoints(
reason->m_vecMoveSpeed.x, reason->m_vecMoveSpeed.y,
0.0f, 0.0f);
// Let's turn our back to the "reason"
@ -6792,14 +6819,14 @@ CPed::SetEvasiveStep(CEntity *reason, uint8 animType)
angleToFace -= TWOPI;
// We don't want to run towards car's direction
float dangerZone = angleToFace - vehDirection;
float dangerZone = angleToFace - dangerDirection;
dangerZone = CGeneral::LimitRadianAngle(dangerZone);
// So, add or subtract 90deg (jump to left/right) according to that
if (dangerZone > 0.0f)
angleToFace = vehDirection - HALFPI;
angleToFace = dangerDirection - HALFPI;
else
angleToFace = vehDirection + HALFPI;
angleToFace = dangerDirection + HALFPI;
stepAnim = ANIM_STD_NUM;
if (animType == 0 || animType == 1)

View file

@ -871,7 +871,7 @@ public:
void SetAimFlag(CEntity* to);
void SetAimFlag(float angle);
void SetAmmo(eWeaponType weaponType, uint32 ammo);
void SetEvasiveStep(CEntity*, uint8);
void SetEvasiveStep(CPhysical*, uint8);
void GrantAmmo(eWeaponType, uint32);
void SetEvasiveDive(CPhysical*, uint8);
void SetAttack(CEntity*);

View file

@ -17,9 +17,9 @@ const RwV3d XaxisIK = { 1.0f, 0.0f, 0.0f};
const RwV3d YaxisIK = { 0.0f, 1.0f, 0.0f};
const RwV3d ZaxisIK = { 0.0f, 0.0f, 1.0f};
CPedIK::CPedIK(CPed *ped)
CPedIK::CPedIK(CPed *ped) : m_ped(ped)
{
m_ped = ped;
assert(ped != nil);
m_flags = 0;
m_headOrient.yaw = 0.0f;
m_headOrient.pitch = 0.0f;

View file

@ -34,7 +34,7 @@ public:
AIMS_WITH_ARM = 4,
};
CPed *m_ped;
CPed *Const m_ped;
LimbOrientation m_headOrient;
LimbOrientation m_torsoOrient;
LimbOrientation m_upperArmOrient;

View file

@ -251,6 +251,11 @@ GenericSave(int file)
WriteSaveDataBlock(CStreaming::MemoryCardSave, "StreamingSize");
WriteSaveDataBlock(CPedType::Save, "PedTypeSize");
// sure just write garbage data repeatedly ...
#ifndef THIS_IS_STUPID
memset(work_buff, 0, sizeof(work_buff));
#endif
// Write padding
for (int i = 0; i < 4; i++) {
size = align4bytes(SIZE_OF_ONE_GAME_IN_BYTES - totalSize - 4);

View file

@ -83,29 +83,29 @@ WriteSaveBuf(uint8 *&buf, uint32 &length, const T &value)
#ifdef VALIDATE_SAVE_SIZE
#define CheckSaveHeader(buf, a, b, c, d, size) do { \
char _C; uint32 _size;\
ReadSaveBuf(&_C, buf);\
assert(_C == a);\
ReadSaveBuf(&_C, buf);\
assert(_C == b);\
ReadSaveBuf(&_C, buf);\
assert(_C == c);\
ReadSaveBuf(&_C, buf);\
assert(_C == d);\
char _c; uint32 _size;\
ReadSaveBuf(&_c, buf);\
assert(_c == a);\
ReadSaveBuf(&_c, buf);\
assert(_c == b);\
ReadSaveBuf(&_c, buf);\
assert(_c == c);\
ReadSaveBuf(&_c, buf);\
assert(_c == d);\
ReadSaveBuf(&_size, buf);\
assert(_size == size);\
} while(0)
#define CheckSaveHeaderWithLength(buf,len,a,b,c,d,size) do { \
char _C; uint32 _size;\
ReadSaveBuf(&_C, buf, len);\
assert(_C == a);\
ReadSaveBuf(&_C, buf, len);\
assert(_C == b);\
ReadSaveBuf(&_C, buf, len);\
assert(_C == c);\
ReadSaveBuf(&_C, buf, len);\
assert(_C == d);\
char _c; uint32 _size;\
ReadSaveBuf(&_c, buf, len);\
assert(_c == a);\
ReadSaveBuf(&_c, buf, len);\
assert(_c == b);\
ReadSaveBuf(&_c, buf, len);\
assert(_c == c);\
ReadSaveBuf(&_c, buf, len);\
assert(_c == d);\
ReadSaveBuf(&_size, buf, len);\
assert(_size == size);\
} while(0)

View file

@ -919,7 +919,7 @@ void _InputInitialiseJoys()
free(db);
fclose(f);
} else
printf("You don't seem to have copied " SDL_GAMEPAD_DB_PATH " file from re3/gamefiles to GTA3 directory. Some gamepads may not be recognized.\n");
printf("You don't seem to have copied " SDL_GAMEPAD_DB_PATH " file from reVC/gamefiles to GTA: Vice City directory. Some gamepads may not be recognized.\n");
#undef SDL_GAMEPAD_DB_PATH

View file

@ -1498,7 +1498,7 @@ psSelectDevice()
#ifdef DEFAULT_NATIVE_RESOLUTION
GcurSelVM = 1;
#else
MessageBox(nil, "Cannot find 640x480 video mode", "GTA3", MB_OK);
MessageBox(nil, "Cannot find 640x480 video mode", "GTA: Vice City", MB_OK);
return FALSE;
#endif
}
@ -1541,7 +1541,7 @@ psSelectDevice()
}
if(bestFsMode < 0){
MessageBox(nil, "Cannot find desired video mode", "GTA3", MB_OK);
MessageBox(nil, "Cannot find desired video mode", "GTA: Vice City", MB_OK);
return FALSE;
}
GcurSelVM = bestFsMode;