Files
MinecraftLegends/Win32.DX11.Release/data/resource_packs/vanilla/ui/realms_settings_screen.json
T
2026-03-08 15:34:38 -05:00

591 lines
19 KiB
JSON

/********************************************************
+* (c) Mojang. All rights reserved *
+* (c) Microsoft. All rights reserved. *
+*********************************************************/
{
"namespace": "realms_settings",
"settings_screen@settings_common.screen_base": {
"$selector_stack_panel": "realms_settings.selector_panel",
"$section_content_panels": "realms_settings.section_content_panels",
"$section_header_panels": "common.empty_panel",
"$section_footer_panels": "common.empty_panel"
},
"generic_section": {
"type": "stack_panel",
"size": [ "100%", "100%c" ],
"anchor_from": "top_left",
"anchor_to": "top_left",
"bindings": [
{
"binding_type": "view",
"source_control_name": "$section_button_name",
"source_property_name": "#toggle_state",
"target_property_name": "#visible"
}
],
"controls": [
{ "$section_content_name@$section_content_name": {} }
]
},
"generic_section_wrapper": {
"type": "panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"offset": [ 2, 0 ],
"size": [ "100% - 4px", "100%c" ],
"$section_button_name|default": "name of selection toggle button",
"$section_content_name|default": "name of class defining the content",
"controls": [
{ "generic_section@realms_settings.generic_section": {} }
]
},
// Subscription content
"player_count_label@settings_common.option_info_label": {
"$option_label": "realmsSettingsScreen.playerCountLabel",
"$container_size": [ "100%", "30px" ],
"$container_text_binding_name": "#realm_player_count"
},
"realm_duration_label@settings_common.option_info_label": {
"$option_label": "realmsSettingsScreen.realmDurationLabel",
"$container_size": [ "100%", "30px" ],
"$container_text_binding_name": "#realm_duration_label"
},
"realm_subscription_origin_label@settings_common.option_info_label": {
"$container_size": [ "100%", "60px" ],
"$container_text_binding_name": "#realm_subscription_origin",
"$show_option_label": false,
"bindings": [
{
"binding_name": "#realm_subscription_origin_visibility",
"binding_name_override": "#visible"
}
]
},
"manage_subscription_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.manageSubscriptionButton",
"$pressed_button_name": "menu_realms_manage_subscription",
"bindings": [
{
"binding_name": "#manage_subscription_button_visible",
"binding_name_override": "#visible"
}
]
},
"renew_subscription_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.renewRealmButton",
"$pressed_button_name": "menu_realms_renew_subscription",
"bindings": [
{
"binding_name": "#renew_subscription_button_visible",
"binding_name_override": "#visible"
}
]
},
"extend_consumable_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.extendRealmButton",
"$pressed_button_name": "menu_realms_extend_consumable",
"bindings": [
{
"binding_name": "#extend_consumable_button_visible",
"binding_name_override": "#visible"
}
]
},
"renew_consumable_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.renewRealmButton",
"$pressed_button_name": "menu_realms_renew_consumable",
"bindings": [
{
"binding_name": "#renew_consumable_button_visible",
"binding_name_override": "#visible"
}
]
},
"open_realm_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.openRealmButton",
"$pressed_button_name": "menu_open_realm",
"bindings": [
{
"binding_name": "#open_realm_button_visible",
"binding_name_override": "#visible"
}
]
},
"close_realm_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.closeRealmButton",
"$pressed_button_name": "menu_close_realm",
"bindings": [
{
"binding_name": "#close_realm_button_visible",
"binding_name_override": "#visible"
}
]
},
"subscriptions_section": {
"type": "panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"size": [ "100%", "100%c" ],
"controls": [
{
"loading_view": {
"type": "label",
"color": "$body_text_color",
"size": [ "default", "80px" ],
"offset": [ 0, 10 ],
"text": "realmsSettingsScreen.LoadingSubscription",
"bindings": [
{
"binding_name": "#realms_subscription_loading_message_visible",
"binding_name_override": "#visible"
}
]
}
},
{
"loaded_view": {
"type": "stack_panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"controls": [
{ "player_count_label@realms_settings.player_count_label": {} },
{ "realm_duration_label@realms_settings.realm_duration_label": {} },
{ "realm_subscription_origin_label@realms_settings.realm_subscription_origin_label": {} },
{ "manage_subscription_button@realms_settings.manage_subscription_button": {} },
{ "renew_subscription_button@realms_settings.renew_subscription_button": {} },
{ "extend_consumable_button@realms_settings.extend_consumable_button": {} },
{ "renew_consumable_button@realms_settings.renew_consumable_button": {} },
{
"_0": {
"type": "panel",
"size": [ 0, 2 ]
}
},
{ "open_realm_button@realms_settings.open_realm_button": {} },
{ "close_realm_button@realms_settings.close_realm_button": {} },
{
"_1": {
"type": "panel",
"size": [ 0, 2 ]
}
}
],
"bindings": [
{
"binding_name": "#realms_subscription_info_visible",
"binding_name_override": "#visible"
}
]
}
}
]
},
//---------------------------------------------------------------------------
// Branches Section
//---------------------------------------------------------------------------
"label_text": {
"type": "label",
"color": "$light_button_default_text_color",
"text": "",
"font_size": "normal",
"anchor_to": "top_left",
"anchor_from": "top_left"
},
"branch_grid_item_content": {
"type": "stack_panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"orientation": "vertical",
"size": [ "100%", 29 ],
"offset": [ 5, 4 ],
"controls": [
{
"branch_text@label_text": {
"text": "#branch_name",
"size": [ "100% - 8px", 10 ],
"color": "$text_color",
"bindings": [
{
"binding_name": "#branch_name",
"binding_type": "collection",
"binding_collection_name": "$collection_binding_name"
}
]
}
},
{
"commit_text@label_text": {
"text": "#commit_id",
"size": [ "100% - 8px", 10 ],
"color": "$text_color",
"bindings": [
{
"binding_name": "#commit_id",
"binding_type": "collection",
"binding_collection_name": "$collection_binding_name"
}
]
}
}
]
},
"branch_item_template": {
"type": "panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"size": [ "100%", 29 ],
"controls": [
{
"branch_item_button@common_buttons.light_content_button": {
"$pressed_button_name": "select_realm_branch",
"size": [ "100%", 29 ],
"$button_content": "realms_settings.branch_grid_item_content",
"bindings": [
{
"binding_type": "collection_details",
"binding_collection_name": "$collection_binding_name"
}
]
}
}
]
},
"branches_grid": {
"type": "grid",
"size": [ "100%", "default" ],
"grid_item_template": "realms_settings.branch_item_template",
"grid_dimension_binding": "#realms_branch_grid_dimension",
"$collection_binding_name": "realms_branch_collection",
"collection_name": "realms_branch_collection",
"anchor_to": "top_left",
"anchor_from": "top_left",
"bindings": [
{
"binding_name": "#realms_branch_grid_dimension"
}
]
},
"branch_set_panel": {
"type": "stack_panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"orientation": "vertical",
"size": "$branch_panel_size",
"controls": [
{
"set_branch_version_label@label_text": {
"text": "realmsSettingsScreen.dev_current_version_label",
"color": "$main_header_text_color",
"size": [ "100% - 8px", 10 ]
}
},
{
"set_branch_id_label@label_text": {
"text": "#selected_branch_commit_id",
"color": "$main_header_text_color",
"size": [ "100% - 8px", 10 ],
"bindings": [
{
"binding_name": "#selected_branch_commit_id"
}
]
}
}
]
},
"version_filter_text_box@common.text_edit_box": {
"size": [ "100%", 25 ],
"$text_box_name": "#version_filter_text_box",
"max_length": 30
},
"branch_page_panel": {
"type": "panel",
"size": [ "100%", 20 ],
"controls": [
{
"prev_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.dev_prev_page_label",
"$pressed_button_name": "prev_page_button",
"anchor_from": "top_left",
"anchor_to": "top_left",
"size": [ 70, "100%" ],
"bindings": [
{
"binding_name": "#prev_button_visible",
"binding_name_override": "#visible"
}
]
}
},
{
"page_text@label_text": {
"text": "#page_index_text",
"color": "$sub_header_text_color",
"anchor_from": "center",
"anchor_to": "center",
"size": [ "default", "50%" ],
"bindings": [
{
"binding_name": "#page_index_text"
}
]
}
},
{
"next_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.dev_next_page_label",
"$pressed_button_name": "next_page_button",
"anchor_from": "top_right",
"anchor_to": "top_right",
"size": [ 70, "100%" ],
"bindings": [
{
"binding_name": "#next_button_visible",
"binding_name_override": "#visible"
}
]
}
}
]
},
"branches_panel": {
"type": "stack_panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"orientation": "vertical",
"size": "$branch_panel_size",
"controls": [
{ "branch_label@branch_label": {} },
{ "version_filter_text_box@version_filter_text_box": {} },
{ "branch_set_panel@branch_set_panel": {} },
{ "branches_grid@branches_grid": {} },
{
"spacing_gap": {
"type": "panel",
"size": [ "100%", 10 ]
}
},
{ "branch_page_panel@branch_page_panel": {} }
]
},
"branch_section": {
"type": "stack_panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"orientation": "vertical",
"$branch_panel_size": [ "100% - 1px", "100%c" ],
"size": [ "100%", "100%c" ],
"controls": [
{ "branches_panel@branches_panel": {} }
]
},
"branch_label@settings_common.selector_group_label": { //exp-todo remove, temp setting for clubid
"offset": [ 2, 0 ],
"text": "Which commit should realm run on?",
"layer": 2
},
// test content
"test_content": {
"type": "panel",
"controls": [
{ "realms_whitelist_content_panel@realms_whitelist.realms_whitelist_content_panel": { "layer": 1 } },
{ "gamepad_helpers@realms_whitelist.gamepad_helpers": {} }
]
},
// Left side
"selector_panel": {
"type": "stack_panel",
"orientation": "vertical",
"anchor_from": "top_left",
"anchor_to": "top_left",
"size": [ "100%", "100%c + 4px" ],
"$default_selector_toggle_index": 1,
"$world_toggle_index|default": 1,
"$members_toggle_index|default": 2,
"$subscription_toggle_index|default": 3,
"$dev_options_toggle_index|default": 4,
"controls": [
{
"play_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.playRealmButton",
"$pressed_button_name": "play_world_button",
"size": [ "100%", "30px" ],
"bindings": [
{
"binding_name": "#play_button_visible",
"binding_name_override": "#visible"
}
]
}
},
{
"disabled_play_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.playDisabledRealmButton",
"$pressed_button_name": "play_world_button",
"size": [ "100%", "30px" ],
"bindings": [
{
"binding_name": "#disabled_play_button_visible",
"binding_name_override": "#visible"
},
{
"binding_name": "#play_button_visible", // a hack: you cannot set "enabled":false directly on a ui control
"binding_name_override": "#enabled"
}
]
}
},
{
"expired_play_button@settings_common.action_button": {
"$button_text": "realmsSettingsScreen.playExpiredRealmButton",
"$pressed_button_name": "play_world_button",
"size": [ "100%", "30px" ],
"bindings": [
{
"binding_name": "#is_realm_expired",
"binding_name_override": "#visible"
},
{
"binding_name": "#play_button_visible", // a hack: you cannot set "enabled":false directly on a ui control
"binding_name_override": "#enabled"
}
]
}
},
{
"padding": {
"type": "panel",
"size": [ "100%", 6 ]
}
},
{
"selector_group_label@settings_common.selector_group_label": {
"offset": [ 2, 0 ],
"text": "realmsSettingsScreen.selectorSectionLabelRealm",
"layer": 2
}
},
{
"world_button@settings_common.section_toggle_base": {
"$toggle_view_binding_name": "world_button_toggle",
"$toggle_group_forced_index": "$world_toggle_index",
"$glyph_texture": "textures/ui/world_glyph",
"$glyph_color_texture": "textures/ui/world_glyph_color",
"$glyph_size": [ 16, 17 ],
"layer": 1,
"$button_text": "realmsSettingsScreen.gameSectionTitle",
"$toggle_property_bag": {
"#panel_title": "realmsSettingsScreen.gameSectionTitle"
}
}
},
{
"members_button@settings_common.section_toggle_base": {
"$toggle_view_binding_name": "members_button_toggle",
"$toggle_group_forced_index": "$members_toggle_index",
"$glyph_texture": "textures/ui/multiplayer_glyph",
"$glyph_color_texture": "textures/ui/multiplayer_glyph_color",
"$glyph_size": [ 22, 12 ],
"layer": 2,
"$button_text": "realmsSettingsScreen.membersSectionTitle",
"$toggle_property_bag": {
"#panel_title": "realmsSettingsScreen.membersSectionTitle"
}
}
},
{
"subscription_button@settings_common.section_toggle_base": {
"$toggle_view_binding_name": "subscription_button_toggle",
"$toggle_group_forced_index": "$subscription_toggle_index",
"$glyph_texture": "textures/ui/subscription_glyph",
"$glyph_color_texture": "textures/ui/subscription_glyph_color",
"$glyph_size": [ 15, 13 ],
"layer": 3,
"$button_text": "realmsSettingsScreen.subscriptionSectionTitle",
"$toggle_property_bag": {
"#panel_title": "realmsSettingsScreen.subscriptionSectionTitle"
}
}
},
{
"dev_options_button@settings_common.section_toggle_base": {
"ignored": "$non_config_realms_env",
"$toggle_view_binding_name": "dev_options_button_toggle",
"$toggle_group_forced_index": "$dev_options_toggle_index",
"$glyph_texture": "textures/ui/dev_glyph",
"$glyph_color_texture": "textures/ui/dev_glyph_color",
"$glyph_size": [ 14, 14 ],
"layer": 4,
"$button_text": "realmsSettingsScreen.devOptionsSectionTitle",
"$toggle_property_bag": {
"#panel_title": "realmsSettingsScreen.devOptionsSectionTitle"
}
}
}
]
},
// right side
"section_content_panels": {
"type": "panel",
"anchor_from": "top_left",
"anchor_to": "top_left",
"size": [ "100%", "100%c" ],
"controls": [
{
"world_section@realms_settings.generic_section_wrapper": {
"$section_button_name|default": "world_button_toggle",
"$section_content_name|default": "realms_world_section.panel_content"
}
},
{
"players_section@realms_settings.generic_section_wrapper": {
"$section_button_name|default": "members_button_toggle",
"$section_content_name|default": "realms_whitelist.friends_panel",
"$friend_panel_size": [ "100%", "100%c" ]
}
},
{
"subscription_section@realms_settings.generic_section_wrapper": {
"$section_button_name|default": "subscription_button_toggle",
"$section_content_name|default": "realms_settings.subscriptions_section"
}
},
{
"dev_options_section@realms_settings.generic_section_wrapper": {
"ignored": "$non_config_realms_env",
"$section_button_name|default": "dev_options_button_toggle",
"$section_content_name|default": "branch_section"
}
}
]
}
}