summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
Diffstat (limited to 'src/core')
-rw-r--r--src/core/ColStore.cpp1
-rw-r--r--src/core/Collision.cpp12
-rw-r--r--src/core/Collision.h3
-rw-r--r--src/core/Frontend.cpp165
-rw-r--r--src/core/Frontend.h47
-rw-r--r--src/core/Game.cpp4
-rw-r--r--src/core/MenuScreens.cpp66
-rw-r--r--src/core/Pad.cpp4
-rw-r--r--src/core/Pools.cpp24
-rw-r--r--src/core/Pools.h3
-rw-r--r--src/core/SurfaceTable.cpp8
-rw-r--r--src/core/SurfaceTable.h1
-rw-r--r--src/core/config.h21
-rw-r--r--src/core/main.cpp6
-rw-r--r--src/core/main.h3
-rw-r--r--src/core/re3.cpp107
-rw-r--r--src/core/templates.h4
17 files changed, 177 insertions, 302 deletions
diff --git a/src/core/ColStore.cpp b/src/core/ColStore.cpp
index 070967e5..bca1e9b7 100644
--- a/src/core/ColStore.cpp
+++ b/src/core/ColStore.cpp
@@ -223,7 +223,6 @@ CColStore::EnsureCollisionIsInMemory(const CVector2D &pos)
}
}
-//--MIAMI: done
bool
CColStore::HasCollisionLoaded(const CVector2D &pos)
{
diff --git a/src/core/Collision.cpp b/src/core/Collision.cpp
index c2037dc5..91e7bba7 100644
--- a/src/core/Collision.cpp
+++ b/src/core/Collision.cpp
@@ -3049,6 +3049,18 @@ CColModel::GetTrianglePoint(CVector &v, int i) const
v = vertices[i].Get();
}
+void*
+CColModel::operator new(size_t){
+ CColModel *node = CPools::GetColModelPool()->New();
+ assert(node);
+ return node;
+}
+
+void
+CColModel::operator delete(void *p, size_t){
+ CPools::GetColModelPool()->Delete((CColModel*)p);
+}
+
CColModel&
CColModel::operator=(const CColModel &other)
{
diff --git a/src/core/Collision.h b/src/core/Collision.h
index fd079028..93959a72 100644
--- a/src/core/Collision.h
+++ b/src/core/Collision.h
@@ -181,7 +181,6 @@ struct CStoredCollPoly
bool valid;
};
-//--MIAMI: done struct
struct CColModel
{
CSphere boundingSphere;
@@ -208,6 +207,8 @@ struct CColModel
void SetLinkPtr(CLink<CColModel*>*);
void GetTrianglePoint(CVector &v, int i) const;
+ void *operator new(size_t);
+ void operator delete(void *p, size_t);
CColModel& operator=(const CColModel& other);
};
diff --git a/src/core/Frontend.cpp b/src/core/Frontend.cpp
index 0be9daf0..b76acf40 100644
--- a/src/core/Frontend.cpp
+++ b/src/core/Frontend.cpp
@@ -290,7 +290,7 @@ CMenuManager::ThingsToDoBeforeLeavingPage()
DMAudio.StopFrontEndTrack();
OutputDebugString("FRONTEND AUDIO TRACK STOPPED");
#endif
- } else if (m_nCurrScreen == MENUPAGE_GRAPHICS_SETTINGS) {
+ } else if (m_nCurrScreen == MENUPAGE_DISPLAY_SETTINGS) {
m_nDisplayVideoMode = m_nPrefsVideoMode;
#ifdef IMPROVED_VIDEOMODE
m_nSelectedScreenMode = m_nPrefsWindowed;
@@ -300,48 +300,13 @@ CMenuManager::ThingsToDoBeforeLeavingPage()
if (m_nCurrScreen == MENUPAGE_SKIN_SELECT) {
CPlayerSkin::EndFrontendSkinEdit();
}
-
-#ifdef CUSTOM_FRONTEND_OPTIONS
- for (int i = 0; i < numCustomFrontendOptions; i++) {
- FrontendOption& option = customFrontendOptions[i];
- if (option.type != FEOPTION_REDIRECT && option.type != FEOPTION_GOBACK && m_nCurrScreen == option.screen) {
- if (option.returnPrevPageFunc)
- option.returnPrevPageFunc();
-
- if (m_nCurrOption == option.screenOptionOrder && option.type == FEOPTION_DYNAMIC)
- option.buttonPressFunc(FEOPTION_ACTION_FOCUSLOSS);
-
- if (option.onlyApplyOnEnter)
- option.displayedValue = *option.value;
- }
- }
-#endif
}
int8
CMenuManager::GetPreviousPageOption()
{
-#ifndef CUSTOM_FRONTEND_OPTIONS
return (!m_bGameNotLoaded ? aScreens[m_nCurrScreen].m_ParentEntry :
(m_nCurrScreen == MENUPAGE_NEW_GAME ? 0 : (m_nCurrScreen == MENUPAGE_OPTIONS ? 1 : (m_nCurrScreen == MENUPAGE_EXIT ? 2 : aScreens[m_nCurrScreen].m_ParentEntry))));
-#else
- int8 prevPage = aScreens[m_nCurrScreen].m_PreviousPage;
-
- if (prevPage == -1) // Game also does same
- return 0;
-
- prevPage = prevPage == MENUPAGE_NONE ? (!m_bGameNotLoaded ? MENUPAGE_PAUSE_MENU : MENUPAGE_START_MENU) : prevPage;
-
- for (int i = 0; i < NUM_MENUROWS; i++) {
- if (aScreens[prevPage].m_aEntries[i].m_TargetMenu == m_nCurrScreen) {
- return i;
- }
- }
-
- // Couldn't find current screen option on previous page, use default behaviour (maybe save-related screen?)
- return (!m_bGameNotLoaded ? aScreens[m_nCurrScreen].m_ParentEntry :
- (m_nCurrScreen == MENUPAGE_NEW_GAME ? 0 : (m_nCurrScreen == MENUPAGE_OPTIONS ? 1 : (m_nCurrScreen == MENUPAGE_EXIT ? 2 : aScreens[m_nCurrScreen].m_ParentEntry))));
-#endif
}
// ------ Functions not in the game/inlined ends
@@ -1139,7 +1104,7 @@ CMenuManager::DrawStandardMenus(bool drawCurrScreen)
}
break;
#ifdef IMPROVED_VIDEOMODE
- case MENUACTION_SCREENMODE:
+ case MENUACTION_SCREENFORMAT:
if (m_nSelectedScreenMode == 0)
sprintf(asciiTemp, "FULLSCREEN");
else
@@ -1210,32 +1175,6 @@ CMenuManager::DrawStandardMenus(bool drawCurrScreen)
rightText = TheText.Get("FEA_NM3");
}
break;
-#ifdef CUSTOM_FRONTEND_OPTIONS
- case MENUACTION_TRIGGERFUNC:
- FrontendOption& option = customFrontendOptions[aScreens[m_nCurrScreen].m_aEntries[i].m_TargetMenu];
- if (m_nCurrScreen == option.screen && i == option.screenOptionOrder) {
- leftText = (wchar*)option.leftText;
- if (option.type == FEOPTION_SELECT) {
- if (option.displayedValue >= option.numRightTexts || option.displayedValue < 0)
- option.displayedValue = 0;
-
- rightText = (wchar*)option.rightTexts[option.displayedValue];
-
- } else if (option.type == FEOPTION_DYNAMIC) {
- if (option.drawFunc) {
- bool isOptionDisabled = false;
- rightText = option.drawFunc(&isOptionDisabled);
- if (isOptionDisabled)
- CFont::SetColor(CRGBA(DARKMENUOPTION_COLOR.r, DARKMENUOPTION_COLOR.g, DARKMENUOPTION_COLOR.b, FadeIn(255)));
- }
- }
- } else {
- debug("A- screen:%d option:%d - totalCo: %d, coId: %d, coScreen:%d, coOption:%d\n", m_nCurrScreen, i, numCustomFrontendOptions, aScreens[m_nCurrScreen].m_aEntries[i].m_TargetMenu, option.screen, option.screenOptionOrder);
- assert(0 && "Custom frontend options is borked");
- }
-
- break;
-#endif
}
// Highlight trapezoid
@@ -1377,7 +1316,7 @@ CMenuManager::DrawStandardMenus(bool drawCurrScreen)
}
if (m_nDisplayVideoMode != m_nPrefsVideoMode) {
if (strcmp(aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_EntryName, "FED_RES") != 0
- && m_nCurrScreen == MENUPAGE_GRAPHICS_SETTINGS) {
+ && m_nCurrScreen == MENUPAGE_DISPLAY_SETTINGS) {
m_nDisplayVideoMode = m_nPrefsVideoMode;
SetHelperText(3);
}
@@ -1385,29 +1324,11 @@ CMenuManager::DrawStandardMenus(bool drawCurrScreen)
#ifdef IMPROVED_VIDEOMODE
if (m_nSelectedScreenMode != m_nPrefsWindowed) {
if (strcmp(aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_EntryName, "FED_POS") != 0
- && m_nCurrScreen == MENUPAGE_GRAPHICS_SETTINGS) {
+ && m_nCurrScreen == MENUPAGE_DISPLAY_SETTINGS) {
m_nSelectedScreenMode = m_nPrefsWindowed;
}
}
#endif
-#ifdef CUSTOM_FRONTEND_OPTIONS
- static int lastOption = m_nCurrOption;
-
- if (aScreens[m_nCurrScreen].m_aEntries[i].m_Action == MENUACTION_TRIGGERFUNC) {
- FrontendOption& option = customFrontendOptions[aScreens[m_nCurrScreen].m_aEntries[i].m_TargetMenu];
- if (option.onlyApplyOnEnter && m_nCurrOption != i)
- option.displayedValue = *option.value;
-
- if (m_nCurrOption != lastOption && lastOption == i) {
- FrontendOption& oldOption = customFrontendOptions[aScreens[m_nCurrScreen].m_aEntries[lastOption].m_TargetMenu];
- if (oldOption.type == FEOPTION_DYNAMIC)
- oldOption.buttonPressFunc(FEOPTION_ACTION_FOCUSLOSS);
- }
- }
-
- if (i == MAX_MENUROWS - 1 || aScreens[m_nCurrScreen].m_aEntries[i + 1].m_EntryName[0] == '\0')
- lastOption = m_nCurrOption;
-#endif
// TODO(Miami): check
// Sliders
@@ -1464,7 +1385,7 @@ CMenuManager::DrawStandardMenus(bool drawCurrScreen)
case MENUPAGE_STATS:
case MENUPAGE_CONTROLLER_PC:
case MENUPAGE_SOUND_SETTINGS:
- case MENUPAGE_GRAPHICS_SETTINGS:
+ case MENUPAGE_DISPLAY_SETTINGS:
case MENUPAGE_MOUSE_CONTROLS:
DisplayHelperText(nil);
break;
@@ -2140,7 +2061,7 @@ CMenuManager::DrawFrontEnd()
bbNames[0] = { "FEB_SAV",MENUPAGE_NEW_GAME };
bbNames[1] = { "FEB_CON",MENUPAGE_CONTROLLER_PC };
bbNames[2] = { "FEB_AUD",MENUPAGE_SOUND_SETTINGS };
- bbNames[3] = { "FEB_DIS",MENUPAGE_GRAPHICS_SETTINGS };
+ bbNames[3] = { "FEB_DIS",MENUPAGE_DISPLAY_SETTINGS };
bbNames[4] = { "FEB_LAN",MENUPAGE_LANGUAGE_SETTINGS };
bbNames[5] = { "FESZ_QU",MENUPAGE_EXIT };
bbTabCount = 6;
@@ -2152,7 +2073,7 @@ CMenuManager::DrawFrontEnd()
bbNames[2] = { "FEB_BRI",MENUPAGE_BRIEFS };
bbNames[3] = { "FEB_CON",MENUPAGE_CONTROLLER_PC };
bbNames[4] = { "FEB_AUD",MENUPAGE_SOUND_SETTINGS };
- bbNames[5] = { "FEB_DIS",MENUPAGE_GRAPHICS_SETTINGS };
+ bbNames[5] = { "FEB_DIS",MENUPAGE_DISPLAY_SETTINGS };
bbNames[6] = { "FEB_LAN",MENUPAGE_LANGUAGE_SETTINGS };
bbNames[7] = { "FESZ_QU",MENUPAGE_EXIT };
bbTabCount = 8;
@@ -2225,7 +2146,7 @@ CMenuManager::DrawBackground()
case MENUPAGE_DELETE_SLOT_CONFIRM:
currentSprite = FE_ICONSAVE;
break;
- case MENUPAGE_GRAPHICS_SETTINGS:
+ case MENUPAGE_DISPLAY_SETTINGS:
currentSprite = FE_ICONDISPLAY;
break;
case MENUPAGE_SOUND_SETTINGS:
@@ -2471,7 +2392,7 @@ CMenuManager::DrawBackground(bool transitionCall)
menuBg.bottomRight_y = 398.0f;
break;
case MENUPAGE_BRIEFS:
- case MENUPAGE_GRAPHICS_SETTINGS:
+ case MENUPAGE_DISPLAY_SETTINGS:
case MENUPAGE_MAP:
case MENUPAGE_CHOOSE_LOAD_SLOT:
case MENUPAGE_CHOOSE_DELETE_SLOT:
@@ -3106,9 +3027,6 @@ CMenuManager::InitialiseChangedLanguageSettings()
break;
}
-#ifdef CUSTOM_FRONTEND_OPTIONS
- CustomFrontendOptionsPopulate();
-#endif
}
}
@@ -4040,7 +3958,7 @@ CMenuManager::UserInput(void)
}
}
if (changeValueBy != 0) {
- if ((m_nCurrScreen == MENUPAGE_SOUND_SETTINGS || m_nCurrScreen == MENUPAGE_GRAPHICS_SETTINGS || m_nCurrScreen == MENUPAGE_CONTROLLER_PC || m_nCurrScreen == MENUPAGE_MOUSE_CONTROLS)
+ if ((m_nCurrScreen == MENUPAGE_SOUND_SETTINGS || m_nCurrScreen == MENUPAGE_DISPLAY_SETTINGS || m_nCurrScreen == MENUPAGE_CONTROLLER_PC || m_nCurrScreen == MENUPAGE_MOUSE_CONTROLS)
&& aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_Action != MENUACTION_NOTHING
&& aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_Action != MENUACTION_LABEL
&& aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_Action != MENUACTION_YES
@@ -4419,7 +4337,7 @@ CMenuManager::ProcessButtonPresses(uint8 goDown, uint8 goUp, uint8 optionSelecte
}
break;
#ifdef IMPROVED_VIDEOMODE
- case MENUACTION_SCREENMODE:
+ case MENUACTION_SCREENFORMAT:
if (m_nSelectedScreenMode != m_nPrefsWindowed) {
m_nPrefsWindowed = m_nSelectedScreenMode;
_psSelectScreenVM(m_nPrefsVideoMode); // apply same resolution
@@ -4471,7 +4389,7 @@ CMenuManager::ProcessButtonPresses(uint8 goDown, uint8 goUp, uint8 optionSelecte
DMAudio.SetRadioInCar(m_PrefsRadioStation);
DMAudio.PlayFrontEndTrack(m_PrefsRadioStation, 1);
SaveSettings();
- } else if (m_nCurrScreen == MENUPAGE_GRAPHICS_SETTINGS) {
+ } else if (m_nCurrScreen == MENUPAGE_DISPLAY_SETTINGS) {
m_PrefsBrightness = 256;
m_PrefsLOD = 1.2f;
#ifdef LEGACY_MENU_OPTIONS
@@ -4541,33 +4459,6 @@ CMenuManager::ProcessButtonPresses(uint8 goDown, uint8 goUp, uint8 optionSelecte
}
break;
}
-#ifdef CUSTOM_FRONTEND_OPTIONS
- case MENUACTION_TRIGGERFUNC:
- FrontendOption& option = customFrontendOptions[aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_TargetMenu];
- if (m_nCurrScreen == option.screen && m_nCurrOption == option.screenOptionOrder) {
- if (option.type == FEOPTION_SELECT) {
- if (!option.onlyApplyOnEnter) {
- option.displayedValue++;
- if (option.displayedValue >= option.numRightTexts || option.displayedValue < 0)
- option.displayedValue = 0;
- }
- option.changeFunc(option.displayedValue);
- *option.value = option.displayedValue;
-
- } else if (option.type == FEOPTION_DYNAMIC) {
- option.buttonPressFunc(FEOPTION_ACTION_SELECT);
- } else if (option.type == FEOPTION_REDIRECT) {
- ChangeScreen(option.to, option.option, true, option.fadeIn);
- } else if (option.type == FEOPTION_GOBACK) {
- goBack = true;
- }
- } else {
- debug("B- screen:%d option:%d - totalCo: %d, coId: %d, coScreen:%d, coOption:%d\n", m_nCurrScreen, m_nCurrOption, numCustomFrontendOptions, aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_TargetMenu, option.screen, option.screenOptionOrder);
- assert(0 && "Custom frontend options are borked");
- }
-
- break;
-#endif
}
}
ProcessOnOffMenuOptions();
@@ -4699,7 +4590,7 @@ CMenuManager::ProcessButtonPresses(uint8 goDown, uint8 goUp, uint8 optionSelecte
}
break;
#ifdef IMPROVED_VIDEOMODE
- case MENUACTION_SCREENMODE:
+ case MENUACTION_SCREENFORMAT:
DMAudio.PlayFrontEndSound(SOUND_FRONTEND_MENU_NEW_PAGE, 0);
m_nSelectedScreenMode = !m_nSelectedScreenMode;
break;
@@ -4726,36 +4617,6 @@ CMenuManager::ProcessButtonPresses(uint8 goDown, uint8 goUp, uint8 optionSelecte
DMAudio.PlayFrontEndSound(SOUND_FRONTEND_MENU_SETTING_CHANGE, 0);
SaveSettings();
break;
-#ifdef CUSTOM_FRONTEND_OPTIONS
- case MENUACTION_TRIGGERFUNC:
- FrontendOption& option = customFrontendOptions[aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_TargetMenu];
- if (m_nCurrScreen == option.screen && m_nCurrOption == option.screenOptionOrder) {
- if (option.type == FEOPTION_SELECT) {
- if (changeAmount > 0) {
- option.displayedValue++;
- if (option.displayedValue >= option.numRightTexts)
- option.displayedValue = 0;
- } else {
- option.displayedValue--;
- if (option.displayedValue < 0)
- option.displayedValue = option.numRightTexts - 1;
- }
- if (!option.onlyApplyOnEnter) {
- option.changeFunc(option.displayedValue);
- *option.value = option.displayedValue;
- }
- } else if (option.type == FEOPTION_DYNAMIC) {
- option.buttonPressFunc(changeAmount > 0 ? FEOPTION_ACTION_RIGHT : FEOPTION_ACTION_LEFT);
- }
- DMAudio.PlayFrontEndSound(SOUND_FRONTEND_MENU_SETTING_CHANGE, 0);
- }
- else {
- debug("C- screen:%d option:%d - totalCo: %d, coId: %d, coScreen:%d, coOption:%d\n", m_nCurrScreen, m_nCurrOption, numCustomFrontendOptions, aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_TargetMenu, option.screen, option.screenOptionOrder);
- assert(0 && "Custom frontend options are borked");
- }
-
- break;
-#endif
}
CheckSliderMovement(changeAmount);
ProcessOnOffMenuOptions();
diff --git a/src/core/Frontend.h b/src/core/Frontend.h
index e64eae98..858ad1f3 100644
--- a/src/core/Frontend.h
+++ b/src/core/Frontend.h
@@ -160,7 +160,7 @@ enum eMenuScreen
MENUPAGE_NEW_GAME = 1,
MENUPAGE_BRIEFS = 2,
MENUPAGE_SOUND_SETTINGS = 3,
- MENUPAGE_GRAPHICS_SETTINGS = 4,
+ MENUPAGE_DISPLAY_SETTINGS = 4,
MENUPAGE_LANGUAGE_SETTINGS = 5,
MENUPAGE_MAP = 6,
MENUPAGE_NEW_GAME_RELOAD = 7,
@@ -200,6 +200,9 @@ enum eMenuScreen
MENUPAGE_CONTROLLER_PC_OLD4,
MENUPAGE_CONTROLLER_DEBUG,
#endif
+#ifdef GRAPHICS_MENU_OPTIONS
+ MENUPAGE_GRAPHICS_SETTINGS,
+#endif
MENUPAGES
};
@@ -266,12 +269,28 @@ enum eMenuAction
MENUACTION_MOUSESTEER,
MENUACTION_UNK110,
#ifdef IMPROVED_VIDEOMODE
- MENUACTION_SCREENMODE,
+ MENUACTION_SCREENFORMAT,
#endif
#ifdef LEGACY_MENU_OPTIONS
MENUACTION_CTRLVIBRATION,
MENUACTION_CTRLCONFIG,
#endif
+#ifdef ANISOTROPIC_FILTERING
+ MENUACTION_MIPMAPS,
+ MENUACTION_TEXTURE_FILTERING,
+#endif
+#ifdef MULTISAMPLING
+ MENUACTION_MULTISAMPLING,
+#endif
+#ifdef NO_ISLAND_LOADING
+ MENUACTION_ISLANDLOADING,
+#endif
+#ifdef PS2_ALPHA_TEST
+ MENUACTION_PS2_ALPHA_TEST,
+#endif
+#ifdef CUTSCENE_BORDERS_SWITCH
+ MENUACTION_CUTSCENEBORDERS,
+#endif
};
enum eCheckHover
@@ -576,6 +595,10 @@ public:
int32 m_nPrefsSubsystem;
int32 m_nSelectedScreenMode;
#endif
+#ifdef MULTISAMPLING
+ static int8 m_nPrefsMSAALevel;
+ static int8 m_nDisplayMSAALevel;
+#endif
enum LANGUAGE
{
@@ -603,7 +626,25 @@ public:
CMenuManager(void);
~CMenuManager(void) { UnloadTextures(); }
-
+
+#ifdef NO_ISLAND_LOADING
+ enum
+ {
+ ISLAND_LOADING_LOW = 0,
+ ISLAND_LOADING_MEDIUM,
+ ISLAND_LOADING_HIGH
+ };
+
+ static int8 m_DisplayIslandLoading;
+ static int8 m_PrefsIslandLoading;
+
+ #define ISLAND_LOADING_IS(p) if (CMenuManager::m_PrefsIslandLoading == CMenuManager::ISLAND_LOADING_##p)
+ #define ISLAND_LOADING_ISNT(p) if (CMenuManager::m_PrefsIslandLoading != CMenuManager::ISLAND_LOADING_##p)
+#else
+ #define ISLAND_LOADING_IS(p)
+ #define ISLAND_LOADING_ISNT(p)
+#endif
+
void Initialise();
void PrintMap();
void SetFrontEndRenderStates();
diff --git a/src/core/Game.cpp b/src/core/Game.cpp
index 50c4288c..7a2e56ed 100644
--- a/src/core/Game.cpp
+++ b/src/core/Game.cpp
@@ -294,10 +294,6 @@ bool CGame::InitialiseOnceAfterRW(void)
DMAudio.SetEffectsFadeVol(127);
DMAudio.SetMusicFadeVol(127);
CWorld::Players[0].SetPlayerSkin(FrontEndMenuManager.m_PrefsSkinFile);
-
-#ifdef CUSTOM_FRONTEND_OPTIONS
- CustomFrontendOptionsPopulate();
-#endif
return true;
}
diff --git a/src/core/MenuScreens.cpp b/src/core/MenuScreens.cpp
index 6fbf597b..65c265ed 100644
--- a/src/core/MenuScreens.cpp
+++ b/src/core/MenuScreens.cpp
@@ -2,7 +2,43 @@
#include "Frontend.h"
#ifdef PC_MENU
-// If you want to add new options, please don't do that here and see CustomFrontendOptionsPopulate in re3.cpp.
+#ifdef CUTSCENE_BORDERS_SWITCH
+#define MENU_CUTSCENE_BORDERS_SWITCH(screen) MENUACTION_CUTSCENEBORDERS, "FEM_CSB", SAVESLOT_NONE, screen,
+#else
+#define MENU_CUTSCENE_BORDERS_SWITCH(screen)
+#endif
+
+#ifdef IMPROVED_VIDEOMODE
+#define MENU_IMPROVED_VIDEOMODE(screen) MENUACTION_SCREENFORMAT, "FEM_SCF", SAVESLOT_NONE, screen,
+#else
+#define MENU_IMPROVED_VIDEOMODE(screen)
+#endif
+
+#ifdef ANISOTROPIC_FILTERING
+#define MENU_MIPMAPS(screen) MENUACTION_MIPMAPS, "FED_MIP", SAVESLOT_NONE, screen,
+#define MENU_TEXTURE_FILTERING(screen) MENUACTION_TEXTURE_FILTERING, "FED_FIL", SAVESLOT_NONE, screen,
+#else
+#define MENU_MIPMAPS(screen)
+#define MENU_TEXTURE_FILTERING(screen)
+#endif
+
+#ifdef MULTISAMPLING
+#define MENU_MULTISAMPLING(screen) MENUACTION_MULTISAMPLING, "FED_AAS", SAVESLOT_NONE, screen,
+#else
+#define MENU_MULTISAMPLING(screen)
+#endif
+
+#ifdef NO_ISLAND_LOADING
+#define MENU_ISLAND_LOADING(screen) MENUACTION_ISLANDLOADING, "FEM_ISL", SAVESLOT_NONE, screen,
+#else
+#define MENU_ISLAND_LOADING(screen)
+#endif
+
+#ifdef PS2_ALPHA_TEST
+#define MENU_PS2_ALPHA_TEST(screen) MENUACTION_PS2_ALPHA_TEST, "FEM_2PR", SAVESLOT_NONE, screen,
+#else
+#define MENU_PS2_ALPHA_TEST(screen)
+#endif
CMenuScreen aScreens[] = {
// MENUPAGE_STATS = 0
@@ -44,24 +80,24 @@ CMenuScreen aScreens[] = {
#endif
{ "FEH_DIS", MENUPAGE_OPTIONS, 2,
- MENUACTION_BRIGHTNESS, "FED_BRI", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 78, MENUALIGN_LEFT,
- MENUACTION_DRAWDIST, "FEM_LOD", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 103, MENUALIGN_LEFT,
+ MENUACTION_BRIGHTNESS, "FED_BRI", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 78, MENUALIGN_LEFT,
+ MENUACTION_DRAWDIST, "FEM_LOD", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 103, MENUALIGN_LEFT,
#ifdef LEGACY_MENU_OPTIONS
- MENUACTION_FRAMESYNC, "FEM_VSC", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 128, MENUALIGN_LEFT,
+ MENUACTION_FRAMESYNC, "FEM_VSC", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 128, MENUALIGN_LEFT,
#endif
- MENUACTION_FRAMELIMIT, "FEM_FRM", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 128 + Y_OFFSET/2, MENUALIGN_LEFT,
+ MENUACTION_FRAMELIMIT, "FEM_FRM", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 128 + Y_OFFSET/2, MENUALIGN_LEFT,
#ifdef LEGACY_MENU_OPTIONS
- MENUACTION_TRAILS, "FED_TRA", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 178, MENUALIGN_LEFT,
+ MENUACTION_TRAILS, "FED_TRA", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 178, MENUALIGN_LEFT,
#endif
- MENUACTION_SUBTITLES, "FED_SUB", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 153 + Y_OFFSET, MENUALIGN_LEFT,
- MENUACTION_WIDESCREEN, "FED_WIS", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 178 + Y_OFFSET, MENUALIGN_LEFT,
- MENUACTION_LEGENDS, "MAP_LEG", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 202 + Y_OFFSET, MENUALIGN_LEFT,
- MENUACTION_RADARMODE, "FED_RDR", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 228 + Y_OFFSET, MENUALIGN_LEFT,
- MENUACTION_HUD, "FED_HUD", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 253 + Y_OFFSET, MENUALIGN_LEFT,
- MENUACTION_SCREENRES, "FED_RES", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 278 + Y_OFFSET, MENUALIGN_LEFT,
+ MENUACTION_SUBTITLES, "FED_SUB", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 153 + Y_OFFSET, MENUALIGN_LEFT,
+ MENUACTION_WIDESCREEN, "FED_WIS", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 178 + Y_OFFSET, MENUALIGN_LEFT,
+ MENUACTION_LEGENDS, "MAP_LEG", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 202 + Y_OFFSET, MENUALIGN_LEFT,
+ MENUACTION_RADARMODE, "FED_RDR", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 228 + Y_OFFSET, MENUALIGN_LEFT,
+ MENUACTION_HUD, "FED_HUD", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 253 + Y_OFFSET, MENUALIGN_LEFT,
+ MENUACTION_SCREENRES, "FED_RES", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 278 + Y_OFFSET, MENUALIGN_LEFT,
#ifdef IMPROVED_VIDEOMODE
- MENUACTION_SCREENMODE, "FED_POS", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 40, 303 + Y_OFFSET, MENUALIGN_LEFT,
- MENUACTION_RESTOREDEF, "FET_DEF", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 320, 328 + Y_OFFSET, MENUALIGN_CENTER,
+ MENUACTION_SCREENFORMAT,"FED_POS", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 40, 303 + Y_OFFSET, MENUALIGN_LEFT,
+ MENUACTION_RESTOREDEF, "FET_DEF", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 320, 328 + Y_OFFSET, MENUALIGN_CENTER,
MENUACTION_GOBACK, "FEDS_TB", SAVESLOT_NONE, MENUPAGE_NONE, 320, 353 + Y_OFFSET, MENUALIGN_CENTER,
#else
MENUACTION_RESTOREDEF, "FET_DEF", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 320, 303 + Y_OFFSET, MENUALIGN_CENTER,
@@ -230,7 +266,7 @@ CMenuScreen aScreens[] = {
{ "FET_OPT", MENUPAGE_NONE, 5,
MENUACTION_CHANGEMENU, "FEO_CON", SAVESLOT_NONE, MENUPAGE_CONTROLLER_PC, 320, 132, MENUALIGN_CENTER,
MENUACTION_LOADRADIO, "FEO_AUD", SAVESLOT_NONE, MENUPAGE_SOUND_SETTINGS, 0, 0, MENUALIGN_CENTER,
- MENUACTION_CHANGEMENU, "FEO_DIS", SAVESLOT_NONE, MENUPAGE_GRAPHICS_SETTINGS, 0, 0, MENUALIGN_CENTER,
+ MENUACTION_CHANGEMENU, "FEO_DIS", SAVESLOT_NONE, MENUPAGE_DISPLAY_SETTINGS, 0, 0, MENUALIGN_CENTER,
MENUACTION_CHANGEMENU, "FEO_LAN", SAVESLOT_NONE, MENUPAGE_LANGUAGE_SETTINGS, 0, 0, MENUALIGN_CENTER,
MENUACTION_PLAYERSETUP, "FET_PS", SAVESLOT_NONE, MENUPAGE_SKIN_SELECT, 0, 0, MENUALIGN_CENTER,
MENUACTION_GOBACK, "FEDS_TB", SAVESLOT_NONE, 0, 0, 0, MENUALIGN_CENTER,
diff --git a/src/core/Pad.cpp b/src/core/Pad.cpp
index eb2b1e31..42b26c63 100644
--- a/src/core/Pad.cpp
+++ b/src/core/Pad.cpp
@@ -11,7 +11,11 @@
#include "platform.h"
#ifdef XINPUT
#include <xinput.h>
+#if !defined(PSAPI_VERSION) || (PSAPI_VERSION > 1)
#pragma comment( lib, "Xinput9_1_0.lib" )
+#else
+#pragma comment( lib, "Xinput.lib" )
+#endif
#endif
#include "Pad.h"
diff --git a/src/core/Pools.cpp b/src/core/Pools.cpp
index 6e3799f4..fe2cf7ad 100644
--- a/src/core/Pools.cpp
+++ b/src/core/Pools.cpp
@@ -22,21 +22,25 @@ CTreadablePool *CPools::ms_pTreadablePool;
CObjectPool *CPools::ms_pObjectPool;
CDummyPool *CPools::ms_pDummyPool;
CAudioScriptObjectPool *CPools::ms_pAudioScriptObjectPool;
+CColModelPool *CPools::ms_pColModelPool;
+//--MIAMI: done
void
CPools::Initialise(void)
{
- ms_pPtrNodePool = new CCPtrNodePool(NUMPTRNODES);
- ms_pEntryInfoNodePool = new CEntryInfoNodePool(NUMENTRYINFOS);
- ms_pPedPool = new CPedPool(NUMPEDS);
- ms_pVehiclePool = new CVehiclePool(NUMVEHICLES);
- ms_pBuildingPool = new CBuildingPool(NUMBUILDINGS);
- ms_pTreadablePool = new CTreadablePool(NUMTREADABLES);
- ms_pObjectPool = new CObjectPool(NUMOBJECTS);
- ms_pDummyPool = new CDummyPool(NUMDUMMIES);
- ms_pAudioScriptObjectPool = new CAudioScriptObjectPool(NUMAUDIOSCRIPTOBJECTS);
+ ms_pPtrNodePool = new CCPtrNodePool(NUMPTRNODES, "PtrNode");
+ ms_pEntryInfoNodePool = new CEntryInfoNodePool(NUMENTRYINFOS, "EntryInfoNode");
+ ms_pPedPool = new CPedPool(NUMPEDS, "Peds");
+ ms_pVehiclePool = new CVehiclePool(NUMVEHICLES, "Vehicles");
+ ms_pBuildingPool = new CBuildingPool(NUMBUILDINGS, "Buildings");
+ ms_pTreadablePool = new CTreadablePool(NUMTREADABLES, "Treadables");
+ ms_pObjectPool = new CObjectPool(NUMOBJECTS, "Objects");
+ ms_pDummyPool = new CDummyPool(NUMDUMMIES, "Dummys");
+ ms_pAudioScriptObjectPool = new CAudioScriptObjectPool(NUMAUDIOSCRIPTOBJECTS, "AudioScriptObj");
+ ms_pColModelPool = new CColModelPool(NUMCOLMODELS, "ColModel");
}
+//--MIAMI: done
void
CPools::ShutDown(void)
{
@@ -49,6 +53,7 @@ CPools::ShutDown(void)
debug("Objects left %d\n", ms_pObjectPool->GetNoOfUsedSpaces());
debug("Dummys left %d\n", ms_pDummyPool->GetNoOfUsedSpaces());
debug("AudioScriptObjects left %d\n", ms_pAudioScriptObjectPool->GetNoOfUsedSpaces());
+ debug("ColModels left %d\n", ms_pColModelPool->GetNoOfUsedSpaces());
printf("Shutdown pool started\n");
delete ms_pPtrNodePool;
@@ -60,6 +65,7 @@ CPools::ShutDown(void)
delete ms_pObjectPool;
delete ms_pDummyPool;
delete ms_pAudioScriptObjectPool;
+ delete ms_pColModelPool;
printf("Shutdown pool done\n");
}
diff --git a/src/core/Pools.h b/src/core/Pools.h
index 2f0537ff..afef1b85 100644
--- a/src/core/Pools.h
+++ b/src/core/Pools.h
@@ -19,6 +19,7 @@ typedef CPool<CTreadable> CTreadablePool;
typedef CPool<CObject, CCutsceneObject> CObjectPool;
typedef CPool<CDummy, CDummyPed> CDummyPool;
typedef CPool<cAudioScriptObject> CAudioScriptObjectPool;
+typedef CPool<CColModel> CColModelPool;
class CPools
{
@@ -31,6 +32,7 @@ class CPools
static CObjectPool *ms_pObjectPool;
static CDummyPool *ms_pDummyPool;
static CAudioScriptObjectPool *ms_pAudioScriptObjectPool;
+ static CColModelPool *ms_pColModelPool;
public:
static CCPtrNodePool *GetPtrNodePool(void) { return ms_pPtrNodePool; }
static CEntryInfoNodePool *GetEntryInfoNodePool(void) { return ms_pEntryInfoNodePool; }
@@ -41,6 +43,7 @@ public:
static CObjectPool *GetObjectPool(void) { return ms_pObjectPool; }
static CDummyPool *GetDummyPool(void) { return ms_pDummyPool; }
static CAudioScriptObjectPool *GetAudioScriptObjectPool(void) { return ms_pAudioScriptObjectPool; }
+ static CColModelPool *GetColModelPool(void) { return ms_pColModelPool; }
static void Initialise(void);
static void ShutDown(void);
diff --git a/src/core/SurfaceTable.cpp b/src/core/SurfaceTable.cpp
index 9076a9a6..56cea203 100644
--- a/src/core/SurfaceTable.cpp
+++ b/src/core/SurfaceTable.cpp
@@ -6,6 +6,8 @@
#include "Collision.h"
#include "SurfaceTable.h"
+//--MIAMI: file done
+
float CSurfaceTable::ms_aAdhesiveLimitTable[NUMADHESIVEGROUPS][NUMADHESIVEGROUPS];
void
@@ -148,3 +150,9 @@ CSurfaceTable::GetAdhesiveLimit(CColPoint &colpoint)
{
return ms_aAdhesiveLimitTable[GetAdhesionGroup(colpoint.surfaceB)][GetAdhesionGroup(colpoint.surfaceA)];
}
+
+bool
+CSurfaceTable::IsSoftLanding(uint8 surf)
+{
+ return surf == SURFACE_GRASS || surf == SURFACE_SAND || surf == SURFACE_SAND_BEACH;
+}
diff --git a/src/core/SurfaceTable.h b/src/core/SurfaceTable.h
index 359ebd5c..cd08c843 100644
--- a/src/core/SurfaceTable.h
+++ b/src/core/SurfaceTable.h
@@ -96,4 +96,5 @@ public:
static int GetAdhesionGroup(uint8 surfaceType);
static float GetWetMultiplier(uint8 surfaceType);
static float GetAdhesiveLimit(CColPoint &colpoint);
+ static bool IsSoftLanding(uint8 surf);
};
diff --git a/src/core/config.h b/src/core/config.h
index a061408a..1cd9ca6c 100644
--- a/src/core/config.h
+++ b/src/core/config.h
@@ -27,16 +27,16 @@ enum Config {
// Pool sizes
NUMPTRNODES = 50000,
- NUMENTRYINFOS = 5400, // only 3200 in VC???
+ NUMENTRYINFOS = 3200,
NUMPEDS = 140,
NUMVEHICLES = 110,
NUMBUILDINGS = 7000,
- NUMTREADABLES = 1214, // 1 in VC
+ NUMTREADABLES = 1,
NUMOBJECTS = 460,
- NUMDUMMIES = 2802, // 2340 in VC
- NUMAUDIOSCRIPTOBJECTS = 256, // 192 in VC
+ NUMDUMMIES = 2340,
+ NUMAUDIOSCRIPTOBJECTS = 192,
+ NUMCOLMODELS = 4400,
NUMCUTSCENEOBJECTS = 50, // does not exist in VC
- // TODO(MIAMI): colmodel pool
NUMANIMBLOCKS = 35,
NUMANIMATIONS = 450,
@@ -224,9 +224,15 @@ enum Config {
//#define DISABLE_LOADING_SCREEN // disable the loading screen which vastly improves the loading time
//#define NO_ISLAND_LOADING // disable loadscreen between islands via loading all island data at once, consumes more memory and CPU
//#define USE_TEXTURE_POOL
-#define CUTSCENE_BORDERS_SWITCH
+//#define CUTSCENE_BORDERS_SWITCH
//#define EXTENDED_COLOURFILTER // more options for colour filter (replaces mblur)
//#define EXTENDED_PIPELINES // custom render pipelines (includes Neo)
+//#define MULTISAMPLING // adds MSAA option TODO
+
+#ifdef LIBRW
+// these are not supported with librw yet
+# undef MULTISAMPLING
+#endif
// Water & Particle
#define PC_PARTICLE
@@ -256,12 +262,13 @@ enum Config {
#ifndef PC_MENU
# define PS2_MENU
//# define PS2_MENU_USEALLPAGEICONS
-#else
//# define PS2_LIKE_MENU // An effort to recreate PS2 menu, cycling through tabs, different bg etc.
+#else
# define MAP_ENHANCEMENTS // Adding waypoint etc.
# define TRIANGLE_BACK_BUTTON
//# define CIRCLE_BACK_BUTTON
//#define CUSTOM_FRONTEND_OPTIONS
+# define GRAPHICS_MENU_OPTIONS
#define LEGACY_MENU_OPTIONS
#define MUCH_SHORTER_OUTRO_SCREEN
diff --git a/src/core/main.cpp b/src/core/main.cpp
index 27f6abd9..7a25daac 100644
--- a/src/core/main.cpp
+++ b/src/core/main.cpp
@@ -3,6 +3,9 @@
#include "rphanim.h"
#include "rpskin.h"
#include "rtbmp.h"
+#ifndef LIBRW
+#include "rpanisot.h"
+#endif
#include "main.h"
#include "CdStream.h"
@@ -384,6 +387,9 @@ PluginAttach(void)
return FALSE;
}
+#ifndef LIBRW
+ RpAnisotPluginAttach();
+#endif
#ifdef EXTENDED_PIPELINES
CustomPipes::CustomPipeRegister();
#endif
diff --git a/src/core/main.h b/src/core/main.h
index 9ad4ed1c..96fbef05 100644
--- a/src/core/main.h
+++ b/src/core/main.h
@@ -20,6 +20,9 @@ extern bool gbShowTimebars;
class CSprite2d;
+bool DoRWStuffStartOfFrame(int16 TopRed, int16 TopGreen, int16 TopBlue, int16 BottomRed, int16 BottomGreen, int16 BottomBlue, int16 Alpha);
+bool DoRWStuffStartOfFrame_Horizon(int16 TopRed, int16 TopGreen, int16 TopBlue, int16 BottomRed, int16 BottomGreen, int16 BottomBlue, int16 Alpha);
+void DoRWStuffEndOfFrame(void);
void InitialiseGame(void);
void LoadingScreen(const char *str1, const char *str2, const char *splashscreen);
void LoadingIslandScreen(const char *levelName);
diff --git a/src/core/re3.cpp b/src/core/re3.cpp
index 3b6b678a..6a305b4c 100644
--- a/src/core/re3.cpp
+++ b/src/core/re3.cpp
@@ -75,110 +75,6 @@ mysrand(unsigned int seed)
myrand_seed = seed;
}
-#ifdef CUSTOM_FRONTEND_OPTIONS
-#include "frontendoption.h"
-#include "platform.h"
-
-void ReloadFrontendOptions(void)
-{
- CustomFrontendOptionsPopulate();
-}
-
-#ifdef MORE_LANGUAGES
-void LangPolSelect(int8 action)
-{
- if (action == FEOPTION_ACTION_SELECT) {
- FrontEndMenuManager.m_PrefsLanguage = CMenuManager::LANGUAGE_POLISH;
- FrontEndMenuManager.m_bFrontEnd_ReloadObrTxtGxt = true;
- FrontEndMenuManager.InitialiseChangedLanguageSettings();
- FrontEndMenuManager.SaveSettings();
- }
-}
-
-void LangRusSelect(int8 action)
-{
- if (action == FEOPTION_ACTION_SELECT) {
- FrontEndMenuManager.m_PrefsLanguage = CMenuManager::LANGUAGE_RUSSIAN;
- FrontEndMenuManager.m_bFrontEnd_ReloadObrTxtGxt = true;
- FrontEndMenuManager.InitialiseChangedLanguageSettings();
- FrontEndMenuManager.SaveSettings();
- }
-}
-
-void LangJapSelect(int8 action)
-{
- if (action == FEOPTION_ACTION_SELECT) {
- FrontEndMenuManager.m_PrefsLanguage = CMenuManager::LANGUAGE_JAPANESE;
- FrontEndMenuManager.m_bFrontEnd_ReloadObrTxtGxt = true;
- FrontEndMenuManager.InitialiseChangedLanguageSettings();
- FrontEndMenuManager.SaveSettings();
- }
-}
-#endif
-
-#ifdef IMPROVED_VIDEOMODE
-void ScreenModeChange(int8 displayedValue)
-{
- if (displayedValue != FrontEndMenuManager.m_nPrefsWindowed) {
- FrontEndMenuManager.m_nPrefsWindowed = displayedValue;
- _psSelectScreenVM(FrontEndMenuManager.m_nPrefsVideoMode); // apply same resolution
- FrontEndMenuManager.SetHelperText(0);
- FrontEndMenuManager.SaveSettings();
- }
-}
-#endif
-
-#ifdef FREE_CAM
-void ToggleFreeCam(int8 action)
-{
- if (action == FEOPTION_ACTION_SELECT) {
- TheCamera.bFreeCam = !TheCamera.bFreeCam;
- FrontEndMenuManager.SaveSettings();
- }
-}
-#endif
-
-#ifdef CUTSCENE_BORDERS_SWITCH
-void BorderModeChange(int8 displayedValue)
-{
- CMenuManager::m_PrefsCutsceneBorders = !!displayedValue;
- FrontEndMenuManager.SaveSettings();
-}
-#endif
-
-// Reloaded on language change, so you can use hardcoded wchar* and TheText.Get with peace of mind
-void
-CustomFrontendOptionsPopulate(void)
-{
- RemoveCustomFrontendOptions(); // if exist
-
-#ifdef MORE_LANGUAGES
- FrontendOptionSetPosition(MENUPAGE_LANGUAGE_SETTINGS);
- FrontendOptionAddDynamic(TheText.Get("FEL_POL"), nil, LangPolSelect, nil);
- FrontendOptionAddDynamic(TheText.Get("FEL_RUS"), nil, LangRusSelect, nil);
- FrontendOptionAddDynamic(TheText.Get("FEL_JAP"), nil, LangJapSelect, nil);
-#endif
-
-#ifdef IMPROVED_VIDEOMODE
- static const wchar *screenModes[] = { (wchar*)L"FULLSCREEN", (wchar*)L"WINDOWED" };
- FrontendOptionSetPosition(MENUPAGE_GRAPHICS_SETTINGS, 8);
- FrontendOptionAddSelect(TheText.Get("SCRFOR"), screenModes, 2, (int8*)&FrontEndMenuManager.m_nPrefsWindowed, true, ScreenModeChange, nil);
-#endif
-
-#ifdef FREE_CAM
- static const wchar *text = (wchar*)L"TOGGLE FREE CAM";
- FrontendOptionSetPosition(MENUPAGE_CONTROLLER_PC, 1);
- FrontendOptionAddDynamic(text, nil, ToggleFreeCam, nil);
-#endif
-
-#ifdef CUTSCENE_BORDERS_SWITCH
- static const wchar *off_on[] = { TheText.Get("FEM_OFF"), TheText.Get("FEM_ON") };
- FrontendOptionSetPosition(MENUPAGE_GRAPHICS_SETTINGS, 9);
- FrontendOptionAddSelect((const wchar *)L"CUTSCENE BORDERS", off_on, 2, (int8 *)&CMenuManager::m_PrefsCutsceneBorders, false, BorderModeChange, nil);
-#endif
-}
-#endif
-
#ifdef DEBUGMENU
void WeaponCheat1();
void WeaponCheat2();
@@ -565,9 +461,6 @@ DebugMenuPopulate(void)
DebugMenuAddVarBool8("Debug", "Script Heli On", &CHeli::ScriptHeliOn, nil);
-#ifdef CUSTOM_FRONTEND_OPTIONS
- DebugMenuAddCmd("Debug", "Reload custom frontend options", ReloadFrontendOptions);
-#endif
DebugMenuAddCmd("Debug", "Start Credits", CCredits::Start);
DebugMenuAddCmd("Debug", "Stop Credits", CCredits::Stop);
diff --git a/src/core/templates.h b/src/core/templates.h
index 465e3bef..9f5bd5ea 100644
--- a/src/core/templates.h
+++ b/src/core/templates.h
@@ -45,7 +45,7 @@ class CPool
public:
// TODO(MIAMI): remove ctor without name argument
- CPool(int size){
+ CPool(int size, const char *name){
// TODO: use new here
m_entries = (U*)malloc(sizeof(U)*size);
m_flags = (Flags*)malloc(sizeof(Flags)*size);
@@ -56,8 +56,6 @@ public:
m_flags[i].free = 1;
}
}
- CPool(int size, const char *name)
- : CPool(size) {}
~CPool() {
Flush();
}