mirror of
https://github.com/1dot13/source.git
synced 2026-09-09 14:46:05 +02:00
- bugfix: Now game always starts at Day 1
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@1075 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
+14
-2
@@ -32,6 +32,7 @@
|
|||||||
#include "meanwhile.h"
|
#include "meanwhile.h"
|
||||||
#include "strategicmap.h"
|
#include "strategicmap.h"
|
||||||
#include "Queen Command.h"
|
#include "Queen Command.h"
|
||||||
|
#include "Game Clock.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "Text.h"
|
#include "Text.h"
|
||||||
@@ -485,8 +486,19 @@ void LoadGameExternalOptions()
|
|||||||
gGameExternalOptions.iStartingCashInsane = iniReader.ReadInteger("JA2 Gameplay Settings", "INSANE_CASH",15000);
|
gGameExternalOptions.iStartingCashInsane = iniReader.ReadInteger("JA2 Gameplay Settings", "INSANE_CASH",15000);
|
||||||
|
|
||||||
//Lalien: Game starting time
|
//Lalien: Game starting time
|
||||||
gGameExternalOptions.iGameStartingTime = iniReader.ReadInteger("JA2 Gameplay Settings", "GAME_STARTING_TIME", 3600);
|
gGameExternalOptions.iGameStartingTime = iniReader.ReadInteger("JA2 Gameplay Settings", "GAME_STARTING_TIME", NUM_SEC_IN_HOUR);
|
||||||
gGameExternalOptions.iFirstArrivalDelay = iniReader.ReadInteger("JA2 Gameplay Settings", "FIRST_ARRIVAL_DELAY", 21600);
|
|
||||||
|
// WANNE: Check for invalid starting time
|
||||||
|
if (gGameExternalOptions.iGameStartingTime < 0 || gGameExternalOptions.iGameStartingTime >= NUM_SEC_IN_DAY)
|
||||||
|
{
|
||||||
|
gGameExternalOptions.iGameStartingTime = NUM_SEC_IN_HOUR + NUM_SEC_IN_DAY;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
gGameExternalOptions.iGameStartingTime += NUM_SEC_IN_DAY;
|
||||||
|
}
|
||||||
|
|
||||||
|
gGameExternalOptions.iFirstArrivalDelay = iniReader.ReadInteger("JA2 Gameplay Settings", "FIRST_ARRIVAL_DELAY", 6 * NUM_SEC_IN_HOUR);
|
||||||
|
|
||||||
//################# Settings valid on game start only end ##################
|
//################# Settings valid on game start only end ##################
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user