Moved worldmap related code from main.cpp to the new Worldmap.cpp.

This commit is contained in:
NovaRain
2019-05-02 21:02:49 +08:00
parent 34628c0ea5
commit cbd3964ae5
9 changed files with 560 additions and 469 deletions
+1 -1
View File
@@ -710,7 +710,7 @@ SkipSizeCheck=0
;Does not require sfall debugging mode ;Does not require sfall debugging mode
;ExtraCRC=0x00000000,0x00000000 ;ExtraCRC=0x00000000,0x00000000
;Set to 1 to stop Fallout from deleting non readonly protos at startup ;Set to 1 to stop Fallout from deleting non read-only protos at startup
;Has pretty nasty side effects when saving/reloading, so don't use for regular gameplay ;Has pretty nasty side effects when saving/reloading, so don't use for regular gameplay
DontDeleteProtos=0 DontDeleteProtos=0
+1
View File
@@ -44,6 +44,7 @@
#include "SuperSave.h" #include "SuperSave.h"
#include "TalkingHeads.h" #include "TalkingHeads.h"
#include "version.h" #include "version.h"
#include "Worldmap.h"
#define MAX_GLOBAL_SIZE (MaxGlobalVars * 12 + 4) #define MAX_GLOBAL_SIZE (MaxGlobalVars * 12 + 4)
+1 -2
View File
@@ -21,7 +21,7 @@
#include "main.h" #include "main.h"
#include "Arrays.h" #include "Arrays.h"
#include "ScriptExtender.h" #include "ScriptExtender.h"
#include "Worldmap.h"
static DWORD EncounteredHorrigan; static DWORD EncounteredHorrigan;
static DWORD ForceEnconterMapID; static DWORD ForceEnconterMapID;
@@ -185,7 +185,6 @@ end:
} }
} }
void _stdcall SetMapMulti(float d);
static void __declspec(naked) set_map_time_multi() { static void __declspec(naked) set_map_time_multi() {
__asm { __asm {
push ebx; push ebx;
+520
View File
File diff suppressed because it is too large Load Diff
+26
View File
@@ -0,0 +1,26 @@
/*
* sfall
* Copyright (C) 2008-2019 The sfall team
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
void WorldmapInit();
DWORD GetAddedYears(bool isCheck = true);
void SetAddedYears(DWORD years);
void _stdcall SetMapMulti(float value);
+2
View File
@@ -327,6 +327,7 @@
<ClInclude Include="Logging.h" /> <ClInclude Include="Logging.h" />
<ClInclude Include="resource.h" /> <ClInclude Include="resource.h" />
<ClInclude Include="SuperSave.h" /> <ClInclude Include="SuperSave.h" />
<ClInclude Include="Worldmap.h" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="AI.cpp" /> <ClCompile Include="AI.cpp" />
@@ -380,6 +381,7 @@
<ClCompile Include="SpeedPatch.cpp" /> <ClCompile Include="SpeedPatch.cpp" />
<ClCompile Include="Logging.cpp" /> <ClCompile Include="Logging.cpp" />
<ClCompile Include="SuperSave.cpp" /> <ClCompile Include="SuperSave.cpp" />
<ClCompile Include="Worldmap.cpp" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<None Include="exports.def" /> <None Include="exports.def" />
+6
View File
@@ -196,6 +196,9 @@
<ClInclude Include="TalkingHeads.h"> <ClInclude Include="TalkingHeads.h">
<Filter>Headers</Filter> <Filter>Headers</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="Worldmap.h">
<Filter>Headers</Filter>
</ClInclude>
<ClInclude Include="Cpp11_emu.h"> <ClInclude Include="Cpp11_emu.h">
<Filter>Headers</Filter> <Filter>Headers</Filter>
</ClInclude> </ClInclude>
@@ -337,6 +340,9 @@
<ClCompile Include="TalkingHeads.cpp"> <ClCompile Include="TalkingHeads.cpp">
<Filter>Source</Filter> <Filter>Source</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="Worldmap.cpp">
<Filter>Source</Filter>
</ClCompile>
<ClCompile Include="stdafx.cpp"> <ClCompile Include="stdafx.cpp">
<Filter>Source</Filter> <Filter>Source</Filter>
</ClCompile> </ClCompile>
+3 -463
View File
File diff suppressed because it is too large Load Diff
-3
View File
@@ -70,9 +70,6 @@ extern DWORD modifiedIni;
extern char dmModelName[65]; extern char dmModelName[65];
extern char dfModelName[65]; extern char dfModelName[65];
DWORD GetAddedYears(bool isCheck = true);
void SetAddedYears(DWORD years);
void RemoveSavFiles(); void RemoveSavFiles();
void ClearSavPrototypes(); void ClearSavPrototypes();