SetDefaultUserStorage
Windows
If you were looking for the method for use with Unreal Engine, see SetDefaultUserStorage for Unreal Engine SDK.
If you were looking for the method for use with Unreal Engine, see SetDefaultUserStorage for Unreal Engine SDK.
caution
Before calling InitSDK
, game developers must set the UserData cache directory and SharedData cache directory.
Player Network SDK will automatically append game ID and application name to the path set by this interface.
If this interface is not invoked by game, then the default path for the Player Network SDK cache data will be %ProgramData%\INTL\{game id}\{application name}\
. For example, game id is 11, and the game application name is INTLSDKDemo, and this interface is not invoked. Then Player Network SDK data will be saved to C:\ProgramData\INTL\11\INTLSDKDemo\
.
Function definition
public static void SetSDKDefaultUserStorage(string dir);
Input parameters
Parameter | Type | Description |
---|---|---|
dir | string | Directory of user data folder |
Code sample
// For example, game id is 11, and the game application name is INTLSDKDemo.
// Then the game invoke the interface like this:
INTLAPI.SetSDKDefaultUserStorage("D:\\game_data\\");
// The data cache path for Player Network SDK will be D:\game_data\11\INTLSDKDemo\.