创建测试光盘
注意
这些说明仅用于测试目的。 对于零售方案,根据合作伙伴中心中的元数据对此数据进行自动配置。 在流中为创建编译光盘选择的选项用于控制安装顺序、自动播放等。 当提交您的游戏以便用于引入时,并没有将测试元数据或 JSON 配置文件直接提交给我们。
本主题介绍如何创建测试光盘。 可以创建下列类型的测试光盘。
编译
创建测试编译光盘
要创建和测试编译某一光盘,您需要按如下所述创建一个 catalog.js 元数据文件和一个光盘布局。
创建光盘布局
创建如以下示例所示的光盘布局。
- Disc Root
- Licenses (folder) - (Not needed for Xbox One ERA Development Kits - make sure to use XVCs created with /LT flag)
License0.xml (file) - (Not needed for Xbox One ERA dev kits - make sure to use XVCs created with /LT flag)
- MSXC (folder)
- Package1.xvc (file)
- Package2.xvc (file)
- Metadata (folder)
- catalog.js (file)
- Bundle (folder)
- Bundle images (files)
- Package1.xvc (folder)
- Package 1 images (files)
- Package2.xvc (folder)
- Package 2 images (files)
其中的目录具有以下内容:
Licenses 包含游戏的许可证文件。 Xbox One ERA 开发工具包不需要此信息。 请确保使用通过 /LT 标志创建的 XVC。 之后,可以忽略它们。
MSXC 包含 Xbox shell 使用的打包的游戏和元数据。
Metadata 包含 shell 用于光盘中的游戏和游戏包的元数据。
Bundle 包含 shell 使用的图像。
Package1.XVC 包含 shell 用于第一个游戏的图像。 名称必须匹配 MSXC 中游戏包文件的名称。
Package2.XVC 包含 shell 用于第二个游戏的图像。 名称必须匹配 MSXC 中游戏包文件的名称。
Catalog.js
在 Metadata 文件夹中,创建一个名为 catalog.js 的文件。 编辑该文件以反映您的程序包的名称以及其他文件夹中的图像。 此文件必须是 UTF-16 LE 编码的。 我们建议在网上使用 JSON 验证程序。 若要确保 JSON 是有效的,请将其复制到文本编辑器中,然后以 UTF-16 LE 格式保存该文件。
针对多人游戏方案的 catalog.js 文件的示例,带有注释
{
"version": "4.1", // Don't adjust this value.
"bundle": {
"oneStoreProductId": "9P436MXJ71GV", // Replace with your bundle product id.
"titles": [
{
"locale": "default",
"title": "Bundle Title" // Replace with bundle title.
}
],
"images": [
{
"size": "100x100", // Don't change the size values.
"image": "100x100_1.png" // Must match the image file names in MSXC\Metadata\Bundle\
},
{
"size": "208x208",
"image": "208x208_1.png"
},
{
"size": "480x480",
"image": "480x480_1.png"
}
]
},
"packages": [ // This is an array of packages.
{
"packageName": "Package1.xvc", // Match your package name in MSXC\<package name> and MSXC\Metdata\<package name>
"oneStoreProductId": "BX38WRFV50MJ", // Product id for package 1.
"contentId": "2b05043b-4043-4ba0-80ed-fd4811c4b333", // Content id for package 1. Must match the content id of the package file.
"franchiseGameHubId": "47445142-3636-3036-C048-464D4E574000", // Optional; Replace with the FranchiseGameHubId. This marks the package as a game hub
"titleId": "037C3A1D", // Title id for package 1.
"titles": [
{
"locale": "default",
"title": "Killer Instinct" // Package 1 title.
}
],
"images": [
{
"size": "100x100",
"image": "100x100_1.png" // Match file names in MSXC\Metadata\<Package1>\
},
{
"size": "208x208",
"image": "208x208_1.png"
},
{
"size": "480x480",
"image": "480x480_1.png"
}
],
"ratings": [
{
"system": "OFLC",
"value": "M"
},
{
"system": "DJCTQ",
"value": "14"
},
{
"system": "PCBP",
"value": "Unrated"
},
{
"system": "USK",
"value": "16"
},
{
"system": "ESRB",
"value": "T"
},
{
"system": "CERO",
"value": "Unrated"
},
{
"system": "CSRR",
"value": "Unrated"
},
{
"system": "COB",
"value": "M"
},
{
"system": "GRB",
"value": "Unrated"
},
{
"system": "PEGI",
"value": "16"
},
{
"system": "PEGIPortugal",
"value": "Unrated"
}
],
"type": "Game"
},
{
"packageName": "Package2.xvc",
"oneStoreProductId": "BVC818MXZ6KG",
"contentId": "4a6cb1d0-5ad3-47b7-9583-7480098b4a26",
"associatedFranchiseGameHubId": "47445142-3636-3036-C048-464D4E574000", // Replace with the FranchiseGameHubId of the corresponding franchise game hub that this package is launched with. Optional;
"titleId": "669E1864",
"titles": [
{
"locale": "default",
"title": "LocoCycle"
}
],
"images": [
{
"size": "100x100",
"image": "100x100_1.png"
},
{
"size": "208x208",
"image": "208x208_1.png"
},
{
"size": "480x480",
"image": "480x480_1.png"
}
],
"ratings": [
{
"system": "OFLC",
"value": "PG"
},
{
"system": "DJCTQ",
"value": "10"
},
{
"system": "USK",
"value": "12"
},
{
"system": "ESRB",
"value": "T"
},
{
"system": "PEGI",
"value": "12"
},
{
"system": "COB",
"value": "PG"
}
],
"type": "Game"
}
]
}
针对游戏 + 可下载内容 (DLC) 方案的 catalog.js 的示例
{
"version": "4.0", // Don't adjust this value.
"bundle": {
"oneStoreProductId": "9P436MXJ71GV", // Replace with bundle product id.
"launchPackage": "Package3.xvc", // Should be the package name of the game package. This is the package that is launched when the game disc is inserted.
"titles": [
{
"locale": "default",
"title": "Game + DLC Bundle Title" // Replace with bundle name.
}
],
"images": [
{
"size": "100x100",
"image": "100x100_1.png" // Must match the image file names in MSXC\Metadata\Bundle\
},
{
"size": "208x208",
"image": "208x208_1.png"
},
{
"size": "480x480",
"image": "480x480_1.png"
}
]
},
"packages": [
{
"packageName": "Package1.xvc", // Match folder name in MSXC\Metadata\<folder name>
"oneStoreProductId": "BX38WRFV50MJ", // Replace with DLC 1 product id.
"contentId": "ace6ef3b-0c5b-4f17-a651-390e75169d5c", // Replace with DLC 1 content id. This must match the content id of the package file.
"allowedOneStoreProductIds": [
"BVC818MXZ6KG" // Should match the product id of the game that will load this DLC.
],
"titles": [
{
"locale": "default",
"title": "DLC Title 1"
}
],
"images": [
{
"size": "100x100",
"image": "100x100_1.png" // Match file names in MSXC\Metadata\Package1.xvc\
},
{
"size": "208x208",
"image": "208x208_1.png"
},
{
"size": "480x480",
"image": "480x480_1.png"
}
],
"ratings": [
{
"system": "ESRB",
"value": "E"
}
],
"type": "Durable" // Indicates that this is a DLC package.
},
{
"packageName": "Package2.xvc",
"oneStoreProductId": "9P436MXJ71GV",
"contentId": "b0f77189-d74c-4005-b351-955d380cb875",
"allowedOneStoreProductIds": [
"BVC818MXZ6KG"
],
"titles": [
{
"locale": "en-US",
"title": "DLC Title 2"
}
],
"images": [
{
"size": "100x100",
"image": "100x100_1.png"
},
{
"size": "208x208",
"image": "208x208_1.png"
},
{
"size": "480x480",
"image": "480x480_1.png"
}
],
"ratings": [
{
"system": "ESRB",
"value": "E"
}
],
"type": "Durable"
},
{
"packageName": "Package3.xvc",
"oneStoreProductId": "BVC818MXZ6KG",
"contentId": "5519355c-bff9-40b4-92bb-b5473fd9c577",
"titleId": "35c8f637",
"titles": [
{
"locale": "default",
"title": "Game Title"
}
],
"images": [
{
"size": "100x100",
"image": "100x100_1.png"
},
{
"size": "208x208",
"image": "208x208_1.png"
},
{
"size": "480x480",
"image": "480x480_1.png"
}
],
"ratings": [
{
"system": "ESRB",
"value": "E"
}
],
"type": "Game" // Indicates main game package.
}
]
}
安装顺序和通知
在一个 DLC 程序包完成某个安装时,通常将触发 DLC 安装通知。 对于某些类型的游戏光盘,有时候的表现并不是您所期望的,因为这会在很短的时间内创建大量通知。 例如,Game of the Year(年度游戏)版本可能在光盘上包括大量的小 DLC 程序包。要处理此情形,仅在已安装它们应用于的游戏时才触发针对 DLC 的通知。
对于具有大量小 DLC 程序包的游戏,我们建议对光盘上的程序包进行排序,以便在游戏前安装 DLC。 这可确保用户在安装 DLC 程序包时,不会对相关的通知应接不暇。
对于具有少量大 DLC 程序包的游戏,我们建议在主游戏后安装 DLC,以便确保在安装了所有 DLC 程序包之前,不会阻止用户玩游戏。
要控制安装 DLC 和游戏的顺序,只需在 catalog.js 的 Packages JSON 数组中调整其顺序。 该数组用于控制安装的默认顺序。
部署
要部署编译光盘,请将目录结构刻录到一个光盘。在您将该光盘插入某一开发工具包后,该光盘会启动,就像发布版本在零售主机上启动一样。
多光盘
要创建测试多光盘,请将您的现有 XVC 拆分为两个文件。
注意
XVC 只能在单个区块边界上拆分,如 Layout.xml 文件中定义。 具有极大区块(大于 45 GB)的 XVC 可能无法通过使用多光盘设备发布。 通常,最好将您的游戏的区块保持小于 45 GB。
要跨两个光盘拆分一个 XVC,应创建一个与以下类似的 DiscLayout.xml 文件。
<Packages>
<Package Name="MultiDisc" Description="Package published on 2 discs" MaxDiscs="2">
</Package>
</Packages>
接下来,调用 SplitPkg 以便生成将刻录到光盘的单独文件。这将生成两个文件,这两个文件具有您的原始 XVC 文件名,并且分别以“.MultiDisc.1”和“.MultiDisc.2”作为后缀。
SplitPkg /f DiscLayout.xml /p sourceXVC /s Multidisc /pd outputDir
要模拟从多个光盘进行的安装,请将 xbapp install
用于光盘 1,将 xbapp install
用于光盘 2。 在安装了光盘 1 上的内容后,主机将提示您插入光盘 2。
Catalog.js
要刻录这些测试光盘,请创建一个 Catalog.js 文件,该文件具有新的 discNumber、discCount 和 discSetId 字段。 请注意,每一个光盘都需要所有这些元数据; 各光盘上 Catalog.js 文件中的唯一差异是 discNumber 字段的值。 例如,光盘 1 应具有值 1,光盘 2 应具有值 2。 0 是保留值且不应使用。
针对多光盘的 Catalog.js 的示例
{
"version": "4.0", // Don't adjust this value.
"discNumber": 1, // 1 for disc 1, 2 for disc 2.
"discCount": 2, // Same on all discs.
"discSetId": "00000001", // For test purposes, this can be 00000001. On retail discs, this value is unique for each published disc set.
// Don't mix installations of test discs from different sets if they share this value. Cancel your installation before starting a new one.
"packages": [ // This is an array of packages.
{
"packageName": "Package1.xvc", // Match your package name in MSXC\package-name and MSXC\Metdata\package-name
"oneStoreProductId": "BX38WRFV50MJ", // Product id for package 1.
"contentId": "2b05043b-4043-4ba0-80ed-fd4811c4b333", // Content id for package 1. Must match the content id of the package file.
"titleId": "037C3A1D", // Title id for package 1.
"titles": [
{
"locale": "default",
"title": "Killer Instinct" // Package 1 title.
}
],
"images": [
{
"size": "100x100",
"image": "100x100_1.png" // Match file names in MSXC\Metadata\Package1\
},
{
"size": "208x208",
"image": "208x208_1.png"
},
{
"size": "480x480",
"image": "480x480_1.png"
}
],
"ratings": [
{
"system": "OFLC",
"value": "M"
},
{
"system": "DJCTQ",
"value": "14"
},
{
"system": "PCBP",
"value": "Unrated"
},
{
"system": "USK",
"value": "16"
},
{
"system": "ESRB",
"value": "T"
},
{
"system": "CERO",
"value": "Unrated"
},
{
"system": "CSRR",
"value": "Unrated"
},
{
"system": "COB",
"value": "M"
},
{
"system": "GRB",
"value": "Unrated"
},
{
"system": "PEGI",
"value": "16"
},
{
"system": "PEGIPortugal",
"value": "Unrated"
}
],
"type": "Game"
}
]
}