mirror of https://github.com/OpenRCT2/OpenRCT2.git
add config for hide mega park and set locking as default
This commit is contained in:
parent
b45ca38d52
commit
b94cd7499d
|
@ -204,7 +204,8 @@ config_property_definition _generalDefinitions[] = {
|
|||
{ offsetof(general_configuration, trap_cursor), "trap_cursor", CONFIG_VALUE_TYPE_BOOLEAN, false, NULL },
|
||||
{ offsetof(general_configuration, auto_open_shops), "auto_open_shops", CONFIG_VALUE_TYPE_BOOLEAN, false, NULL },
|
||||
{ offsetof(general_configuration, scenario_select_mode), "scenario_select_mode", CONFIG_VALUE_TYPE_UINT8, SCENARIO_SELECT_MODE_ORIGIN, NULL },
|
||||
{ offsetof(general_configuration, scenario_unlocking_enabled), "scenario_unlocking_enabled", CONFIG_VALUE_TYPE_BOOLEAN, false, NULL },
|
||||
{ offsetof(general_configuration, scenario_unlocking_enabled), "scenario_unlocking_enabled", CONFIG_VALUE_TYPE_BOOLEAN, true, NULL },
|
||||
{ offsetof(general_configuration, scenario_hide_mega_park), "scenario_hide_mega_park", CONFIG_VALUE_TYPE_BOOLEAN, true, NULL },
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -179,6 +179,7 @@ typedef struct {
|
|||
uint8 auto_open_shops;
|
||||
uint8 scenario_select_mode;
|
||||
uint8 scenario_unlocking_enabled;
|
||||
uint8 scenario_hide_mega_park;
|
||||
} general_configuration;
|
||||
|
||||
typedef struct {
|
||||
|
|
|
@ -606,8 +606,7 @@ static void initialise_list_items(rct_window *w)
|
|||
if (megaParkListItemIndex != -1) {
|
||||
bool megaParkLocked = (rct1CompletedScenarios & rct1RequiredCompletedScenarios) != rct1RequiredCompletedScenarios;
|
||||
_listItems[megaParkListItemIndex].scenario.is_locked = megaParkLocked;
|
||||
#ifdef HIDE_MEGA_PARK
|
||||
if (megaParkLocked) {
|
||||
if (megaParkLocked && gConfigGeneral.scenario_hide_mega_park) {
|
||||
// Remove mega park
|
||||
int remainingItems = length - megaParkListItemIndex - 1;
|
||||
memmove(&_listItems[megaParkListItemIndex], &_listItems[megaParkListItemIndex + 1], remainingItems);
|
||||
|
@ -624,7 +623,6 @@ static void initialise_list_items(rct_window *w)
|
|||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue