Difference between revisions of "Profile Selector"

From Nintendo Switch Brew
Jump to navigation Jump to search
(One intermediate revision by the same user not shown)
Line 20: Line 20:
 
"starter" sets the first byte to 5 in order to display initial user setup.
 
"starter" sets the first byte to 5 in order to display initial user setup.
  
With [2.0.0+] sdknso ShowUserSelectorForSystem now has an additional input param UserSelectionSettingsForSystemService: u8 +4 is copied to UiSettings+0x96, and u32 +0 is copied to UiSettings+0xA0.
+
[2.0.0+]: sdknso ShowUserSelectorForSystem now has an additional input param UserSelectionSettingsForSystemService: u8 +4 is copied to UiSettings+0x96, and u32 +0 is copied to UiSettings+0xA0. sdknso ShowUserSelectorForLauncher/ShowUserSelector now sets u8 UiSettings+0x96 to value 1.
  
 
== Result ==  
 
== Result ==  

Revision as of 01:05, 30 November 2019

This is the applet presented when launching a game that allows the user to select a user.

See AM_services#Library_Applets. The profile selector expects a two IStorage inputs and a single IStorage output.

Library Applet Versions

System Version Value
[1.0.0+] 0x1
[2.0.0+] 0x10000
[6.0.0+] 0x20000

UiSettings

This has size 0xA0 (0x98 with [1.0.0]) and seems to only affect the UI display. Typical value is all zero with byte 0x96 equal to 0x01. Setting the first byte to 1 will make the applet display in order to create a new user. "starter" sets the first byte to 5 in order to display initial user setup.

[2.0.0+]: sdknso ShowUserSelectorForSystem now has an additional input param UserSelectionSettingsForSystemService: u8 +4 is copied to UiSettings+0x96, and u32 +0 is copied to UiSettings+0xA0. sdknso ShowUserSelectorForLauncher/ShowUserSelector now sets u8 UiSettings+0x96 to value 1.

Result

This is 0x18-bytes.

Offset Size Notes
0x0 0x8 Result (0 = Success, 2 = Failure)
0x8 0x10 UUID of selected user

Usage

User-processes should push a common arguments struct and the typical UserSelectionConfig struct as well. After pushing in the data and calling start, user-processes should wait upon the PopOutDataEvent and then pop a single IStorage to obtain the result structure described above.