summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authoreray orçunus <erayorcunus@gmail.com>2019-07-18 04:28:06 +0200
committereray orçunus <erayorcunus@gmail.com>2019-07-18 04:28:06 +0200
commit993944c05c9f204a2caf61b973d68b7f7a1c56ab (patch)
tree998813788845b3a334f2f04612136b390a1e872c /src/core
parentThe Peds, mainly dying/injuring (diff)
parentmore CAutomobile::ProcessControl (diff)
downloadre3-993944c05c9f204a2caf61b973d68b7f7a1c56ab.tar
re3-993944c05c9f204a2caf61b973d68b7f7a1c56ab.tar.gz
re3-993944c05c9f204a2caf61b973d68b7f7a1c56ab.tar.bz2
re3-993944c05c9f204a2caf61b973d68b7f7a1c56ab.tar.lz
re3-993944c05c9f204a2caf61b973d68b7f7a1c56ab.tar.xz
re3-993944c05c9f204a2caf61b973d68b7f7a1c56ab.tar.zst
re3-993944c05c9f204a2caf61b973d68b7f7a1c56ab.zip
Diffstat (limited to 'src/core')
-rw-r--r--src/core/Clock.cpp7
-rw-r--r--src/core/Clock.h2
-rw-r--r--src/core/Pad.h3
-rw-r--r--src/core/Stats.cpp1
-rw-r--r--src/core/Stats.h1
-rw-r--r--src/core/Streaming.cpp2
6 files changed, 7 insertions, 9 deletions
diff --git a/src/core/Clock.cpp b/src/core/Clock.cpp
index 707b0e57..a97dcb5f 100644
--- a/src/core/Clock.cpp
+++ b/src/core/Clock.cpp
@@ -15,7 +15,7 @@ uint8 &CClock::ms_Stored_nGameClockHours = *(uint8*)0x95CD7B;
uint8 &CClock::ms_Stored_nGameClockMinutes = *(uint8*)0x95CD9B;
uint16 &CClock::ms_Stored_nGameClockSeconds = *(uint16*)0x95CC9C;
uint32 &CClock::ms_nMillisecondsPerGameMinute = *(uint32*)0x8F2C64;
-int32 &CClock::ms_nLastClockTick = *(int32*)0x9430E4;
+uint32 &CClock::ms_nLastClockTick = *(uint32*)0x9430E4;
bool &CClock::ms_bClockHasBeenStored = *(bool*)0x95CD82;
void
@@ -67,10 +67,7 @@ CClock::Update(void)
}
}
}
- ms_nGameClockSeconds +=
- 60
- * (CTimer::GetTimeInMilliseconds() - ms_nLastClockTick)
- / ms_nMillisecondsPerGameMinute;
+ ms_nGameClockSeconds = 60 * (CTimer::GetTimeInMilliseconds() - ms_nLastClockTick) / ms_nMillisecondsPerGameMinute;
}
void
diff --git a/src/core/Clock.h b/src/core/Clock.h
index e11b2293..ea4263bd 100644
--- a/src/core/Clock.h
+++ b/src/core/Clock.h
@@ -9,7 +9,7 @@ class CClock
static uint8 &ms_Stored_nGameClockMinutes;
static uint16 &ms_Stored_nGameClockSeconds;
static uint32 &ms_nMillisecondsPerGameMinute;
- static int32 &ms_nLastClockTick;
+ static uint32 &ms_nLastClockTick;
static bool &ms_bClockHasBeenStored;
public:
diff --git a/src/core/Pad.h b/src/core/Pad.h
index f853a8cd..f84ca742 100644
--- a/src/core/Pad.h
+++ b/src/core/Pad.h
@@ -197,7 +197,7 @@ public:
int16 Mode;
int16 ShakeDur;
uint8 ShakeFreq;
- int8 bHornHistory[5];
+ bool bHornHistory[5];
uint8 iCurrHornHistory;
uint8 DisablePlayerControls;
int8 bApplyBrakes;
@@ -377,6 +377,7 @@ public:
bool ArePlayerControlsDisabled(void) { return DisablePlayerControls != PLAYERCONTROL_ENABLED; }
};
VALIDATE_SIZE(CPad, 0xFC);
+extern CPad *Pads; //[2]
#define IsButtonJustDown(pad, btn) \
(!(pad)->OldState.btn && (pad)->NewState.btn)
diff --git a/src/core/Stats.cpp b/src/core/Stats.cpp
index 921586bb..01bbf82e 100644
--- a/src/core/Stats.cpp
+++ b/src/core/Stats.cpp
@@ -4,6 +4,7 @@
int32 &CStats::DaysPassed = *(int32*)0x8F2BB8;
int32 &CStats::HeadShots = *(int32*)0x8F647C;
bool& CStats::CommercialPassed = *(bool*)0x8F4334;
+bool& CStats::IndustrialPassed = *(bool*)0x8E2A68;
int32 &CStats::NumberKillFrenziesPassed = *(int32*)0x8E287C;
int32 &CStats::PeopleKilledByOthers = *(int32*)0x8E2C50;
diff --git a/src/core/Stats.h b/src/core/Stats.h
index 30058a59..c536465f 100644
--- a/src/core/Stats.h
+++ b/src/core/Stats.h
@@ -6,6 +6,7 @@ public:
static int32 &DaysPassed;
static int32 &HeadShots;
static bool& CommercialPassed;
+ static bool& IndustrialPassed;
static int32 &NumberKillFrenziesPassed;
static int32 &PeopleKilledByOthers;
diff --git a/src/core/Streaming.cpp b/src/core/Streaming.cpp
index a23e35be..9d9241e4 100644
--- a/src/core/Streaming.cpp
+++ b/src/core/Streaming.cpp
@@ -1048,8 +1048,6 @@ CStreaming::RemoveReferencedTxds(int32 mem)
return false;
}
-// TODO: RemoveCurrentZonesModels
-
void
CStreaming::RemoveUnusedModelsInLoadedList(void)
{