#include <nn/save.h> SAVEStatus SAVEInitSaveDir(u8 accountSlotNo);
|accountSlotNo||The user account slot number. To select the slot number of the common save directory, specify
||The specified user account does not exist on this Wii U console.|
|| The name of this error was changed to
||Not enough space is available in storage to create the save directory.|
||Fatal error occurred. This error is not returned to the application. The application does not need to process this fatal error. Instead, the fatal error message is shown on the TV screen.
A fatal error occurs if the game disc is ejected while this function is copying metadata, such as when the save data icon image is being copied from the game disc to the save
Creates the save directory (or BOSS storage) specified by accountSlotNo and mounts it at
/vol/save. When you create save directories other than
ACT_SLOT_NO_COMMON, if the common directory does not exist (and the common directory has been set to a size greater than 0), the common directory and that account directory are created. (Two directories are created.) If the directory already exists, return
SAVE_STATUS_OK without executing any operations on the directory.
SAVEInitSaveDir takes about one second to create save directories and the metadata. The application does not need to call
SAVEInitSaveDir every time it starts. If save directories already exist, the application can access those directories without calling
SAVEInitSaveDir flushes the save directories internally. For this reason, directory creation can be established without calling
SAVEFlushQuota. If save directories already exist,
SAVEInitSaveDir does not flush the save directories.
SAVEInitSaveDir, there are some moments where you cannot access the save directory.
Do not access a save directory or save data from other threads while calling
When a USB storage is connected to the Wii U, applications started from the optical disc create save data in the USB storage. However, if the save data already exists in NAND, the disc application creates save data in NAND.
Applications started from NAND create save data in NAND, and applications started from USB storage create save data in the USB storage.
|Multiple threads||This function is not thread-safe.|
2013/12/12 Added a description that
SAVEInitSaveDir does not flush the save directories if the save directories already exist.
2013/06/14 Added precautions when calling
2013/05/08 Automated cleanup pass.
2012/09/26 Updated the description.
2012/09/15 Added a description of fatal errors.
2012/09/01 Changed the name of
SAVE_STATUS_STORAGE_FULL. The reason for this change is that the FS function returns
SAVE_STATUS_STORAGE_FULL is a more appropriate name.
2012/08/31 Added an explanation indicating that applications do not need to handle
2012/08/28 Updated the description of the
2012/08/20 Added a comment indicating that applications do not need to call this function every time they start.
2012/07/19 Changed the type of the return value.
2012/03/29 Initial version.