diff options
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/Game.h | 2 | ||||
-rw-r--r-- | src/core/Streaming.cpp | 93 | ||||
-rw-r--r-- | src/core/common.h | 1 | ||||
-rw-r--r-- | src/core/config.h | 2 | ||||
-rw-r--r-- | src/core/main.cpp | 4 | ||||
-rw-r--r-- | src/core/main.h | 4 |
6 files changed, 55 insertions, 51 deletions
diff --git a/src/core/Game.h b/src/core/Game.h index 69d71700..dd14278a 100644 --- a/src/core/Game.h +++ b/src/core/Game.h @@ -80,4 +80,4 @@ public: static void ProcessTidyUpMemory(void); }; -inline bool IsAreaVisible(int area) { return area == CGame::currArea || area == AREA_EVERYWHERE; } +inline bool IsAreaVisible(int area) { return true; } diff --git a/src/core/Streaming.cpp b/src/core/Streaming.cpp index 4fff2367..4198dd84 100644 --- a/src/core/Streaming.cpp +++ b/src/core/Streaming.cpp @@ -37,6 +37,7 @@ #include "Font.h" #include "Frontend.h" #include "VarConsole.h" +#include "KeyGen.h" //--MIAMI: file done (possibly bugs) @@ -948,53 +949,45 @@ CStreaming::RequestIslands(eLevelName level) } } -static char *IGnames[] = { - "player", - "player2", - "player3", - "player4", - "player5", - "player6", - "player7", - "player8", - "player9", - "play10", - "play11", - "igken", - "igcandy", - "igsonny", - "igbuddy", - "igjezz", - "ighlary", - "igphil", - "igmerc", - "igdick", - "igdiaz", +const char *csPlayerNames[] = +{ + "csplr", + "csplr2", + "csplr3", + "csplr4", + "csplr5", + "csplr6", + "csplr7", + "csplr8", + "csplr9", + "csplr10", + "csplr11", + "csplr12", + "csplr13", + "csplr14", + "csplr15", + "csplr16", "" }; -static char *CSnames[] = { - "csplay", - "csplay2", - "csplay3", - "csplay4", - "csplay5", - "csplay6", - "csplay7", - "csplay8", - "csplay9", - "csplay10", - "csplay11", - "csken", - "cscandy", - "cssonny", - "csbuddy", - "csjezz", - "cshlary", - "csphil", - "csmerc", - "csdick", - "csdiaz", +const char* playerNames[] = +{ + "plr", + "plr2", + "plr3", + "plr4", + "plr5", + "plr6", + "plr7", + "plr8", + "plr9", + "plr10", + "plr11", + "plr12", + "plr13", + "plr14", + "plr15", + "plr16", "" }; @@ -1008,15 +1001,17 @@ CStreaming::RequestSpecialModel(int32 modelId, const char *modelName, int32 flag int i, n; mi = CModelInfo::GetModelInfo(modelId); - if(strncasecmp("CSPlay", modelName, 6) == 0){ - char *curname = CModelInfo::GetModelInfo(MI_PLAYER)->GetModelName(); - for(int i = 0; CSnames[i][0]; i++){ - if(strcasecmp(curname, IGnames[i]) == 0){ - modelName = CSnames[i]; + if (CKeyGen::GetUppercaseKey(modelName) == CKeyGen::GetUppercaseKey("cstoni_a")) { + i = 0; + while (csPlayerNames[i][0] != '\0') { + if (CModelInfo::GetModelInfo(0)->GetNameHashKey() == CKeyGen::GetUppercaseKey(playerNames[i])) { + modelName = csPlayerNames[i]; break; } + i++; } } + if(!CGeneral::faststrcmp(mi->GetModelName(), modelName)){ // Already have the correct name, just request it RequestModel(modelId, flags); diff --git a/src/core/common.h b/src/core/common.h index 3e919ab6..ace15ee1 100644 --- a/src/core/common.h +++ b/src/core/common.h @@ -93,6 +93,7 @@ typedef ptrdiff_t ssize_t; #include "config.h" #include "memoryManager.h" +#include "relocatableChunk.h" #include <rphanim.h> #include <rpskin.h> diff --git a/src/core/config.h b/src/core/config.h index 711e119a..225863f3 100644 --- a/src/core/config.h +++ b/src/core/config.h @@ -371,7 +371,7 @@ static_assert(false, "SUPPORT_XBOX_SCRIPT and SUPPORT_MOBILE_SCRIPT are mutually // Audio #define AUDIO_CACHE // cache sound lengths to speed up the cold boot -//#define PS2_AUDIO_PATHS // changes audio paths for cutscenes and radio to PS2 paths (needs vbdec on MSS builds) +#define PS2_AUDIO_PATHS // changes audio paths for cutscenes and radio to PS2 paths (needs vbdec on MSS builds) //#define AUDIO_OAL_USE_SNDFILE // use libsndfile to decode WAVs instead of our internal decoder #define AUDIO_OAL_USE_MPG123 // use mpg123 to support mp3 files diff --git a/src/core/main.cpp b/src/core/main.cpp index 8685e42d..c516cd84 100644 --- a/src/core/main.cpp +++ b/src/core/main.cpp @@ -82,6 +82,10 @@ char gString2[512]; wchar gUString[256]; wchar gUString2[256]; +// leeds +bool gMakeResources = true; +bool gUseChunkFiles = false; + float FramesPerSecond = 30.0f; bool gbPrintShite = false; diff --git a/src/core/main.h b/src/core/main.h index 37a82fb2..19dd57ba 100644 --- a/src/core/main.h +++ b/src/core/main.h @@ -24,6 +24,10 @@ extern bool gbShowTimebars; extern bool gbPrintMemoryUsage; #endif +// leeds +extern bool gMakeResources; +extern bool gUseChunkFiles; + class CSprite2d; bool DoRWStuffStartOfFrame(int16 TopRed, int16 TopGreen, int16 TopBlue, int16 BottomRed, int16 BottomGreen, int16 BottomBlue, int16 Alpha); |