1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-06 06:32:56 +01:00

Fix underflow in sub_68F41A()

This commit is contained in:
Gymnasiast
2017-07-26 14:51:43 +02:00
parent 603735f86d
commit 3f345c60c6
2 changed files with 2 additions and 2 deletions

View File

@@ -55,7 +55,7 @@ extern "C" {
// This define specifies which version of network stream current build uses.
// It is used for making sure only compatible builds get connected, even within
// single OpenRCT2 version.
#define NETWORK_STREAM_VERSION "7"
#define NETWORK_STREAM_VERSION "8"
#define NETWORK_STREAM_ID OPENRCT2_VERSION "-" NETWORK_STREAM_VERSION
#ifdef __cplusplus

View File

@@ -998,7 +998,7 @@ static void sub_68F41A(rct_peep *peep, sint32 index)
}
if (peep->time_on_ride > 15){
peep->happiness_growth_rate = min(0, peep->happiness_growth_rate - 5);
peep->happiness_growth_rate = max(0, peep->happiness_growth_rate - 5);
if (peep->time_on_ride > 22){
rct_ride* ride = get_ride(peep->current_ride);