1
mirror of https://github.com/thepeacockproject/Peacock synced 2024-11-22 22:12:45 +01:00
Peacock/static/PlayNextTemplate.json
Reece Dunham 6245e91624 Initial commit
Co-authored-by: Tino Roivanen <tino.roivanen98@gmail.com>
Co-authored-by: Govert de Gans <grappigegovert@hotmail.com>
Co-authored-by: Gray Olson <gray@grayolson.com>
Co-authored-by: Alexandre Sanchez <alex73630@gmail.com>
Co-authored-by: Anthony Fuller <24512050+anthonyfuller@users.noreply.github.com>
Co-authored-by: atampy25 <24306974+atampy25@users.noreply.github.com>
Co-authored-by: David <davidstulemeijer@gmail.com>
Co-authored-by: c0derMo <c0dermo@users.noreply.github.com>
Co-authored-by: Jeevat Singh <jeevatt.singh@gmail.com>
Signed-off-by: Reece Dunham <me@rdil.rocks>
2022-10-19 21:33:45 -04:00

273 lines
20 KiB
JSON

{
"id": "playnext_data_container",
"controller": "list",
"direction": "horizontal",
"data": {
"direction": "horizontal"
},
"children": {
"$each $.Categories": {
"$if $gt ($arraysize $.Items,0)": {
"$then": {
"$switch $.CategoryType": [
{
"case": "NextMission",
"return": {
"id": "playnext_data_categories",
"controller": "list",
"view": "menu3.containers.ListContainerWithHeader",
"direction": "horizontal",
"pressable": false,
"selectable": true,
"data": {
"direction": "horizontal",
"headlinetitle": "$loc $.CategoryName"
},
"children": {
"$each $.Items": {
"$if $eqs ($.ContentType,Contract)": {
"$then": {
"id": "element",
"view": "menu3.basic.MenuTileLarge",
"pressable": true,
"selectable": true,
"data": {
"title": "$loc $.Content.UserCentricContract.Contract.Metadata.Title",
"image": "$res $.Content.UserCentricContract.Contract.Metadata.TileImage",
"header": "$loc UI_PLAYNEXT_CONTINUE_STORY_TITLE",
"icon": "arrowright"
},
"actions": {
"select": {
"replace-children": {
"target": "headline_container",
"children": [
{
"view": "menu3.basic.HeadlineElement",
"selectable": false,
"pressable": false,
"data": {
"title": "$loc $.Content.UserCentricContract.Contract.Metadata.Title",
"header": "$loc UI_PLAYNEXT_CONTINUE_STORY_TITLE",
"icon": "arrowright"
}
}
]
}
},
"deselect": {
"replace-children": {
"target": "headline_container",
"children": []
}
},
"accept": {
"$setup": {
"$set CampaignName": "$.Content.CampaignInfo.CampaignName",
"$set ContractId": "$.Content.ContractId",
"$set IntroVideoId": "$.Content.CampaignInfo.IntroVideoId",
"$in": {
"set-persistent-context": {
"$if $not $isnull $.IntroVideoId": {
"$then": {
"target": "hub",
"actions": [
{
"show-background-layers": {
"show-background": false
}
},
{
"set-selected": {
"target": "category_story"
}
},
{
"set-selected": {
"target": "$formatstring story_category_{$.CampaignName}"
}
},
{
"trigger-input": {
"action": "accept"
}
},
{
"set-selected": {
"target": "$formatstring video-tile-{$.IntroVideoId}"
}
},
{
"set-background": ""
},
{
"trigger-input": {
"action": "accept"
}
},
{
"set-selected": {
"target": "$formatstring story-tile-{$.ContractId}"
}
},
{
"show-background-layers": {
"show-background": true
}
}
]
},
"$else": {
"target": "hub",
"actions": [
{
"show-background-layers": {
"show-background": false
}
},
{
"set-selected": {
"target": "category_story"
}
},
{
"set-selected": {
"target": "$formatstring story_category_{$.CampaignName}"
}
},
{
"trigger-input": {
"action": "accept"
}
},
{
"set-selected": {
"target": "$formatstring story-tile-{$.ContractId}"
}
},
{
"set-background": ""
},
{
"trigger-input": {
"action": "accept"
}
},
{
"show-background-layers": {
"show-background": true
}
}
]
}
}
},
"exit-to-main-menu": {}
}
}
}
}
},
"$else": null
}
}
}
}
},
{
"case": "Matchmaking",
"return": {
"id": "playnext_data_category_matchmaking",
"controller": "list",
"view": "menu3.containers.ListContainer",
"direction": "horizontal",
"pressable": false,
"selectable": true,
"data": {
"direction": "horizontal"
},
"children": {
"$each $.Items": {
"$if $eqs ($.ContentType,Matchmaking)": {
"$then": {
"id": "element",
"view": "menu3.basic.MenuTileLarge",
"pressable": true,
"selectable": true,
"data": {
"title": "$loc UI_MENU_PAGE_HUB_GAMEMODE_NEWMODE",
"image": "$res images/gamemodes/tile_multiplayer_matchmaking.jpg",
"header": "$loc UI_MENU_PAGE_HUB_GAMEMODES",
"icon": "arrowright"
},
"actions": {
"select": {
"replace-children": {
"target": "headline_container",
"children": [
{
"view": "menu3.basic.HeadlineElement",
"selectable": false,
"pressable": false,
"data": {
"title": "$loc UI_MENU_PAGE_HUB_GAMEMODE_NEWMODE",
"header": "$loc UI_MENU_PAGE_HUB_GAMEMODES",
"icon": "arrowright"
}
}
]
}
},
"deselect": {
"replace-children": {
"target": "headline_container",
"children": []
}
},
"accept": {
"set-persistent-context": {
"target": "hub",
"actions": [
{
"set-selected": {
"target": "category_gamemodes"
}
},
{
"set-selected": {
"target": "gamemodes_category_newgamemode_multiplayerpage"
}
},
{
"trigger-input": {
"action": "accept"
}
},
{
"set-selected": {
"target": "$formatstring preset_matchmaking_{$.Content.Id}"
}
}
]
},
"exit-to-main-menu": {}
}
}
},
"$else": null
}
}
}
}
},
{
"default": null
}
]
},
"$else": null
}
}
}
}