mirror of
https://github.com/CTCaer/RetroArch.git
synced 2024-12-18 16:28:51 +00:00
separate hardcore achievements
This commit is contained in:
parent
f190909aae
commit
486254f06d
43
cheevos.c
43
cheevos.c
@ -2566,7 +2566,7 @@ void cheevos_reset_game(void)
|
||||
}
|
||||
}
|
||||
|
||||
void cheevos_populate_menu(void *data)
|
||||
void cheevos_populate_menu(void *data, bool hardcore)
|
||||
{
|
||||
#ifdef HAVE_MENU
|
||||
unsigned i;
|
||||
@ -2579,15 +2579,42 @@ void cheevos_populate_menu(void *data)
|
||||
|
||||
for (i = 0; cheevo < end; i++, cheevo++)
|
||||
{
|
||||
if (!cheevo->active)
|
||||
if (!hardcore)
|
||||
{
|
||||
menu_entries_append_enum(info->list, cheevo->title,
|
||||
cheevo->description, MENU_ENUM_LABEL_CHEEVOS_UNLOCKED_ENTRY,
|
||||
MENU_SETTINGS_CHEEVOS_START + i, 0, 0);
|
||||
items_found++;
|
||||
if (!(cheevo->active & CHEEVOS_ACTIVE_SOFTCORE))
|
||||
{
|
||||
menu_entries_append_enum(info->list, cheevo->title,
|
||||
cheevo->description, MENU_ENUM_LABEL_CHEEVOS_UNLOCKED_ENTRY,
|
||||
MENU_SETTINGS_CHEEVOS_START + i, 0, 0);
|
||||
items_found++;
|
||||
}
|
||||
else
|
||||
{
|
||||
menu_entries_append_enum(info->list, cheevo->title,
|
||||
cheevo->description, MENU_ENUM_LABEL_CHEEVOS_LOCKED_ENTRY,
|
||||
MENU_SETTINGS_CHEEVOS_START + i, 0, 0);
|
||||
items_found++;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!(cheevo->active & CHEEVOS_ACTIVE_HARDCORE))
|
||||
{
|
||||
menu_entries_append_enum(info->list, cheevo->title,
|
||||
cheevo->description, MENU_ENUM_LABEL_CHEEVOS_UNLOCKED_ENTRY,
|
||||
MENU_SETTINGS_CHEEVOS_START + i, 0, 0);
|
||||
items_found++;
|
||||
}
|
||||
else
|
||||
{
|
||||
menu_entries_append_enum(info->list, cheevo->title,
|
||||
cheevo->description, MENU_ENUM_LABEL_CHEEVOS_LOCKED_ENTRY,
|
||||
MENU_SETTINGS_CHEEVOS_START + i, 0, 0);
|
||||
items_found++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
if (settings->cheevos.test_unofficial)
|
||||
{
|
||||
cheevo = cheevos_locals.unofficial.cheevos;
|
||||
@ -2634,7 +2661,7 @@ void cheevos_populate_menu(void *data)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
*/
|
||||
if (items_found == 0)
|
||||
{
|
||||
menu_entries_append_enum(info->list,
|
||||
|
@ -43,7 +43,7 @@ bool cheevos_load(const void *data);
|
||||
|
||||
void cheevos_reset_game(void);
|
||||
|
||||
void cheevos_populate_menu(void *data);
|
||||
void cheevos_populate_menu(void *data, bool hardcore);
|
||||
|
||||
bool cheevos_get_description(cheevos_ctx_desc_t *desc);
|
||||
|
||||
|
@ -6,6 +6,8 @@ MSG_HASH(MENU_ENUM_LABEL_ACCOUNTS_RETRO_ACHIEVEMENTS,
|
||||
"retro_achievements")
|
||||
MSG_HASH(MENU_ENUM_LABEL_ACHIEVEMENT_LIST,
|
||||
"achievement_list")
|
||||
MSG_HASH(MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE,
|
||||
"achievement_list_hardcore")
|
||||
MSG_HASH(MENU_ENUM_LABEL_ADD_CONTENT_LIST,
|
||||
"add_content")
|
||||
MSG_HASH(MENU_ENUM_LABEL_CONFIGURATIONS_LIST,
|
||||
|
@ -94,6 +94,11 @@ MSG_HASH(
|
||||
MENU_ENUM_LABEL_VALUE_ACHIEVEMENT_LIST,
|
||||
"Achievement List"
|
||||
)
|
||||
|
||||
MSG_HASH(
|
||||
MENU_ENUM_LABEL_VALUE_ACHIEVEMENT_LIST_HARDCORE,
|
||||
"Achievement List (Hardcore)"
|
||||
)
|
||||
MSG_HASH(
|
||||
MENU_ENUM_LABEL_VALUE_ADD_CONTENT_LIST,
|
||||
"Scan Content"
|
||||
|
@ -80,6 +80,11 @@ static int deferred_push_achievement_list(menu_displaylist_info_t *info)
|
||||
return deferred_push_dlist(info, DISPLAYLIST_ACHIEVEMENT_LIST);
|
||||
}
|
||||
|
||||
static int deferred_push_achievement_list_hardcore(menu_displaylist_info_t *info)
|
||||
{
|
||||
return deferred_push_dlist(info, DISPLAYLIST_ACHIEVEMENT_LIST_HARDCORE);
|
||||
}
|
||||
|
||||
static int deferred_push_rdb_collection(menu_displaylist_info_t *info)
|
||||
{
|
||||
return deferred_push_dlist(info, DISPLAYLIST_PLAYLIST_COLLECTION);
|
||||
@ -996,6 +1001,9 @@ static int menu_cbs_init_bind_deferred_push_compare_label(
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST:
|
||||
BIND_ACTION_DEFERRED_PUSH(cbs, deferred_push_achievement_list);
|
||||
break;
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE:
|
||||
BIND_ACTION_DEFERRED_PUSH(cbs, deferred_push_achievement_list_hardcore);
|
||||
break;
|
||||
case MENU_ENUM_LABEL_CORE_COUNTERS:
|
||||
BIND_ACTION_DEFERRED_PUSH(cbs, deferred_push_core_counters);
|
||||
break;
|
||||
@ -1256,6 +1264,9 @@ static int menu_cbs_init_bind_deferred_push_compare_label(
|
||||
case MENU_LABEL_ACHIEVEMENT_LIST:
|
||||
BIND_ACTION_DEFERRED_PUSH(cbs, deferred_push_achievement_list);
|
||||
break;
|
||||
case MENU_LABEL_ACHIEVEMENT_LIST_HARDCORE:
|
||||
BIND_ACTION_DEFERRED_PUSH(cbs, deferred_push_achievement_list_hardcore);
|
||||
break;
|
||||
case MENU_LABEL_CORE_COUNTERS:
|
||||
BIND_ACTION_DEFERRED_PUSH(cbs, deferred_push_core_counters);
|
||||
break;
|
||||
|
@ -1714,6 +1714,7 @@ static int menu_cbs_init_bind_get_string_representation_compare_label(
|
||||
case MENU_ENUM_LABEL_CORE_INFORMATION:
|
||||
case MENU_ENUM_LABEL_SYSTEM_INFORMATION:
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST:
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE:
|
||||
case MENU_ENUM_LABEL_SAVE_STATE:
|
||||
case MENU_ENUM_LABEL_LOAD_STATE:
|
||||
BIND_ACTION_GET_VALUE(cbs,
|
||||
@ -1952,6 +1953,10 @@ int menu_cbs_init_bind_get_string_representation(menu_file_list_cbs_t *cbs,
|
||||
BIND_ACTION_GET_VALUE(cbs,
|
||||
menu_action_setting_disp_set_label_achievement_information);
|
||||
return 0;
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE:
|
||||
BIND_ACTION_GET_VALUE(cbs,
|
||||
menu_action_setting_disp_set_label_achievement_information);
|
||||
return 0;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -3696,6 +3696,7 @@ static int menu_cbs_init_bind_ok_compare_label(menu_file_list_cbs_t *cbs,
|
||||
case MENU_ENUM_LABEL_SYSTEM_INFORMATION:
|
||||
case MENU_ENUM_LABEL_NETWORK_INFORMATION:
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST:
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE:
|
||||
case MENU_ENUM_LABEL_DISK_OPTIONS:
|
||||
case MENU_ENUM_LABEL_SETTINGS:
|
||||
case MENU_ENUM_LABEL_FRONTEND_COUNTERS:
|
||||
|
@ -1285,6 +1285,7 @@ static int menu_cbs_init_bind_title_compare_label(menu_file_list_cbs_t *cbs,
|
||||
break;
|
||||
case MENU_ENUM_LABEL_MANAGEMENT:
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST:
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE:
|
||||
case MENU_ENUM_LABEL_VIDEO_SHADER_PARAMETERS:
|
||||
case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_PARAMETERS:
|
||||
case MENU_ENUM_LABEL_CONTENT_COLLECTION_LIST:
|
||||
|
@ -1747,6 +1747,8 @@ static uintptr_t xmb_icon_get_id(xmb_handle_t *xmb,
|
||||
return xmb->textures.list[XMB_TEXTURE_SHADER_OPTIONS];
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST:
|
||||
return xmb->textures.list[XMB_TEXTURE_ACHIEVEMENT_LIST];
|
||||
case MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE:
|
||||
return xmb->textures.list[XMB_TEXTURE_ACHIEVEMENT_LIST];
|
||||
case MENU_ENUM_LABEL_SAVE_STATE:
|
||||
return xmb->textures.list[XMB_TEXTURE_SAVESTATE];
|
||||
case MENU_ENUM_LABEL_LOAD_STATE:
|
||||
|
@ -2739,11 +2739,18 @@ static int menu_displaylist_parse_load_content_settings(
|
||||
|
||||
#ifdef HAVE_CHEEVOS
|
||||
if(settings->cheevos.enable)
|
||||
{
|
||||
menu_entries_append_enum(info->list,
|
||||
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_ACHIEVEMENT_LIST),
|
||||
msg_hash_to_str(MENU_ENUM_LABEL_ACHIEVEMENT_LIST),
|
||||
MENU_ENUM_LABEL_ACHIEVEMENT_LIST,
|
||||
MENU_SETTING_ACTION, 0, 0);
|
||||
menu_entries_append_enum(info->list,
|
||||
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_ACHIEVEMENT_LIST_HARDCORE),
|
||||
msg_hash_to_str(MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE),
|
||||
MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE,
|
||||
MENU_SETTING_ACTION, 0, 0);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
@ -4148,6 +4155,7 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, void *data)
|
||||
case DISPLAYLIST_NETWORK_INFO:
|
||||
case DISPLAYLIST_SYSTEM_INFO:
|
||||
case DISPLAYLIST_ACHIEVEMENT_LIST:
|
||||
case DISPLAYLIST_ACHIEVEMENT_LIST_HARDCORE:
|
||||
case DISPLAYLIST_CORES:
|
||||
case DISPLAYLIST_CORES_DETECTED:
|
||||
case DISPLAYLIST_CORES_UPDATER:
|
||||
@ -5757,7 +5765,12 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, void *data)
|
||||
break;
|
||||
#ifdef HAVE_CHEEVOS
|
||||
case DISPLAYLIST_ACHIEVEMENT_LIST:
|
||||
cheevos_populate_menu(info);
|
||||
cheevos_populate_menu(info, false);
|
||||
info->need_push = true;
|
||||
info->need_refresh = true;
|
||||
break;
|
||||
case DISPLAYLIST_ACHIEVEMENT_LIST_HARDCORE:
|
||||
cheevos_populate_menu(info, true);
|
||||
info->need_push = true;
|
||||
info->need_refresh = true;
|
||||
break;
|
||||
|
@ -105,6 +105,7 @@ enum menu_displaylist_ctl_state
|
||||
DISPLAYLIST_NETWORK_INFO,
|
||||
DISPLAYLIST_SYSTEM_INFO,
|
||||
DISPLAYLIST_ACHIEVEMENT_LIST,
|
||||
DISPLAYLIST_ACHIEVEMENT_LIST_HARDCORE,
|
||||
DISPLAYLIST_USER_BINDS_LIST,
|
||||
DISPLAYLIST_ACCOUNTS_LIST,
|
||||
DISPLAYLIST_DRIVER_SETTINGS_LIST,
|
||||
|
@ -1536,8 +1536,10 @@ enum msg_hash_enums
|
||||
MENU_ENUM_LABEL_VALUE_NETWORK_INFORMATION,
|
||||
MENU_ENUM_LABEL_SYSTEM_INFORMATION,
|
||||
MENU_ENUM_LABEL_ACHIEVEMENT_LIST,
|
||||
MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE,
|
||||
MENU_ENUM_LABEL_VALUE_SYSTEM_INFORMATION,
|
||||
MENU_ENUM_LABEL_VALUE_ACHIEVEMENT_LIST,
|
||||
MENU_ENUM_LABEL_VALUE_ACHIEVEMENT_LIST_HARDCORE,
|
||||
MENU_ENUM_LABEL_CORE_INFORMATION,
|
||||
MENU_ENUM_LABEL_VALUE_CORE_INFORMATION,
|
||||
MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PARAMETERS,
|
||||
@ -2153,6 +2155,7 @@ enum msg_hash_enums
|
||||
#define MENU_LABEL_FRONTEND_COUNTERS 0xe5696877U
|
||||
#define MENU_LABEL_CORE_COUNTERS 0x64cc83e0U
|
||||
#define MENU_LABEL_ACHIEVEMENT_LIST 0x7b90fc49U
|
||||
#define MENU_LABEL_ACHIEVEMENT_LIST_HARDCORE 0x7c632930U
|
||||
#define MENU_LABEL_CORE_INFORMATION 0xb638e0d3U
|
||||
#define MENU_LABEL_CORE_OPTIONS 0xf65e60f9U
|
||||
#define MENU_LABEL_SHADER_OPTIONS 0x1f7d2fc7U
|
||||
|
Loading…
Reference in New Issue
Block a user