ACTU:GetAccountDataBlock: Difference between revisions

m Use field names from account.dat
TimmSkiller (talk | contribs)
No edit summary
 
(2 intermediate revisions by one other user not shown)
Line 1: Line 1:
=Request=
=Request=
{| class="wikitable" border="1"
{{IPC/Request}}
|-
{{IPC/RequestHeader|0x0006|3|2}}
!  Index Word
{{IPC/RequestEntry|u8, Account slot (0xFE for default)}}
!  Description
{{IPC/RequestEntry|Output buffer size}}
|-
{{IPC/RequestEntry|Account data type}}
| 0
{{IPC/MapPointerW|Output buffer}}
| Header code [0x000600C2]
{{IPC/RequestEnd}}
|-
| 1
| u8 Account index (0xFE to use current account)
|-
| 2
| Size
|-
| 3
| BlkID
|-
| 4
| (Size<<4)  <nowiki>|</nowiki> 12
|-
| 5
| Output buffer ptr
|}


=Response=
=Response=
{| class="wikitable" border="1"
{{IPC/Request}}
|-
{{#vardefine:ipc_offset|0}}
!  Index Word
{{IPC/RequestHeader|0x0006|1|2}}
!  Description
{{IPC/RequestEntry|Result code}}
|-
{{IPC/MapPointerW|Output buffer}}
| 0
{{IPC/RequestEnd}}
| Header code
|-
| 1
| Result code
|}


=Description=
=Description=
This returns NNID account info from account.dat
Returns information associated to the account specified by the account slot.


=DataBlocks=
See [[ACT_Services#DataBlocks|DataBlocks]] for possible data types.
 
{| class="wikitable" border="1"
|-
!  BlkID
!  Size
!  Description
|-
| 0x5
| 0x4
| PersistentId
|-
| 0x6
| 0x8
| TransferableIdBase
|-
| 0x7
| 0x60
| [[Mii#Mii_format|MiiData]]
|-
| 0x8
| 0x11
| AccountId (ASCII NUL-terminated Nintendo Network ID)
|-
| 0xA
| 0x4
| Birthday {u16 year; u8 month; u8 day;}
|-
| 0xB
| 0x3
| ASCII NUL-terminated Country Name
|-
| 0xC
| 0x4
| PrincipalId
|-
| 0xE
| 0x1
| ?
|-
| 0xF
| 0x1
| ?
|-
| 0x11
| 0xA0
| struct{u32 PersistentID; u32 padding; u64 TransferableIDBase; u8[0x60] MiiData; char16_t[0xB] MachinUserName?; char[0x11] AccountID; u8 padding; struct{u16 year; u8 month; u8 day;}Birthday; u32 PrincipalID;}
|-
| 0x12
| 0x4
| ?
|-
| 0x13
| 0x1
| Gender
|-
| 0x14
| 0x1
| ?
|-
| 0x15
| 0x11
| AccountId? (ASCII NUL-terminated Nintendo Network ID)
|-
| 0x16
| 0x1
| ParentalControlSlotNo
|-
| 0x17
| 0x4
| SimpleAddressId ([[Config_Savegame#CountryInfo|CountryInfo]])
|-
| 0x19
| 0x8
| UtcOffset
|-
| 0x1A
| 0x1
| ?
|-
| 0x1B
| 0x16
| (NUL-terminated?) UTF-16 Mii name
|-
| 0x1C
| 0x11
| AssignedAccountId? (ASCII NUL-terminated Nintendo Network ID)
|-
| 0x1D
| 0x1
| ?
|-
| 0x1E
| 0x41
| TimeZoneId (ASCII Time Zone Location)
|-
| 0x1F
| 0x1
| ?
|-
| 0x20
| 0x1
| ?
|-
| 0x24
| 0x1
| ?
|-
| 0x25
| 0x101
| MiiImageUrl (ASCII NUL-terminated URL to account mii image)
|-
| 0x26
| 0x4
| AssignedPrincipalId
|-
| 0x27
| 0x4
| ? (Only accessible with param[1] = 0xFE)
|-
| 0x28
| 0x24
| NnasNfsEnv?
|-
| 0x2B
| 0x1
| FpLocalAccountId
|-
| 0x2C
| 0x2
| Age (Not accessible?)
|-
| 0x2D
| 0x1
| ?
|-
| 0x2E
| 0x1
| ?
|-
| 0x2F
| 0x4
| SimpleAddressId? ([[Config_Savegame#CountryInfo|CountryInfo]])
|}