Difference between revisions of "NAND游戏存档格式"

From 3dbrew
Jump to navigation Jump to search
(translate 60% eng.ver http://3dbrew.org/w/index.php?title=Config_Savegame&oldid=8463)
 
(translate fin.)
 
Line 1: Line 1:
本页介绍 [[Config_Services|Cfg]] [[System_SaveData|NAND]] [游戏存档]的格式.这些块可以通过CFG服务命令来访问。
+
本页介绍 [[Config_Services|Cfg]] [[System_SaveData|NAND]] [[游戏存档]]的格式.这些块可以通过CFG服务命令来访问。
  
 
==存档文件 "/config" 的结构==
 
==存档文件 "/config" 的结构==
Line 27: Line 27:
 
/config文件的大小为 0x8000 byte
 
/config文件的大小为 0x8000 byte
  
==块入口的结构 ==
+
==设置块入口 ==
 
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"
 
|-
 
|-
Line 40: Line 40:
 
| 0x4
 
| 0x4
 
| 0x4
 
| 0x4
| Offset to the data for this block when size is >4, otherwise this word is the data for this block.
+
| 大小>4时,是这个快的数据的偏移, 否则是这个块的数据的word.
 
|-
 
|-
 
| 0x8
 
| 0x8
 
| 0x2
 
| 0x2
| Size
+
| 大小
 
|-
 
|-
 
| 0xA
 
| 0xA
 
| 0x2
 
| 0x2
| Flags
+
| 标志位
 
|}
 
|}
  
==Configuration blocks==
+
==设置块==
 
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"
 
|-
 
|-
 
!  BlkID
 
!  BlkID
Size
+
大小
Flags
+
标志位
Description
+
说明
 
|-
 
|-
 
| 0x00090000
 
| 0x00090000
 
| 0x8
 
| 0x8
 
| 0x2?
 
| 0x2?
| This contains a u64 ID, used by processes using [[NWMUDS:Initialize]]. The first word is the same as [[CfgS:GetLocalFriendCodeSeed|LocalFriendCodeSeed]], while the latter is a separate random word.
+
| 包含一个u64 ID, 进程通过 [[NWMUDS:Initialize]] 使用. 第一个字和[[CfgS:GetLocalFriendCodeSeed|LocalFriendCodeSeed]]相同, 后边一个字是一个独立的随机字.
 
|-
 
|-
 
| 0x00090001
 
| 0x00090001
 
| 0x8
 
| 0x8
 
| 0xE
 
| 0xE
| This console-unique u64 used by [[Cfg:GenHashConsoleUnique|GenHashConsoleUnique]] is generated with the LocalFriendCodeSeed and with random data.
+
| [[Cfg:GenHashConsoleUnique|GenHashConsoleUnique]]使用的console-unique u64,由 LocalFriendCodeSeed和随机数生成.
 
|-
 
|-
 
| 0x000A0000
 
| 0x000A0000
 
| 0x1C
 
| 0x1C
 
| 0xE
 
| 0xE
| See below.
+
| 往下看吧.
 
|-
 
|-
 
| 0x000A0002
 
| 0x000A0002
 
| 0x1
 
| 0x1
 
| 0xA
 
| 0xA
| Language
+
| 语言
 
|-
 
|-
 
| 0x000B0000
 
| 0x000B0000
 
| 0x4
 
| 0x4
 
| 0x8
 
| 0x8
| CountryInfo
+
| 国家信息
 
|-
 
|-
 
| 0x000F0000
 
| 0x000F0000
 
| 0x10
 
| 0x10
 
| 0x8?
 
| 0x8?
| Unknown, used by [[NS]] on dev-units for [[SVC|svcKernelSetState]], where Type is 6.
+
| 未知,dev-units的 [[NS]]使用[[SVC|svcKernelSetState]]时 Type为6.
 
|-
 
|-
 
| 0x00110000
 
| 0x00110000
 
| 0x4
 
| 0x4
 
| ?
 
| ?
| The low u16 indicates whether the system setup is required, such as when the system is booted for the first time or after doing a [[System Settings|System Format]]: 0 = setup required, non-zero = no setup required.
+
| 低U16指示是否需要进行系统设置.比如系统第一次启动时会做一次[[System Settings|System Format]]: 0=需要设置,非0=无需设置
 
|-
 
|-
 
| 0x00110001
 
| 0x00110001
 
| 0x8
 
| 0x8
 
| 0xA?
 
| 0xA?
| TitleID of the menu to launch, used by [[NS]] on dev units. (This block can be edited on dev units with [[3DS Development Unit Software#Config|Config]])
+
| dev units的[[NS]]用于主画面载入的TitleID . (这个快可以在 dev units使用 [[3DS Development Unit Software#Config|Config]]编辑)
 
|}
 
|}
  
The dev unit TID block only exists on dev units.
+
dev unit TID block仅存在于dev units.
  
 
===语言===
 
===语言===
Line 168: Line 168:
 
|-
 
|-
 
| 0x0-0x13
 
| 0x0-0x13
| UTF-16 username, with no NULL-terminator.
+
| UTF-16用户名, 结尾没有NULL标志.
 
|-
 
|-
 
| 0x14-17
 
| 0x14-17

Latest revision as of 12:07, 31 January 2014

本页介绍 Cfg NAND 游戏存档的格式.这些块可以通过CFG服务命令来访问。

存档文件 "/config" 的结构[edit]

偏移 长度 说明
0x0 0x2 总入口
0x2 0x2 ?
0x4 0x4558 块入口
0x455C 入口数据

/config文件的大小为 0x8000 byte

设置块入口[edit]

偏移 大小 说明
0x0 0x4 BlkID
0x4 0x4 大小>4时,是这个快的数据的偏移, 否则是这个块的数据的word.
0x8 0x2 大小
0xA 0x2 标志位

设置块[edit]

BlkID 大小 标志位 说明
0x00090000 0x8 0x2? 包含一个u64 ID, 进程通过 NWMUDS:Initialize 使用. 第一个字和LocalFriendCodeSeed相同, 后边一个字是一个独立的随机字.
0x00090001 0x8 0xE GenHashConsoleUnique使用的console-unique u64,由 LocalFriendCodeSeed和随机数生成.
0x000A0000 0x1C 0xE 往下看吧.
0x000A0002 0x1 0xA 语言
0x000B0000 0x4 0x8 国家信息
0x000F0000 0x10 0x8? 未知,dev-units的 NS使用svcKernelSetState时 Type为6.
0x00110000 0x4 ? 低U16指示是否需要进行系统设置.比如系统第一次启动时会做一次System Format: 0=需要设置,非0=无需设置
0x00110001 0x8 0xA? dev units的NS用于主画面载入的TitleID . (这个快可以在 dev units使用 Config编辑)

dev unit TID block仅存在于dev units.

语言[edit]

ID 说明
0 ja
1 en
2 fr
3 de
4 it
5 es
6 zh
7 ko
8 nl
9 pt
10 ru

国家信息[edit]

Byte 说明
0 ?
1 ?
2 ?
3 国家代码,和DSi/Wii国家代码相同.值为0xff时无效.

0x000A0000 Block[edit]

Byte 说明
0x0-0x13 UTF-16用户名, 结尾没有NULL标志.
0x14-17 通常为0?
0x18-0x1B ?