- Last Updated
PC SDK Unity Reference — 3.4.x and Earlier
Based on SDK version 3.4.x. 125 items combined in alphabetical order.
Contents
Base_AccessTokenRenewed
Kind Function · Module Base · Version 3.3.0
Description
Base_AccessTokenRenewed is a function that registers a callback to be called whenever the access token is renewed. Once registered, the callback is called repeatedly each time the token is renewed.
If you call onFinished again, any previously registered callbacks of the same type will be replaced by the new callback.
Declaration
public static void Base_AccessTokenRenewed(OnRenewTokenFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnRenewTokenFinished | N | A callback to be called when the token is renewed. Passing null will unregister it. |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnRenewTokenFinished(CallbackResult result, StovePCToken token);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Renewal Results |
token | StovePCToken | Updated token information |
The callback runs in the thread that called Base_RunCallback(). It is called repeatedly each time the token is renewed.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnRenewTokenFinished(CallbackResult callbackResult, StovePCToken token)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic that uses `token.accessToken`.
}
}
Base_AccessTokenRenewed(OnRenewTokenFinished);
Notes
- This is a notification-type callback that is called repeatedly. It differs in nature from callbacks for one-time asynchronous APIs, such as Base_RestartAppIfNecessaryAsync.
See Also
Base_GetAccessToken
Kind Function · Module Base · Version 3.0.0.4
Description
Base_GetAccessToken is a function that returns the current access token by populating accessToken with it. It must be called after initialization.
Declaration
public static Result Base_GetAccessToken(ref string accessToken, uint length);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
accessToken | ref string | Y | Variable to receive the access token |
length | uint | Y | Buffer size (number of characters) used internally to fill accessToken |
Returns
| Type | Description |
|---|---|
| Result | Query results. Success is determined by IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
string accessToken = string.Empty;
Result result = Base_GetAccessToken(ref accessToken, 1024);
if (result.IsSuccessful())
{
// Please implement the logic that uses the accessToken.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- To receive a notification when the token is renewed, you must use Base_AccessTokenRenewed.
- Do not keep the retrieved token in the game and reuse it later. The SDK renews the token periodically, so a stored value can expire. Call this function every time a token is needed and use the value returned at that moment.
See Also
Base_GetGds
Kind Function · Module Base · Version 3.1.0
Description
Base_GetGds is a function that populates StovePCGds with the user's GDS information and returns it. It must be called after initialization.
Declaration
public static Result Base_GetGds(ref StovePCGds gds);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
gds | ref StovePCGds | Y | Variable to receive GDS information |
Returns
| Type | Description |
|---|---|
| Result | Query results. Success is determined by IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 83 | INVALID_GDS_INFO | The GDS information is incorrect. You must verify the initialization status. | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
StovePCGds gds = default;
Result result = Base_GetGds(ref gds);
if (result.IsSuccessful())
{
// Please implement logic that uses gds.nation, gds.regulation, and so on.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- If the operation fails,
gdswill remain at its default value (default).
See Also
Base_GetSignin
Kind Function · Module Base · Version 3.1.0
Description
Base_GetSignin is a function that fills in the user's login information into StovePCSignin and returns it. It must be called after initialization.
Declaration
public static Result Base_GetSignin(ref StovePCSignin signin);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
signin | ref StovePCSignin | Y | Variable to store the retrieved login credentials |
Returns
| Type | Description |
|---|---|
| Result | Query results. Success is determined by IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
StovePCSignin signin = default;
Result result = Base_GetSignin(ref signin);
if (result.IsSuccessful())
{
// Please implement the logic that uses `signin.personVerify`, `signin.nationality`, and so on.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- If the operation fails,
signinremains at its default value (default).
See Also
Base_GetTraceHint
Kind Function · Module Base · Version 3.0.0.4 · Deprecated
Description
This feature is deprecated. It is not available in the new interface either.
Base_GetTraceHint is a function that fills in the session hint information for log tracing into StovePCTraceHint and returns it. It must be called after initialization.
Declaration
public static Result Base_GetTraceHint(ref StovePCTraceHint traceHint);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
traceHint | ref StovePCTraceHint | Y | Variable to receive session hint information |
Returns
| Type | Description |
|---|---|
| Result | Query results. Success is determined by IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
StovePCTraceHint traceHint = default;
Result result = Base_GetTraceHint(ref traceHint);
if (result.IsSuccessful())
{
// Please implement logic to log items such as `traceHint.sessionId`.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- If the operation fails,
traceHintwill remain at its default value (default). - This function and StovePCTraceHint are scheduled to be removed in a future version.
See Also
Base_GetUser
Kind Function · Module Base · Version 3.0.0.4
Description
Base_GetUser is a function that fills in the logged-in user's information into StovePCUser and returns it. It must be called after initialization.
Declaration
public static Result Base_GetUser(ref StovePCUser user);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
user | ref StovePCUser | Y | Variable to store the returned user information |
Returns
| Type | Description |
|---|---|
| Result | Query results. Success is determined by IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
StovePCUser user = default;
Result result = Base_GetUser(ref user);
if (result.IsSuccessful())
{
// Please implement the logic using `user.nickname` and `user.gameUserId`.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- If the operation fails,
userremains at its default value (default).
See Also
Base_GetVersion
Kind Function · Module Base · Version 3.0.0.4
Description
Base_GetVersion is a function that returns the SDK version string with version substituted into it.
Declaration
public static Result Base_GetVersion(ref string version, uint length);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
version | ref string | Y | Variable to receive the version string |
length | uint | Y | The buffer size (in characters) used internally to fill version |
Returns
| Type | Description |
|---|---|
| Result | Query results. Success is determined based on IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
string version = string.Empty;
Result result = Base_GetVersion(ref version, 64);
if (result.IsSuccessful())
{
// Please implement the logic that uses "version."
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- None
See Also
- None
Base_Initialize
Kind Function · Module Base · Version 3.0.0.4
Description
Base_Initialize is an asynchronous function that takes StovePCInitializeParam as an argument to initialize the SDK. The result is passed to the onFinished callback.
You cannot call any other SDK APIs before calling this function. To call it without initialization parameters, you must use Base_InitializeEx.
Before calling this function, you must first call a function from the Base_RestartAppIfNecessary series (such as
Base_RestartAppIfNecessary,Base_RestartAppIfNecessaryAsync,Base_RestartAppIfNecessaryAsyncEx, etc.) to verify that it was executed via the launcher. If you do not call them first, the function will fail with error codeNEED_STOVE_LAUNCHER(84).
Declaration
public static void Base_Initialize(StovePCInitializeParam initParam, OnInitializeFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
initParam | StovePCInitializeParam | Y | Initialization Parameters |
onFinished | OnInitializeFinished | Y | Callback to receive the results |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnInitializeFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Initialization Results |
The callback runs in the thread that called Base_RunCallback(). It runs once for each such call.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | There is a missing value among environment, gameId, and applicationKey in initParam. | x | |
| 18 | ALREADY_INITIALIZED | It is already initialized. | x | |
| 84 | NEED_STOVE_LAUNCHER | The Base_RestartAppIfNecessary series function was not called first, or it was not executed via the launcher | O | The game is closing because it is not running through the Stove PC client. Please relaunch the game from the client. If you do not have the client installed, please install it from the Stove website.[OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnInitializeFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for the success case.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
StovePCInitializeParam initParam = new StovePCInitializeParam
{
environment = "real",
gameId = "your_game_id",
applicationKey = "your_application_key"
};
Base_Initialize(initParam, OnInitializeFinished);
// Please handle the callback by calling it repeatedly within the game loop.
while (isRunning)
{
Base_RunCallback();
}
Notes
- To receive a callback, you must repeatedly call Base_RunCallback within the game loop. This function should not be called separately in the form of
while(true); rather, it must be called every frame within the game loop. - When the process ends, you must call Base_UnInitialize.
See Also
Base_InitializeEx
Kind Function · Module Base · Version 3.4.1
Description
Unlike Base_Initialize, Base_InitializeEx does not accept StovePCInitializeParam; it only accepts a callback. The initialization result is passed to the onFinished callback in the same way.
This function reuses the initialization parameters cached by the Base_RestartAppIfNecessary series of functions (
Base_RestartAppIfNecessary,Base_RestartAppIfNecessaryAsync,Base_RestartAppIfNecessaryAsyncEx2, etc.). You must call a function from theBase_RestartAppIfNecessaryseries before calling this function; otherwise, it will fail with errorNEED_STOVE_LAUNCHER(84).
Declaration
public static void Base_InitializeEx(OnInitializeFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnInitializeFinished | Y | Callback to receive the results |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnInitializeFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Initialization Results |
The callback runs in the thread that called Base_RunCallback(). It runs once for each such call.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | There are empty values among the environment, gameId, and applicationKey cached by the Base_RestartAppIfNecessary series of functions. | x | |
| 18 | ALREADY_INITIALIZED | It is already initialized. | x | |
| 84 | NEED_STOVE_LAUNCHER | The Base_RestartAppIfNecessary series function was not called first, or the application was not launched via the launcher. | O | The game is closing because it is not running through the Stove PC client. Please relaunch the game from the client. If you haven't installed the client, please install it from the Stove website.[OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnInitializeFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for when the operation is successful.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
Base_InitializeEx(OnInitializeFinished);
Notes
- The only difference in the signature compared to Base_Initialize is that the StovePCInitializeParam parameter is missing.
- To receive the callback, you must repeatedly call Base_RunCallback within the game loop.
See Also
Base_OpenExternalUrl
Kind Function · Module Base · Version 3.3.4
Description
Base_OpenExternalUrl is an asynchronous function that opens the specified URL externally. The result is passed to the onFinished callback.
Declaration
public static void Base_OpenExternalUrl(string url, OnOpenExternalUrlFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
url | string | Y | URL to open |
onFinished | OnOpenExternalUrlFinished | Y | Callback to receive the results |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnOpenExternalUrlFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Call Results |
The callback runs in the thread that called Base_RunCallback(). It runs once for each such call.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnOpenExternalUrlFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
Base_OpenExternalUrl("https://www.onstove.com", OnOpenExternalUrlFinished);
Notes
onFinishedis required. If it is not provided, it will be treated asINVALID_PARAM.- Opens the specified URL in your default browser. The game window remains open.
- The callback runs in the thread that called
Base_RunCallback().
See Also
- None
Base_OverImmersionNotification
Kind Function · Module Base · Version 3.3.0
Description
Base_OverImmersionNotification is a function that registers a callback to be called when an over-engagement warning is triggered. Calling onFinished again replaces any previously registered callbacks of the same type with the new callback.
Declaration
public static void Base_OverImmersionNotification(OnOverImmersionFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnOverImmersionFinished | N | A callback to be invoked when an excessive engagement warning is triggered. Passing null will unregister it. |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnOverImmersionFinished(CallbackResult result, StovePCOverImmersion overImmersion);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Notification Results |
overImmersion | StovePCOverImmersion | Warning Regarding Excessive Engagement |
The callback runs in the thread that called Base_RunCallback(). It is called whenever an immersion warning occurs.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnOverImmersionFinished(CallbackResult callbackResult, StovePCOverImmersion overImmersion)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic to display warnings using `overImmersion.warningMessage` and similar methods.
}
}
Base_OverImmersionNotification(OnOverImmersionFinished);
Notes
- This notification may continue to function even in
PCBANG_FREEstate. You must maintain the callback registration regardless of the state.
See Also
Base_RestartAppIfNecessary
Kind Function · Module Base · Version 3.1.0
Description
Base_RestartAppIfNecessary is a synchronous function that returns StovePCInitializeParam and restarts the app if necessary. It immediately returns the value bool without a callback.
To process this asynchronously, you must use the Base_RestartAppIfNecessaryAsync series.
Declaration
public static bool Base_RestartAppIfNecessary(StovePCInitializeParam initParam);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
initParam | StovePCInitializeParam | Y | Initialization Parameters |
Returns
| Type | Description |
|---|---|
bool | If true, the game will be relaunched via the Stove Protocol handler, so you must exit the game without executing the subsequent code. If false, the game is already running via the launcher, so proceed by calling Base_Initialize(). |
Error Codes
None. This function does not return Result/CallbackResult; if an exception occurs internally, the C# exception is rethrown as-is.
Example
using static Stove.PCSDK.Base;
StovePCInitializeParam initParam = new StovePCInitializeParam
{
environment = "real",
gameId = "your_game_id",
applicationKey = "your_application_key"
};
bool restarted = Base_RestartAppIfNecessary(initParam);
Notes
- This function is synchronous and does not accept callbacks. To handle restarts asynchronously, you must use Base_RestartAppIfNecessaryAsync, Base_RestartAppIfNecessaryAsyncEx, and Base_RestartAppIfNecessaryAsyncEx2.
- If an exception occurs, the C# exception is rethrown as-is without being wrapped in
Result, so the calling code must handle the exception accordingly.
See Also
Base_RestartAppIfNecessaryAsync
Kind Function · Module Base · Version 3.3.0
Description
Base_RestartAppIfNecessaryAsync accepts StovePCInitializeParam and a timeout (waitTimeMillisec), and, if necessary, restarts the app asynchronously and notifies you of the result via a callback.
If you need to specify whether to run the launcher, use Base_RestartAppIfNecessaryAsyncEx; if you want to pass the extension initialization parameters as a single structure, use Base_RestartAppIfNecessaryAsyncEx2.
Declaration
public static void Base_RestartAppIfNecessaryAsync(StovePCInitializeParam initParam, uint waitTimeMillisec, OnRestartAppIfNecessaryAsyncFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
initParam | StovePCInitializeParam | Y | Initialization Parameters |
waitTimeMillisec | uint | Y | Wait Time (milliseconds) |
onFinished | OnRestartAppIfNecessaryAsyncFinished | Y | Callback to receive the results |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnRestartAppIfNecessaryAsyncFinished(CallbackResult result, bool restartAppIfNecessary);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Call Results |
restartAppIfNecessary | bool | This value indicates whether to restart. |
The callback runs in the thread that called Base_RunCallback(). It runs once for each such call.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check result.exceptionMessage. | O | There was a temporary issue. Please try again. [OK] |
If you receive the code below, you must exit the game. The game cannot continue normally.
87IPC_CONNECT_FAILED·88IPC_AES_KEY_NOT_RECEIVED·89IPC_TIMEOUT— You must restart the game via the Stove PC client253UNMANAGED_EXCEPTION·254MANAGED_EXCEPTION— Since it is impossible to determine whether to restart, the game must be closed.
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnRestartAppIfNecessaryAsyncFinished(CallbackResult callbackResult, bool restartAppIfNecessary)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
StovePCInitializeParam initParam = new StovePCInitializeParam
{
environment = "real",
gameId = "your_game_id",
applicationKey = "your_application_key"
};
Base_RestartAppIfNecessaryAsync(initParam, 3000, OnRestartAppIfNecessaryAsyncFinished);
Notes
- If you pass
onFinishedtonull, only the restart will be handled without a callback. - To receive the callback, you must repeatedly call Base_RunCallback within the game loop.
See Also
Base_RestartAppIfNecessaryAsyncEx
Kind Function · Module Base · Version 3.4.0
Description
Base_RestartAppIfNecessaryAsyncEx is a version of Base_RestartAppIfNecessaryAsync with the launchLauncher parameter added. The caller can specify whether to run the launcher.
Declaration
public static void Base_RestartAppIfNecessaryAsyncEx(StovePCInitializeParam initParam, uint waitTimeMillisec, bool launchLauncher, OnRestartAppIfNecessaryAsyncFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
initParam | StovePCInitializeParam | Y | Initialization Parameters |
waitTimeMillisec | uint | Y | Wait Time (milliseconds) |
launchLauncher | bool | Y | Whether the launcher is running |
onFinished | OnRestartAppIfNecessaryAsyncFinished | Y | Callback to receive the results |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnRestartAppIfNecessaryAsyncFinished(CallbackResult result, bool restartAppIfNecessary);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Call Results |
restartAppIfNecessary | bool | This value indicates whether to restart. |
The callback runs in the thread that called Base_RunCallback(). It runs once for each such call.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check result.exceptionMessage. | O | There was a temporary issue. Please try again. [OK] |
If you receive the code below, you must exit the game. The game cannot proceed normally.
87IPC_CONNECT_FAILED·88IPC_AES_KEY_NOT_RECEIVED·89IPC_TIMEOUT— You must restart the game via the Stove PC client253UNMANAGED_EXCEPTION·254MANAGED_EXCEPTION— Since it is impossible to determine whether to restart, the game must be closed.
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnRestartAppIfNecessaryAsyncFinished(CallbackResult callbackResult, bool restartAppIfNecessary)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
StovePCInitializeParam initParam = new StovePCInitializeParam
{
environment = "real",
gameId = "your_game_id",
applicationKey = "your_application_key"
};
Base_RestartAppIfNecessaryAsyncEx(initParam, 3000, true, OnRestartAppIfNecessaryAsyncFinished);
Notes
- Exceptions that occur in a background thread are also passed to the callback as
UNMANAGED_EXCEPTION(253) orMANAGED_EXCEPTION(254). - The only difference between Base_RestartAppIfNecessaryAsync and the signature is the single parameter
launchLauncher.
See Also
Base_RestartAppIfNecessaryAsyncEx2
Kind Function · Module Base · Version 3.4.1
Description
This can be used regardless of whether it is linked to Steam.
platformNameis an optional field to be filled in only when linking with platforms other than Stove (such as Steam); if you are linking exclusively with Stove, leave the value unset or set it to an empty string (""), and it will function the same as Base_RestartAppIfNecessaryAsyncEx.
Base_RestartAppIfNecessaryAsyncEx2 is a version of Base_RestartAppIfNecessaryAsyncEx that combines initParam, waitTimeMillisec, and launchLauncher into a single StovePCInitializeParamEx2 structure. platformName and the reserved fields are also passed together via this structure.
Declaration
public static void Base_RestartAppIfNecessaryAsyncEx2(StovePCInitializeParamEx2 initParam, OnRestartAppIfNecessaryAsyncFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
initParam | StovePCInitializeParamEx2 | Y | Extension Initialization Parameters |
onFinished | OnRestartAppIfNecessaryAsyncFinished | Y | Callback to receive the results |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnRestartAppIfNecessaryAsyncFinished(CallbackResult result, bool restartAppIfNecessary);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Call Results |
restartAppIfNecessary | bool | This value indicates whether to restart. |
The callback runs in the thread that called Base_RunCallback(). It runs once for each such call.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
If you see the code below, you must exit the game. The game cannot proceed normally.
87IPC_CONNECT_FAILED·88IPC_AES_KEY_NOT_RECEIVED·89IPC_TIMEOUT— You must restart the game via the Stove PC client253UNMANAGED_EXCEPTION·254MANAGED_EXCEPTION— Since it is impossible to determine whether to restart, the game must be terminated.
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnRestartAppIfNecessaryAsyncFinished(CallbackResult callbackResult, bool restartAppIfNecessary)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
StovePCInitializeParamEx2 initParam = new StovePCInitializeParamEx2
{
environment = "real",
gameId = "your_game_id",
applicationKey = "your_application_key",
waitTimeMillisec = 3000,
launchLauncher = true,
platformName = "your_platform_name"
};
Base_RestartAppIfNecessaryAsyncEx2(initParam, OnRestartAppIfNecessaryAsyncFinished);
Notes
- Exceptions that occur in a background thread are also passed to the callback as
UNMANAGED_EXCEPTION(253) orMANAGED_EXCEPTION(254). - Unlike Base_RestartAppIfNecessaryAsync and Base_RestartAppIfNecessaryAsyncEx, it accepts only StovePCInitializeParamEx2 without any additional parameters.
See Also
Base_RunCallback
Kind Function · Module Base · Version 3.0.0.4
Description
Base_RunCallback is a function that executes pending asynchronous API callbacks on the current calling thread. Callbacks for all SDK asynchronous APIs (e.g., Base_Initialize) are executed on the thread that called this function, rather than on an internal SDK thread.
Pending callbacks are processed when they are called every frame (or periodically) within the game loop.
Declaration
public static void Base_RunCallback();
Parameters
None
Returns
| Type | Description |
|---|---|
void | None |
Error Codes
None. This function does not return Result/CallbackResult; if an exception occurs internally, the C# exception is rethrown as-is.
Example
using static Stove.PCSDK.Base;
// Please call this every frame within the game loop.
void Update()
{
Base_RunCallback();
}
Notes
- This is not a function that is called separately in the form of
while(true), but rather a function that must be called repeatedly within the game loop. - To specify a wait time, you must use Base_RunCallbackWithTimeout.
See Also
Base_RunCallbackWithTimeout
Kind Function · Module Base · Version 3.3.0
Description
Base_RunCallbackWithTimeout is a function that behaves similarly to Base_RunCallback, but allows you to specify a wait time using timeoutMillisec. The callback is executed on the thread that called this function.
Declaration
public static void Base_RunCallbackWithTimeout(uint timeoutMillisec);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
timeoutMillisec | uint | Y | Wait Time (milliseconds) |
Returns
| Type | Description |
|---|---|
void | None |
Error Codes
None. This function does not return Result/CallbackResult; if an exception occurs internally, the C# exception is rethrown as-is.
Example
using static Stove.PCSDK.Base;
Base_RunCallbackWithTimeout(100);
Notes
- Just like Base_RunCallback, this must be called repeatedly within the game loop.
See Also
Base_SetGameProfile
Kind Function · Module Base · Version 3.0.0.4
Description
Base_SetGameProfile is a synchronous function that passes StovePCGameProfile to the SDK.
Declaration
public static Result Base_SetGameProfile(StovePCGameProfile gameProfile);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
gameProfile | StovePCGameProfile | Y | Game Profiles to Configure |
Returns
| Type | Description |
|---|---|
| Result | Configuration results. Success is determined by IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
StovePCGameProfile gameProfile = new StovePCGameProfile
{
worldId = "world_01",
characterNumber = 12345L
};
Result result = Base_SetGameProfile(gameProfile);
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
Notes
- None
See Also
Base_SetLanguage
Kind Function · Module Base · Version 3.1.0
Description
Base_SetLanguage is a synchronous function that sets the SDK language to the enumeration value StoveLanguage.
If you need to specify a language that is not listed here, use Base_SetLanguageEx.
When setting up a new integration, use Base_SetLanguageEx. This allows you to specify languages not listed in the enumeration as strings, so you can continue using them even if new languages are added later.
Declaration
public static Result Base_SetLanguage(StoveLanguage language);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
language | StoveLanguage | Y | Language to Set |
Returns
| Type | Description |
|---|---|
| Result | Configuration results. Success is determined by IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
Result result = Base_SetLanguage(StoveLanguage.ko);
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- Base_SetLanguageEx accepts a string instead of a value from the
StoveLanguageenumeration.
See Also
Base_SetLanguageEx
Kind Function · Module Base · Version 3.4.0
Description
Unlike Base_SetLanguage, Base_SetLanguageEx is a synchronous function that sets the language as a string rather than using the StoveLanguage enumeration. It is used when you need to set a language value that is not listed in StoveLanguage.
Declaration
public static Result Base_SetLanguageEx(string language);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
language | string | Y | Language strings to configure |
Returns
| Type | Description |
|---|---|
| Result | Configuration results. Success is determined based on IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
Result result = Base_SetLanguageEx("ko");
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- The only difference in the signature compared to Base_SetLanguage is that the parameter type is
stringrather than theStoveLanguageenumeration.
See Also
Base_ShutdownNotification
Kind Function · Module Base · Version 3.3.0
Description
Base_ShutdownNotification is a function that registers a callback to be invoked when a shutdown notification is sent to a user subject to shutdown. Calling onFinished again replaces any previously registered callbacks of the same type with the new callback.
Declaration
public static void Base_ShutdownNotification(OnShutdownFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnShutdownFinished | N | A callback to be invoked when a shutdown notification occurs. Passing null unregisters the callback. |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnShutdownFinished(CallbackResult result, StovePCShutdown shutdown);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Notification Results |
shutdown | StovePCShutdown | Shutdown Notice |
The callback runs in the thread that called Base_RunCallback(). It is called whenever a shutdown notification occurs.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). The error code is result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnShutdownFinished(CallbackResult callbackResult, StovePCShutdown shutdown)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic to display prompts using `shutdown`, `shutdownMessage`, etc.
}
}
Base_ShutdownNotification(OnShutdownFinished);
Notes
ShutdownNotificationis not a feature exclusive to South Korea. If an account has been shut down, this callback will be triggered even from overseas.
See Also
Base_UnInitialize
Kind Function · Module Base · Version 3.0.0.4
Description
You must call this function before exiting the game. Since this function is responsible for calculating the total playtime and updating the server with that data, if you terminate the process without calling it, the playtime for that session will be missing.
Base_UnInitialize is a synchronous function that terminates the SDK. It clears the pending callback queue in disposal mode (registered user delegates are not called during this process), cleans up the callback container, and performs a native termination.
Declaration
public static Result Base_UnInitialize();
Parameters
None
Returns
| Type | Description |
|---|---|
| Result | Exit result. Success is determined by IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). It is identified as exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
Result result = Base_UnInitialize();
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- During the shutdown process, any callbacks that have already been registered are treated as being in "discard" mode, so the user's delegate is not called. In other words, you should not expect callbacks from asynchronous APIs registered immediately before shutdown.
- Initialization pairs with Base_Initialize or Base_InitializeEx.
- If there are multiple ways for the game to end (normal exit, exception exit, forced exit), ensure that this function is called in all cases. The playtime statistics are calculated at this point.
See Also
Base_VietnamAgeRatingNotification
Kind Function · Module Base · Version 3.4.1
Description
Base_VietnamAgeRatingNotification is a function that registers a callback to be invoked when a Vietnamese age rating overlay is required.
This callback is a one-time event and must be registered after rendering is complete.
Declaration
public static void Base_VietnamAgeRatingNotification(OnVietnamAgeRatingFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnVietnamAgeRatingFinished | N | A callback to be invoked when a notification occurs. Passing null unregisters it. |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnVietnamAgeRatingFinished(CallbackResult result, StovePCVietnamAgeRatingInfo vietnamAgeRatingInfo);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Notification Results |
vietnamAgeRatingInfo | StovePCVietnamAgeRatingInfo | Age Rating Overlay Information |
The callback runs in the thread that called Base_RunCallback(). This is a one-time callback.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). It is identified as result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnVietnamAgeRatingFinished(CallbackResult callbackResult, StovePCVietnamAgeRatingInfo vietnamAgeRatingInfo)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic to draw an overlay using `vietnamAgeRatingInfo`.
}
}
Base_VietnamAgeRatingNotification(OnVietnamAgeRatingFinished);
Notes
- This callback must be registered after rendering is possible. If it is registered at a time when rendering is not yet ready—such as immediately after initialization—the overlay may not display properly.
- You must register the "Excessive Engagement Alert" separately under Base_VietnamOverimmersionNotification.
See Also
Base_VietnamOverimmersionNotification
Kind Function · Module Base · Version 3.4.1
Description
Base_VietnamOverimmersionNotification is a function that registers a callback to be invoked when the Vietnam Immersion overlay needs to be displayed. Calling onFinished again replaces any previously registered callbacks of the same type with the new callback.
This callback is a one-time event and must be registered after the point at which rendering is possible.
Declaration
public static void Base_VietnamOverimmersionNotification(OnVietnamOverimmersionFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnVietnamOverimmersionFinished | N | A callback to be invoked when a notification is triggered. Passing null will unregister it. |
Returns
| Type | Description |
|---|---|
void | None |
Callback
public delegate void OnVietnamOverimmersionFinished(CallbackResult result, StovePCVietnamOverimmersionInfo vietnamOverimmersionInfo);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Notification Results |
vietnamOverimmersionInfo | StovePCVietnamOverimmersionInfo | Information Displayed by the "Over-Engagement" Overlay |
The callback runs in the thread that called Base_RunCallback(). This is a one-time callback.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). It is identified as result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For possible error codes, see BaseSDKResultCode.
Example
using static Stove.PCSDK.Base;
void OnVietnamOverimmersionFinished(CallbackResult callbackResult, StovePCVietnamOverimmersionInfo vietnamOverimmersionInfo)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic to draw overlays using `vietnamOverimmersionInfo`.
}
}
Base_VietnamOverimmersionNotification(OnVietnamOverimmersionFinished);
Notes
- This callback must be registered after rendering is possible.
- Age rating notifications must be registered separately under Base_VietnamAgeRatingNotification.
See Also
BaseSDKMethod
Kind Enum · Module Base · Version 3.0.0.4
Description
BaseSDKMethod is the value stored in result.methodCode within Result.methodCode and CallbackResult. It is used to indicate which API call occurred when the C# wrapper converts Managed exception to Result / CallbackResult.
The values are categorized by type as follows.
- Life Cycle: Initialization · Termination · Version Lookup
- Authentication/Token: View and Renew Access Tokens
- User/Game Information: User · GDS · View Login Information
- Language
- Notices/Regulations: Excessive Gaming · Shutdown · Vietnam Regulatory Notice
- Logs/Diagnostics: Log Transmission, Trace Hints, Game Profiles
- App Restart/External Links: Launcher Restart, External URLs
Among these, values prefixed with INTERNAL_ are for internal SDK use only and have been excluded from the table below.
Values prefixed with
INTERNAL_are for internal use only and have therefore been excluded from the table below. You will not need to handle these values directly in the game code.
Declaration
public enum BaseSDKMethod
{
INITIALIZE = 1,
UNINITIALIZE = 2,
// ... See the "Values" table below
GET_TRANSLATE_LANGUAGE = 119,
};
Enum Values
Life Cycle
| Code | Name | Description |
|---|---|---|
| 1 | INITIALIZE | Base_Initialize · Base_InitializeEx |
| 2 | UNINITIALIZE | Base_UnInitialize |
| 5 | GET_VERSION | Base_GetVersion |
Authentication/Token
| Code | Name | Description |
|---|---|---|
| 64 | GET_ACCESS_TOKEN | Base_GetAccessToken |
| 65 | ACCESS_TOKEN_RENEWED | Base_AccessTokenRenewed |
| 112 | FORCE_REFRESH_TOKEN | No corresponding public API (for internal SDK use only) |
| 113 | ACCESS_TOKEN_RENEWED_TO_PRIVATE | No corresponding public API (for internal SDK use only) |
| 114 | GET_TOKEN_TO_PRIVATE | No corresponding public API (for internal SDK use only) |
User/Game Information
| Code | Name | Description |
|---|---|---|
| 66 | GET_USER | Base_GetUser |
| 73 | GET_GDS | Base_GetGds |
| 74 | GET_SIGNIN | Base_GetSignin |
| 115 | GET_ENV_TOKEN_TO_PRIVATE | No corresponding public API (for internal SDK use only) |
| 116 | GET_GAMEID_TO_PRIVATE | No corresponding public API (for internal SDK use only) |
| 117 | GET_MEMBERNO_PRIVATE | No corresponding public API (for internal SDK use only) |
| 118 | GET_PUBLIC_IP | No corresponding public API (internal to the SDK only) |
Language
| Code | Name | Description |
|---|---|---|
| 67 | SET_LANGUAGE | Base_SetLanguage · Base_SetLanguageEx |
| 119 | GET_TRANSLATE_LANGUAGE | No corresponding public API (for internal SDK use only) |
Notices/Regulations
| Code | Name | Description |
|---|---|---|
| 68 | OVER_IMMERSION_NOTIFICATION | Base_OverImmersionNotification |
| 69 | SHUTDOWN_NOTIFICATION | Base_ShutdownNotification |
| 79 | VIETNAM_AGE_RATING_NOTIFICATION | Base_VietnamAgeRatingNotification |
| 80 | VIETNAM_OVER_IMMERSION_NOTIFICATION | Base_VietnamOverimmersionNotification |
Log/Diagnostics
| Code | Name | Description |
|---|---|---|
| 70 | LOG_ADD | Base_LogAdd (Deprecated) — There is no corresponding function for the currently exposed header. |
| 71 | GET_TRACE_HINT | Base_GetTraceHint |
| 72 | SET_GAME_PROFILE | Base_SetGameProfile |
App Restart/External Connection
| Code | Name | Description |
|---|---|---|
| 75 | RESTART_APP_IF_NECESSARY | Base_RestartAppIfNecessary |
| 76 | RESTART_APP_IF_NECESSARY_ASYNC | Base_RestartAppIfNecessaryAsync series (including Ex and Ex2) |
| 77 | OPEN_EXTERNAL_URL | Base_OpenExternalUrl |
| 78 | GET_CLOUD_SAVING_PATH | Base_GetCloudSavingPath — Exclusive to StoreIndie |
Unused numbers
| Code | Name | Description |
|---|---|---|
| — | 6–63 | Not in use (unused number) |
| — | 81–95 | Not in use (unused number) |
Internal-use-only values (INTERNAL_SEND_81PLUG, INTERNAL_UPDATE_81PLUG, INTERNAL_SET_PLAYTIME_REPORT, INTERNAL_OPERATOR_REPORT_PLAYTIME, INTERNAL_GAME_EXIT_REPORT_PLAYTIME, INTERNAL_FILE_SAVE_UNSET_PLAYTIME, INTERNAL_FAILED_PLAYTIME_TRANSFERS, INTERNAL_OPERATOR_REPORT_CONCURRENT_USER, INTERNAL_SERVER_CONFIG, INTERNAL_GDS_INFO, INTERNAL_GAME_CHECKER_LOGIN, INTERNAL_ONSTOVE_LOGIN, INTERNAL_FUNCTION, INTERNAL_RENEW_GUID_TOKEN, INTERNAL_RENEW_TOKEN, INTERNAL_CONVERT_ONLINE_TOKEN, INTERNAL_TRANSLATE_LANGUAGE, INTERNAL_GET_GAMEMETA, for a total of 18) have been excluded from the table.
Example
using static Stove.PCSDK.Base;
// Result.methodCode stores the value of this enumeration as a uint.
void CheckMethod(Result result)
{
if (result.methodCode == Convert.ToUInt32(BaseSDKMethod.INITIALIZE))
{
// These are the results of the calls to Base_Initialize and Base_InitializeEx.
}
}
Notes
GET_TOKEN_TO_PRIVATE,GET_ENV_TOKEN_TO_PRIVATE,GET_GAMEID_TO_PRIVATE,GET_MEMBERNO_PRIVATE,GET_PUBLIC_IP,FORCE_REFRESH_TOKEN,ACCESS_TOKEN_RENEWED_TO_PRIVATE,GET_TRANSLATE_LANGUAGEdo not containINTERNALin their names, but no publicBase_API that uses this value withinBaseAPI.cshas been identified. Values 112–119 in the C++ source header (BaseSDKResult.h) are all explicitly marked with the comment “Internal method,” confirming that these values are used exclusively within the SDK and have no corresponding public API.- There is no public API corresponding to
LOG_ADD(70). Although the C++ source header contains a comment forBase_LogAdd (deprecated), there is no function declaration forBase_LogAddin any of the currently public headers. This is a deprecated API where only the code value remains for backward compatibility.
See Also
BaseSDKResultCode
Kind Result Code · Module Base · Version 3.0.0.4
Description
BaseSDKResultCode is the value stored in Result.resultCode. 0 (SUCCESS) indicates success; any other value indicates the cause of failure. Result.IsSuccessful() checks whether resultCode == 0 is true.
If an exception occurs inside the C# wrapper (such as a marshaling error), it always returns a Result filled with MANAGED_EXCEPTION(254).
Declaration
public enum BaseSDKResultCode
{
SUCCESS = 0,
FAIL = 1,
// ... See the "Values" table below
IPC_TIMEOUT = 89,
}
Enum Values
Success/General Error
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 1 | FAIL | General Failure | x | |
| 2 | INVALID_CONFIG | Invalid setting (unused code) | x | |
| 3 | INVALID_LOG_LEVEL | Invalid log level value (unused code) | x | |
| 4 | INVALID_LOG_PATH | Invalid log path (unused code) | x | |
| 5 | INVALID_PARAM | The parameter value is incorrect. Please check the parameters in the calling code. | x | |
| — | 6–15 | Not in use (unassigned number) | x |
Initial State
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 16 | BASE_NOT_INITIALIZED | The SDK has not been initialized. A prior call to Base_Initialize is required. | x | |
| 17 | NOT_INITIALIZED | Not initialized | x | |
| 18 | ALREADY_INITIALIZED | Already initialized. Duplicate initialization calls must be removed. | x | |
| 29 | ASYNC_OPERATION_IN_PROGRESS | An asynchronous operation is already in progress. You must wait for the callback from the previous call before calling again. | x | |
| 30 | BASE_UNINITIALIZED | The SDK is closed | x |
Authentication/Token
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 19 | INVALID_ACCESS_TOKEN | Invalid access token | O | Your login session has expired. Please close the game and restart it. [OK] |
| 20 | NULL_TOKEN_ENTITY | No token entities (unused code) | x |
Response/Communication
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 21 | NULL_ENTITY | No response entity (unused code) | x | |
| 22 | HTTP_ERROR | HTTP Communication Error | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 23 | RESPONSE_ERROR | Response Processing Error | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 24 | RESPONSE_INVALID_CODE | Invalid response code | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 25 | RESPONSE_VALUE_IS_NULL | No response value | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 26 | RESPONSE_INVALID_VALUE_FORMAT | The response value is in an invalid format. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 249 | NETWORK_TRANSPORT_ERROR | Network transmission error. externalError contains a native error code from the HTTP backend (e.g., WinHTTP 12002/12007/12029). | x |
81Plug Integration
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 27 | LOG_81PLUG_ERROR | 81Plug Log Processing Error (Unused Code) | x | |
| 28 | UPDATE_81PLUG_FEED_ERROR | 81Plug Feed Update Error (Unused Code) | x |
Country/Regulations
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 31 | NOT_SUPPORTED_COUNTRY | Countries Not Supported | x |
For Internal Use Only
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 33 | POPUP_NOT_CREATED | For internal maintenance only — Close without creating a popup (for onDestroy only). The wrapper intercepts the call and does not invoke the user callback. | x | |
| — | 32 | Not in use (unused number) | x | |
| — | 34–79 | Not in use (unassigned number) | x |
Language/GDS
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 80 | LANGUAGE_NOT_SET | Language not set (unused code) | x | |
| 81 | EMPTY_TRANSLATED_STRING | The translated string is empty (unused code) | x | |
| 82 | NOT_FOUND_REQUIRED_INFORMATION | The information you are looking for cannot be found. | x | |
| 83 | INVALID_GDS_INFO | GDS Information Is Incorrect (Unused Code) | x |
Launcher Integration
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 84 | NEED_STOVE_LAUNCHER | Stove Launcher is required | O | The game is closing because it is not running through the Stove PC client. Please launch the game again from the client. If you do not have the client installed, please install it from the Stove website.[OK] |
| 85 | LAUNCHER_FAILED_CREATE_REQUIRED | Failed to create launcher (unused code) | x | |
| 86 | RENEW_TOKEN_MAX_RETRY_COUNT_EXCEEDED | The number of retries for token renewal has been exceeded. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 87 | IPC_CONNECT_FAILED | Failed to establish an IPC connection with the launcher | O | The game is closing because it is not running through the Stove PC client. Please launch the game again from the client. If you do not have the client installed, please install it from the Stove website.[OK] |
| 88 | IPC_AES_KEY_NOT_RECEIVED | IPC AES Key Not Received | O | The game is closing because it is not running through the Stove PC client. Please launch the game again from the client. If you do not have the client installed, please install it from the Stove website.[OK] |
| 89 | IPC_TIMEOUT | IPC Timeout | O | The game is closing because it is not running through the Stove PC client. Please launch the game again from the client. If you do not have the client installed, please install it from the Stove website.[OK] |
| — | 90–248 | Not in use (unused number) | x |
For C# Wrappers Only
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 250 | JSON_EXCEPTION | An exception occurred while processing JSON | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 251 | PCSDK_DLL_NOT_FOUND | Native PCSDK DLL not found (unused code) | x | |
| 252 | NOT_IMPLEMENTED | Unimplemented Features (Unused Code) | x | |
| 253 | UNMANAGED_EXCEPTION | Native (unmanaged) exception occurred | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | Exception occurred within the C# wrapper (e.g., marshaling) | O | A temporary issue has occurred. Please try again. [OK] |
| 255 | UNKNOWN_ERROR | Unknown Error (Unused Code) | x |
If you receive the code below, you must exit the game. The game cannot proceed normally.
19INVALID_ACCESS_TOKEN— Your login session has expired; please close the game and restart it.84NEED_STOVE_LAUNCHER— You'll need to restart the game after it closes.87IPC_CONNECT_FAILED— You'll need to restart the game after it closes.88IPC_AES_KEY_NOT_RECEIVED— You will need to restart the game after it closes89IPC_TIMEOUT— You will need to restart the game after it ends
If you run the game executable file directly without the Stove PC client, error
87(IPC_CONNECT_FAILED) or89(IPC_TIMEOUT) will occur. In this case, you must close the game; once closed, the Stove launcher will launch automatically.
Example
using static Stove.PCSDK.Base;
Result result = Base_SetGameProfile(gameProfile);
if (result.IsSuccessful())
{
// Please implement the logic for when the operation is successful.
}
else if (result.resultCode == Convert.ToUInt32(BaseSDKResultCode.BASE_NOT_INITIALIZED))
{
// Please implement the logic for calling the initialization function first.
}
else
{
// Please implement the logic for other failure scenarios.
}
Notes
POPUP_NOT_CREATED(33) is used in the pop-up's internal cleanup path rather than in the SDK Legacy API itself, and is not passed to the user callback.
See Also
CallbackResult
Kind Struct · Module Base · Version 3.0.0.4
Description
CallbackResult is a structure passed as the first argument to callbacks by the SDK Legacy API—such as Base_Initialize and Base_RestartAppIfNecessaryAsync. The actual success or failure is determined by the internal result field.
Declaration
public struct CallbackResult
{
public Result result;
public string errorMessage;
public int externalError;
}
Members
| Name | Type | Description |
|---|---|---|
result | Result | A struct containing the result code. These are lowercase fields. |
errorMessage | string | Error Message |
externalError | int | External (such as native transport layer) error code. Example: When BaseSDKResultCode.NETWORK_TRANSPORT_ERROR(249) is specified, a WinHTTP native error code is included. |
Example
using static Stove.PCSDK.Base;
void OnInitializeFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
Notes
- The result is
callbackResult.result.IsSuccessful().resultis a lowercase field, andIsSuccessful()is a method. - The
IStoveCallbackResultof the new C# interface (Stove.PCSDK.V3) uses theResultproperty (capitalized), so its notation differs from that of the old interface.
See Also
DiscountType
Kind Enum · Module IAP · Version 3.0.0.4
Description
Stored in the StovePCProduct.discountType / StovePCProductEx.discountType fields, this indicates whether the discount method (isDiscount == true) is a percentage or a fixed amount when the product is on sale.
Declaration
public enum DiscountType
{
NONE = 0,
FIXED_RATE = 1,
FLAT_RATE,
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | NONE | The discount has not been applied. |
| 1 | FIXED_RATE | This is a fixed-rate discount. |
| 2 | FLAT_RATE | This is a flat-rate discount. |
Example
using static Stove.PCSDK.IAP;
void CheckDiscount(StovePCProduct product)
{
if (product.isDiscount && product.discountType == DiscountType.FIXED_RATE)
{
// Please implement the logic to display a fixed-rate discount. `discountTypeValue` represents the discount rate.
}
}
Notes
- It is used in conjunction with the
discountTypeValuefield. A value ofFIXED_RATEindicates a percentage, while a value ofFLAT_RATEindicates a fixed amount.
See Also
IAP_CloseAllPopups
Kind Function · Module IAP · Version 3.1.3
Description
If any web view pop-ups triggered by the payment feature (such as purchase, payment, terms and conditions agreement, or game withdrawal) are open, close them all.
It must be called after IAP_Initialize.
Declaration
public static Result IAP_CloseAllPopups()
Parameters
None
Returns
| Type | Description |
|---|---|
| Result | Here are the results of the call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
The value of Result.methodCode is Convert.ToUInt32(IAPSDKMethod.CLOSE_ALL_POPUPS).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP is not initialized | x | |
| 80 | VIEWUI_NOT_INITIALIZED | The WebView of the popup to be closed has not been initialized | x | |
| 89 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all open pop-ups | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | There was a temporary issue. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
Result result = IAP_CloseAllPopups();
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- Use this when you need to close all open pop-ups at once, such as when exiting a game.
See Also
- IAP_StartPurchase
- IAP_StartPayment
- IAP_WithdrawGame
IAP_ConfirmPurchase
Kind Function · Module IAP · Version 3.0.0.4
Description
Confirms the purchase for the transaction specified as transactionMasterNo. Passes StovePCPurchaseResult.transactionMasterNumber, which was received via the callback from IAP_StartPurchase / IAP_StartPurchaseEx.
It must be called after IAP_Initialize.
Declaration
public static void IAP_ConfirmPurchase(long transactionMasterNo, OnConfirmPurchaseFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
transactionMasterNo | long | Y | This is the master number of the transaction to be confirmed. |
onFinished | OnConfirmPurchaseFinished | Y | This is the callback that will receive the confirmation result. |
Returns
None
Callback
public delegate void OnConfirmPurchaseFinished(CallbackResult callbackResult, bool status, StovePCPurchasedProduct[] purchasedProducts, StovePCChargeInfo[] chargeInfos);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
status | bool | The status is "Pending Confirmation." |
purchasedProducts | StovePCPurchasedProduct[] | This is a list of the items that were actually delivered. |
chargeInfos | StovePCChargeInfo[] | This is a list of the goods deducted as payment for the purchase. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.CONFIRM_PURCHASE).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 21 | NULL_ENTITY | Unable to process the request because language settings could not be verified. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
IAP_ConfirmPurchase(transactionMasterNumber, OnConfirmPurchaseFinished);
void OnConfirmPurchaseFinished(CallbackResult callbackResult, bool status, StovePCPurchasedProduct[] purchasedProducts, StovePCChargeInfo[] chargeInfos)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
Notes
transactionMasterNois obtained from the callback result of the IAP_StartPurchase series API.- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_FetchInventory
Kind Function · Module IAP · Version 3.0.0.4
Description
Displays a list of the items in the user's inventory.
It must be called after IAP_Initialize.
Declaration
public static void IAP_FetchInventory(OnFetchInventoryFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnFetchInventoryFinished | Y | This is the callback that will receive the query results. |
Returns
None
Callback
public delegate void OnFetchInventoryFinished(CallbackResult callbackResult, StovePCInventoryItem[] inventoryItems);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
inventoryItems | StovePCInventoryItem[] | This is the list of inventory items found. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.FETCH_INVENTORY).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must first call IAP_Initialize. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
IAP_FetchInventory(OnFetchInventoryFinished);
void OnFetchInventoryFinished(CallbackResult callbackResult, StovePCInventoryItem[] inventoryItems)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
Notes
- You must repeatedly call
Base_RunCallback()within the game loop for the callback to be passed.
See Also
IAP_FetchProducts
Kind Function · Module IAP · Version 3.0.0.4 · Deprecated
Description
Do not use this default template. Use IAP_FetchProductsEx instead.
Retrieves a list of products within the category and page range specified by productParam.
It must be called after IAP_Initialize.
Declaration
public static void IAP_FetchProducts(StovePCFetchProductParam productParam, OnFetchProductsFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
productParam | StovePCFetchProductParam | Y | These are the criteria for the categories and pages to be retrieved. |
onFinished | OnFetchProductsFinished | Y | This is the callback that will receive the query results. |
Returns
None
Callback
public delegate void OnFetchProductsFinished(CallbackResult callbackResult, StovePCProduct[] products);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
products | StovePCProduct[] | Here is the list of products found. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.FETCH_PRODUCTS).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
StovePCFetchProductParam param = new StovePCFetchProductParam();
param.categoryId = "YOUR_CATEGORY_ID";
param.pageNumber = 1;
param.pageSize = 20;
IAP_FetchProducts(param, OnFetchProductsFinished);
void OnFetchProductsFinished(CallbackResult callbackResult, StovePCProduct[] products)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for when the operation is successful.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
Notes
- Always use IAP_FetchProductsEx for actual integration. The availability code (
purchaseAvailabilityCode) is also only available in theExvariant. - You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_FetchProductsEx
Kind Function · Module IAP · Version 3.4.1
Description
It returns StovePCProductEx[], which has the same input parameters (productParam) as IAP_FetchProducts but includes the purchaseAvailabilityCode field in the query results. It differs from IAP_FetchProducts—which returns StovePCProduct[]—only in the return type.
It must be called after IAP_Initialize.
Declaration
public static void IAP_FetchProductsEx(StovePCFetchProductParam productParam, OnFetchProductsExFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
productParam | StovePCFetchProductParam | Y | These are the criteria for the categories and pages to be retrieved. |
onFinished | OnFetchProductsExFinished | Y | This is the callback that receives the query results. |
Returns
None
Callback
public delegate void OnFetchProductsExFinished(CallbackResult callbackResult, StovePCProductEx[] products);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
products | StovePCProductEx[] | Here is the list of products found. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.FETCH_PRODUCTS).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
StovePCFetchProductParam param = new StovePCFetchProductParam();
param.categoryId = "YOUR_CATEGORY_ID";
param.pageNumber = 1;
param.pageSize = 20;
IAP_FetchProductsEx(param, OnFetchProductsExFinished);
void OnFetchProductsExFinished(CallbackResult callbackResult, StovePCProductEx[] products)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
Notes
- If
purchaseAvailabilityCodeis not needed, use IAP_FetchProducts. - You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_FetchShopCategories
Kind Function · Module IAP · Version 3.0.0.4
Description
Retrieves the list of categories registered in the store. The retrieved category ID is used in StovePCFetchProductParam.categoryId of IAP_FetchProducts / IAP_FetchProductsEx.
It must be called after IAP_Initialize.
Declaration
public static void IAP_FetchShopCategories(OnFetchShopCategoriesFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnFetchShopCategoriesFinished | Y | This is the callback that will receive the query results. |
Returns
None
Callback
public delegate void OnFetchShopCategoriesFinished(CallbackResult callbackResult, StovePCShopCategory[] shopCategories);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
shopCategories | StovePCShopCategory[] | Here is a list of the categories found. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.FETCH_SHOP_CATEGORIES).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
IAP_FetchShopCategories(OnFetchShopCategoriesFinished);
void OnFetchShopCategoriesFinished(CallbackResult callbackResult, StovePCShopCategory[] shopCategories)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
Notes
- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_FetchTermsAgreement
Kind Function · Module IAP · Version 3.0.0.4
Description
Checks whether the user has agreed to the terms and conditions. Depending on how option operates, a web view pop-up for agreeing to the terms and conditions may appear.
It must be called after IAP_Initialize.
Declaration
public static void IAP_FetchTermsAgreement(StovePCTermsOption option, OnFetchTermsAgreementFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
option | StovePCTermsOption | Y | This describes how the terms and conditions consent pop-up works, as well as its position and size. |
onFinished | OnFetchTermsAgreementFinished | Y | This is the callback that will receive the query results. |
Returns
None
Callback
public delegate void OnFetchTermsAgreementFinished(CallbackResult callbackResult, bool agreed, string url);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
agreed | bool | Whether you have agreed to the terms and conditions. |
url | string | This is the URL for the Terms and Conditions consent web view. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.FETCH_TERMS_AGREEMENT).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView that displays the terms and conditions consent pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a web view for the Terms of Service agreement pop-up | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the Terms of Service consent pop-up web view | x | |
| 87 | WEBVIEW_CREATE_COOKIE_FAIL | The host address on the Terms and Conditions agreement screen could not be found. | O | You must agree to the terms and conditions to complete your purchase. We were unable to load the terms and conditions screen. Please try again. [OK] |
| 89 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCTermsOption option = new StovePCTermsOption();
option.operation = StovePCTermsOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewWidth = 800;
option.webviewHeight = 600;
IAP_FetchTermsAgreement(option, OnFetchTermsAgreementFinished);
void OnFetchTermsAgreementFinished(CallbackResult callbackResult, bool agreed, string url)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
Notes
- If you need to detect when the popup closes (destroy) separately, use IAP_FetchTermsAgreementEx.
- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_FetchTermsAgreementEx
Kind Function · Module IAP · Version 3.3.4
Description
Just like IAP_FetchTermsAgreement, it checks whether the terms and conditions have been accepted, but it also receives an additional callback, onDestroy, which is triggered when the terms and conditions pop-up is closed. The remaining parameters and the result callback (onFinished) are the same as those for IAP_FetchTermsAgreement.
It must be called after IAP_Initialize.
Declaration
public static void IAP_FetchTermsAgreementEx(StovePCTermsOption option, OnFetchTermsAgreementFinished onFinished, OnIAPPopupDestroyFinished onDestroy)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
option | StovePCTermsOption | Y | This describes how the terms and conditions consent pop-up works, as well as its position and size. |
onFinished | OnFetchTermsAgreementFinished | Y | This is the callback that will receive the query results. |
onDestroy | OnIAPPopupDestroyFinished | N | This is a callback that is triggered when the terms and conditions consent pop-up closes. |
Returns
None
Callback
public delegate void OnFetchTermsAgreementFinished(CallbackResult callbackResult, bool agreed, string url);
public delegate void OnIAPPopupDestroyFinished(CallbackResult callbackResult);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
agreed | bool | This indicates whether you agree to the terms and conditions provided in onFinished. |
url | string | This is the URL of the web view for agreeing to the terms and conditions, which is passed to onFinished. |
Both callbacks run on the thread that called Base_RunCallback(). onFinished is called when the query is complete, and onDestroy is called when the terms and conditions pop-up is closed.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.FETCH_TERMS_AGREEMENT).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the terms and conditions consent pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a web view for the Terms of Service agreement pop-up | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the Terms of Service consent pop-up web view | x | |
| 87 | WEBVIEW_CREATE_COOKIE_FAIL | The host address on the Terms and Conditions agreement screen could not be found. | O | You must agree to the terms and conditions to make a purchase. We were unable to load the terms and conditions screen. Please try again. [OK] |
| 89 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups | x | |
| 90 | WEBVIEW_CLOSE_FAIL | Failed to close the popup (passed to the onDestroy callback) | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | There was a temporary issue. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCTermsOption option = new StovePCTermsOption();
option.operation = StovePCTermsOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewWidth = 800;
option.webviewHeight = 600;
IAP_FetchTermsAgreementEx(option, OnFetchTermsAgreementFinished, OnIAPPopupDestroyFinished);
void OnFetchTermsAgreementFinished(CallbackResult callbackResult, bool agreed, string url)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnIAPPopupDestroyFinished(CallbackResult callbackResult)
{
// Please implement the logic that runs when the terms and conditions consent pop-up is closed.
}
Notes
- If you don't need to detect when the pop-up closes, use IAP_FetchTermsAgreement.
- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_FetchVoidedPurchases
Kind Function · Module IAP · Version 3.0.0.4 · Deprecated
Description
The refund inquiry feature has been deprecated. It is not available in the new interface. It remains available only in the existing interface.
View a list of purchases that have been canceled (refunded) on the marketplace.
It must be called after IAP_Initialize.
Declaration
public static void IAP_FetchVoidedPurchases(OnFetchVoidedPurchasesFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnFetchVoidedPurchasesFinished | Y | This is the callback that will receive the query results. |
Returns
None
Callback
public delegate void OnFetchVoidedPurchasesFinished(CallbackResult callbackResult, StovePCVoidedPurchase[] voidedPurchase);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
voidedPurchase | StovePCVoidedPurchase[] | This is a list of canceled purchases. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.FETCH_VOIDED_PURCHASES).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
IAP_FetchVoidedPurchases(OnFetchVoidedPurchasesFinished);
void OnFetchVoidedPurchasesFinished(CallbackResult callbackResult, StovePCVoidedPurchase[] voidedPurchase)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
Notes
- The IAP_FetchVoidedPurchasesEx feature, which allows you to filter and view results by market, is not currently available in the SDK.
- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_FetchVoidedPurchasesEx
Kind Function · Module IAP · Version 3.4.1 · Deprecated
Description
This function is not currently available in the SDK. The refund inquiry feature itself has been deprecated.
Unlike IAP_FetchVoidedPurchases, you can specify the market to query using the marketType parameter, and it returns StovePCVoidedPurchasesEx[], which includes additional fields such as member ID and GUID in the query results.
It must be called after IAP_Initialize.
Declaration
public static void IAP_FetchVoidedPurchasesEx(StovePCVoidedPurchasesMarketType marketType, OnFetchVoidedPurchasesExFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
marketType | StovePCVoidedPurchasesMarketType | Y | This is the market you want to view. |
onFinished | OnFetchVoidedPurchasesExFinished | Y | This is the callback that receives the query results. |
Returns
None
Callback
public delegate void OnFetchVoidedPurchasesExFinished(CallbackResult callbackResult, StovePCVoidedPurchasesEx[] voidedPurchase);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
voidedPurchase | StovePCVoidedPurchasesEx[] | This is a list of canceled purchases. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.FETCH_VOIDED_PURCHASES).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| — | — | This function is not currently available in the SDK. | — | — |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
IAP_FetchVoidedPurchasesEx(StovePCVoidedPurchasesMarketType.STEAM, OnFetchVoidedPurchasesExFinished);
void OnFetchVoidedPurchasesExFinished(CallbackResult callbackResult, StovePCVoidedPurchasesEx[] voidedPurchase)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for the success case.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
Notes
- To view results without filtering by market, pass
StovePCVoidedPurchasesMarketType.ALLtomarketType. - You must call
Base_RunCallback()repeatedly within the game loop for the callback to be triggered.
See Also
IAP_GetVersion
Kind Function · Module IAP · Version 3.4.1
Description
It retrieves the version string from the payment module and returns it by filling in version.
Declaration
public static Result IAP_GetVersion(ref string version, uint length)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
version | ref string | Y | This is a reference variable that receives the version string. After the call, this variable is assigned the version value. |
length | uint | Y | The size (in characters) of the buffer that will hold the version string. |
Returns
| Type | Description |
|---|---|
| Result | Here are the results of the call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
The value of Result.methodCode is Convert.ToUInt32(IAPSDKMethod.GET_VERSION).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | version No buffer, length is 0, or the buffer size is insufficient to hold the string | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to check the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | There was a temporary issue. Please try again. [OK] |
This function actually returns the BaseSDK integrated version as-is, rather than IAPSDK itself. For a complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
string version = string.Empty;
Result result = IAP_GetVersion(ref version, 64);
if (result.IsSuccessful())
{
// Please implement the logic for when the operation succeeds. The `version` field will be populated with the version string.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
lengthmust be large enough to hold the string that will be inserted intoversion.
See Also
IAP_Initialize
Kind Function · Module IAP · Version 3.0.0.4
Description
Call this method to initialize the module with the Shop Key before using the payment feature.
In the old interface, you must initialize each module—including the SDK and the payment functionality—separately. You must call this function after initializing the SDK.
Declaration
public static Result IAP_Initialize(string shopKey)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
shopKey | string | Y | This is the store key used to initialize the payment functionality. |
Returns
| Type | Description |
|---|---|
| Result | Here are the results of the call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
The value of Result.methodCode is Convert.ToUInt32(IAPSDKMethod.INITIALIZE).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 16 | BASE_NOT_INITIALIZED | BaseSDK has not been initialized. You must call Base_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | IAP is already initialized | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView that displays the payment pop-up | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to verify the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | There was a temporary issue. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
Result result = IAP_Initialize("YOUR_SHOP_KEY");
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- Use IAP_InitializeWithWndInfo to pass the main window handle along with it.
- Be sure to call IAP_UnInitialize when the process ends.
See Also
IAP_InitializeWithWndInfo
Kind Function · Module IAP · Version 3.3.3
Description
Just like IAP_Initialize, this resets the payment functionality, but it also passes the handle of the main window via the mainWndHandle parameter.
In the old interface, you must initialize each module—including the payment functionality—separately, in addition to the SDK. You must call this function after initializing the SDK.
Declaration
public static Result IAP_InitializeWithWndInfo(string shopKey, IntPtr mainWndHandle)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
shopKey | string | Y | This is the store key used to initialize the payment functionality. |
mainWndHandle | IntPtr | Y | This is the handle for the main window. |
Returns
| Type | Description |
|---|---|
| Result | Here are the results of the call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
The value of Result.methodCode is Convert.ToUInt32(IAPSDKMethod.INITIALIZE).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 16 | BASE_NOT_INITIALIZED | BaseSDK was not initialized. You must call Base_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | IAP is already initialized | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the payment pop-up | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to verify the version because the SDK file path could not be found | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
Result result = IAP_InitializeWithWndInfo("YOUR_SHOP_KEY", mainWindowHandle);
if (result.IsSuccessful())
{
// Please implement the logic for when the operation succeeds.
}
else
{
// Please implement the logic for when a failure occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- If you don't need the main window handle, use IAP_Initialize.
- Be sure to call IAP_UnInitialize when the process ends.
See Also
IAP_StartPayment
Kind Function · Module IAP · Version 3.0.0.4 · Deprecated
Description
This feature is deprecated. Please use IAP_StartPurchase instead.
We request payment using the method specified as option. Depending on how it works, a payment web view pop-up may appear.
It must be called after IAP_Initialize.
Declaration
public static void IAP_StartPayment(StovePCPaymentOption option, OnStartPaymentFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
option | StovePCPaymentOption | Y | How the payment pop-up works, as well as its position and size. |
onFinished | OnStartPaymentFinished | Y | This is the callback that will receive the payment result. |
Returns
None
Callback
public delegate void OnStartPaymentFinished(CallbackResult callbackResult, string url);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
url | string | This is the URL for the payment web view. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.START_PAYMENT).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the payment pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create the payment pop-up web view | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the payment pop-up web view | x | |
| 89 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCPaymentOption option = new StovePCPaymentOption();
option.operation = StovePCPaymentOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewWidth = 800;
option.webviewHeight = 600;
IAP_StartPayment(option, OnStartPaymentFinished);
void OnStartPaymentFinished(CallbackResult callbackResult, string url)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
Notes
- If you need to detect when the popup closes (destroy) separately, use IAP_StartPaymentEx.
- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be triggered.
See Also
IAP_StartPaymentEx
Kind Function · Module IAP · Version 3.3.4 · Deprecated
Description
This feature is deprecated. Please use IAP_StartPurchaseEx instead.
It requests payment in the same way as IAP_StartPayment, but also receives an additional callback (onDestroy) that is triggered when the payment pop-up closes. The remaining parameters and the result callback (onFinished) are the same as in IAP_StartPayment.
It must be called after IAP_Initialize.
Declaration
public static void IAP_StartPaymentEx(StovePCPaymentOption option, OnStartPaymentFinished onFinished, OnIAPPopupDestroyFinished onDestroy)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
option | StovePCPaymentOption | Y | How the payment pop-up works, as well as its position and size. |
onFinished | OnStartPaymentFinished | Y | This is the callback that will receive the payment result. |
onDestroy | OnIAPPopupDestroyFinished | N | This is a callback that is called when the payment pop-up closes. |
Returns
None
Callback
public delegate void OnStartPaymentFinished(CallbackResult callbackResult, string url);
public delegate void OnIAPPopupDestroyFinished(CallbackResult callbackResult);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
url | string | This is the URL of the payment web view passed to onFinished. |
Both callbacks run on the thread that called Base_RunCallback(). onFinished is called when the request is processed, and onDestroy is called when the payment pop-up is closed.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.START_PAYMENT).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView that displays the payment pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create the payment pop-up web view | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the payment pop-up web view | x | |
| 89 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups | x | |
| 90 | WEBVIEW_CLOSE_FAIL | Failed to close the popup (passed to the onDestroy callback) | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCPaymentOption option = new StovePCPaymentOption();
option.operation = StovePCPaymentOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewWidth = 800;
option.webviewHeight = 600;
IAP_StartPaymentEx(option, OnStartPaymentFinished, OnIAPPopupDestroyFinished);
void OnStartPaymentFinished(CallbackResult callbackResult, string url)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnIAPPopupDestroyFinished(CallbackResult callbackResult)
{
// Please implement the logic that runs when the payment pop-up closes.
}
Notes
- If you don't need to detect when the pop-up closes, use IAP_StartPayment.
- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_StartPurchase
Kind Function · Module IAP · Version 3.0.0.4
Description
Requests purchase of the products listed in startPurchaseParam. Depending on the purchase options, a web view pop-up may appear.
It must be called after IAP_Initialize.
Declaration
public static void IAP_StartPurchase(StovePCStartPurchaseParam startPurchaseParam, OnStartPurchaseFinished onFinished)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
startPurchaseParam | StovePCStartPurchaseParam | Y | Here is the list of items to purchase and the pop-up options. |
onFinished | OnStartPurchaseFinished | Y | This is the callback function that will receive the purchase results. |
Returns
None
Callback
public delegate void OnStartPurchaseFinished(CallbackResult callbackResult, StovePCPurchaseResult purchase);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
purchase | StovePCPurchaseResult | Here are the results of your purchase. |
This callback runs in the thread that called Base_RunCallback(). It runs once per call.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.START_PURCHASE).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView that displays the purchase pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create the purchase pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the purchase pop-up web view | x | |
| 84 | WEBVIEW_CLOSED_BEFORE_PURCHASE | The pop-up was closed before the purchase was completed | O | The purchase was not completed successfully. Please try again. [OK] |
| 85 | PARAMETER_LENGTH_EXCEEDED | The length of serviceTxnNo or extraData exceeds the allowed range. | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 86 | INVALID_JSON_STRING | extraData is not in the correct JSON format | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 88 | INVALID_ORDER_PRODUCT_INFORMATION | The purchase item information (quantity, salePrice, etc.) is incorrect. | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 89 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups | x | |
| 252 | NOT_IMPLEMENTED | An unknown value was specified for the purchase option (option.operation) | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCOrderProduct orderProduct = new StovePCOrderProduct();
orderProduct.productId = 123456;
orderProduct.salePrice = 1000;
orderProduct.quantity = 1;
StovePCPurchaseOption option = new StovePCPurchaseOption();
option.operation = StovePCPurchaseOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewWidth = 800;
option.webviewHeight = 600;
StovePCStartPurchaseParam purchaseParam = new StovePCStartPurchaseParam();
purchaseParam.products = new StovePCOrderProduct[] { orderProduct };
purchaseParam.productsSize = 1;
purchaseParam.option = option;
purchaseParam.serviceTxnNo = "YOUR_SERVICE_TXN_NO";
purchaseParam.extraData = "";
IAP_StartPurchase(purchaseParam, OnStartPurchaseFinished);
void OnStartPurchaseFinished(CallbackResult callbackResult, StovePCPurchaseResult purchase)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
Notes
- If you need to detect when the popup closes (destroy) separately, use IAP_StartPurchaseEx.
- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_StartPurchaseEx
Kind Function · Module IAP · Version 3.3.4
Description
It requests a purchase in the same way as IAP_StartPurchase, but also receives the onDestroy callback, which is called when the purchase pop-up closes. The remaining parameters and the result callback (onFinished) are the same as in IAP_StartPurchase.
It must be called after IAP_Initialize.
Declaration
public static void IAP_StartPurchaseEx(StovePCStartPurchaseParam startPurchaseParam, OnStartPurchaseFinished onFinished, OnIAPPopupDestroyFinished onDestroy)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
startPurchaseParam | StovePCStartPurchaseParam | Y | Here is the list of items to purchase and the pop-up options. |
onFinished | OnStartPurchaseFinished | Y | This is the callback that will receive the purchase results. |
onDestroy | OnIAPPopupDestroyFinished | N | This is a callback that is triggered when the purchase pop-up closes. |
Returns
None
Callback
public delegate void OnStartPurchaseFinished(CallbackResult callbackResult, StovePCPurchaseResult purchase);
public delegate void OnIAPPopupDestroyFinished(CallbackResult callbackResult);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
purchase | StovePCPurchaseResult | This is the purchase processing result sent to onFinished. |
Both callbacks run on the thread that called Base_RunCallback(). onFinished is called when the purchase is complete, and onDestroy is called when the purchase pop-up is closed.
Error Codes
The value of CallbackResult.result.methodCode is Convert.ToUInt32(IAPSDKMethod.START_PURCHASE).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP has not been initialized. You must call IAP_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView that displays the purchase pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create the purchase pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the purchase pop-up web view | x | |
| 84 | WEBVIEW_CLOSED_BEFORE_PURCHASE | The pop-up was closed before the purchase was completed | O | Your purchase was not completed successfully. Please try again. [OK] |
| 85 | PARAMETER_LENGTH_EXCEEDED | The length of serviceTxnNo or extraData exceeds the allowed range. | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 86 | INVALID_JSON_STRING | extraData is not in the correct JSON format | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 88 | INVALID_ORDER_PRODUCT_INFORMATION | The product information (quantity, salePrice, etc.) is incorrect. | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 89 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups | x | |
| 90 | WEBVIEW_CLOSE_FAIL | Failed to close the popup (passed to the onDestroy callback) | x | |
| 252 | NOT_IMPLEMENTED | An unknown value was specified for the purchase option (option.operation) | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCOrderProduct orderProduct = new StovePCOrderProduct();
orderProduct.productId = 123456;
orderProduct.salePrice = 1000;
orderProduct.quantity = 1;
StovePCPurchaseOption option = new StovePCPurchaseOption();
option.operation = StovePCPurchaseOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewWidth = 800;
option.webviewHeight = 600;
StovePCStartPurchaseParam purchaseParam = new StovePCStartPurchaseParam();
purchaseParam.products = new StovePCOrderProduct[] { orderProduct };
purchaseParam.productsSize = 1;
purchaseParam.option = option;
purchaseParam.serviceTxnNo = "YOUR_SERVICE_TXN_NO";
purchaseParam.extraData = "";
IAP_StartPurchaseEx(purchaseParam, OnStartPurchaseFinished, OnIAPPopupDestroyFinished);
void OnStartPurchaseFinished(CallbackResult callbackResult, StovePCPurchaseResult purchase)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for the success case.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnIAPPopupDestroyFinished(CallbackResult callbackResult)
{
// Please implement the logic that runs when the purchase pop-up closes.
}
Notes
- If you don't need to detect when the pop-up closes, use IAP_StartPurchase.
- You must call
Base_RunCallback()repeatedly within the game loop for the callback to be passed.
See Also
IAP_UnInitialize
Kind Function · Module IAP · Version 3.0.0.4
Description
Terminate the payment module initialized as IAP_Initialize / IAP_InitializeWithWndInfo.
In the old interface, you must initialize and terminate each module—including the SDK and payment features—individually. You must call this function before exiting the game.
Declaration
public static Result IAP_UnInitialize()
Parameters
None
Returns
| Type | Description |
|---|---|
| Result | Here are the results of the call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
The value of Result.methodCode is Convert.ToUInt32(IAPSDKMethod.UNINITIALIZE).
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | IAP is not initialized | x | |
| 81 | VIEWUI_UNINIT_FAILED | Failed to close the payment web view | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see IAPSDKResultCode.
Example
using static Stove.PCSDK.IAP;
Result result = IAP_UnInitialize();
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- This is the termination function that pairs with IAP_Initialize / IAP_InitializeWithWndInfo.
See Also
IAPSDKMethod
Kind Enum · Module IAP · Version 3.0.0.4
Description
This value identifies each API in the payment functionality. If an exception occurs within an API, it is converted to Convert.ToUInt32(IAPSDKMethod.Xxx) and stored in the methodCode field of Result or the result.methodCode field of CallbackResult.
The value itself has no bearing on success or failure; it is used to identify which API call caused an error when one occurs.
Declaration
public enum IAPSDKMethod
{
INITIALIZE = 1,
UNINITIALIZE = 2,
GET_VERSION = 5,
// ... See the "Values" table below
WITHDRAW_GAME = 89,
}
Enum Values
| Code | Name | Description |
|---|---|---|
| 1 | INITIALIZE | IAP_Initialize / IAP_InitializeWithWndInfo |
| 2 | UNINITIALIZE | IAP_UnInitialize |
| 5 | GET_VERSION | IAP_GetVersion |
| 80 | FETCH_SHOP_CATEGORIES | IAP_FetchShopCategories |
| 81 | FETCH_PRODUCTS | IAP_FetchProducts / IAP_FetchProductsEx |
| 82 | START_PURCHASE | IAP_StartPurchase / IAP_StartPurchaseEx |
| 83 | CONFIRM_PURCHASE | IAP_ConfirmPurchase |
| 84 | FETCH_INVENTORY | IAP_FetchInventory |
| 85 | FETCH_TERMS_AGREEMENT | IAP_FetchTermsAgreement / IAP_FetchTermsAgreementEx |
| 86 | START_PAYMENT | IAP_StartPayment / IAP_StartPaymentEx |
| 87 | FETCH_VOIDED_PURCHASES | IAP_FetchVoidedPurchases / IAP_FetchVoidedPurchasesEx |
| 88 | CLOSE_ALL_POPUPS | IAP_CloseAllPopups |
| 89 | WITHDRAW_GAME | IAP_WithdrawGame — For Lost Ark Mobile only |
INTERNAL_SEND_81PLUG(3) and INTERNAL_UPDATE_81PLUG(4) are for internal use only and are not included in this document.
The value numbers are divided into two ranges: 1–5 (module-common APIs) and 80–89 (payment-function-specific APIs); numbers outside these ranges are not used.
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
void OnInitializeChecked(Result result)
{
if (!result.IsSuccessful() && result.methodCode == Convert.ToUInt32(IAPSDKMethod.INITIALIZE))
{
// Please implement the logic for when the IAP_Initialize call fails.
}
}
Notes
- Since
Result.methodCodeandCallbackResult.result.methodCodeare of typeuint, they must be converted toConvert.ToUInt32(IAPSDKMethod.Xxx)for comparison. - Since other modules also have their own separate
XxxSDKMethodenumerations, the numbers may overlap.
See Also
IAPSDKResultCode
Kind Result Code · Module IAP · Version 3.0.0.4
Description
This is the response code returned by all APIs in the payment functionality for the Result field in resultCode or the result.resultCode field in CallbackResult.
If the result is 0(SUCCESS), it is considered a success, and the result is evaluated as Result.IsSuccessful() / CallbackResult.result.IsSuccessful(). Any other value indicates a failure.
Declaration
public enum IAPSDKResultCode
{
SUCCESS = 0,
FAIL = 1,
INVALID_CONFIG = 2,
// ... See the "Values" table below
WEBVIEW_CLOSE_ALL_FAIL = 89,
}
Enum Values
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 1 | FAIL | This is a general error. Please try again or contact us. | x | |
| 2 | INVALID_CONFIG | The settings are incorrect. Please check the settings in the caller. | x | |
| 3 | INVALID_LOG_LEVEL | The log level value is incorrect. You must check the settings in the calling section. | x | |
| 4 | INVALID_LOG_PATH | The log path is incorrect. You need to check the caller settings. | x | |
| 5 | INVALID_PARAM | The parameters passed are incorrect. Please check the calling parameters. | x | |
| 16 | BASE_NOT_INITIALIZED | The SDK has not been initialized. You must first call Base_Initialize. | x | |
| 17 | NOT_INITIALIZED | The payment function has not been initialized. You must first call IAP_Initialize. | x | |
| 18 | ALREADY_INITIALIZED | The payment feature is already initialized. You must remove the duplicate initialization call. | x | |
| 19 | INVALID_ACCESS_TOKEN | The access token is invalid. You must log in again or refresh the token. | O | Your login session has expired. Please close the game and restart it. [OK] |
| 20 | NULL_TOKEN_ENTITY | The token information is empty. You must log in again or renew the token. | x | |
| 21 | NULL_ENTITY | The required data is missing. | x | |
| 22 | HTTP_ERROR | An HTTP communication error has occurred. Please check your network connection and try again. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 23 | RESPONSE_ERROR | An error occurred while processing the server response. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 24 | RESPONSE_INVALID_CODE | The server response code is incorrect. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 25 | RESPONSE_VALUE_IS_NULL | The server response is empty. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 26 | RESPONSE_INVALID_VALUE_FORMAT | The format of the server response is incorrect. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 27 | LOG_81PLUG_ERROR | This is an 81Plug log transmission error. | x | |
| 28 | UPDATE_81PLUG_FEED_ERROR | Error updating the 81Plug feed | x | |
| 29 | ASYNC_OPERATION_IN_PROGRESS | An asynchronous task is already in progress. You must call this method again after the previous request has finished. | x | |
| 30 | BASE_UNINITIALIZED | The SDK has already been uninitialized. Please check the call sequence. | x | |
| 31 | NOT_SUPPORTED_COUNTRY | This country is not supported. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | The pop-up UI is not initialized. You need to check the initialization sequence. | x | |
| 81 | VIEWUI_UNINIT_FAILED | Failed to close the pop-up UI | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | The WebView was unable to load the URL. Please check your network connection and try again. | x | |
| 84 | WEBVIEW_CLOSED_BEFORE_PURCHASE | The WebView closed before the purchase was completed. The user should be prompted to cancel. | O | The purchase was not completed successfully. Please try again. [OK] |
| 85 | PARAMETER_LENGTH_EXCEEDED | The parameter length exceeds the allowed range. Please check the parameters in the calling code. | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 86 | INVALID_JSON_STRING | The JSON string is invalid. | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 87 | WEBVIEW_CREATE_COOKIE_FAIL | Failed to create a WebView cookie | O | You must agree to the terms and conditions to complete your purchase. We were unable to load the terms and conditions screen. Please try again. [OK] |
| 88 | INVALID_ORDER_PRODUCT_INFORMATION | The order details are incorrect. Please verify the product information in the call section. | O | The payment information is invalid, so we cannot process the payment. Please try again. [OK] |
| 89 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all WebViews | x | |
| 251 | PCSDK_DLL_NOT_FOUND | The PCSDK native DLL could not be found. Please check the installation path. | x | |
| 252 | NOT_IMPLEMENTED | This feature has not been implemented. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred in the native (unmanaged) layer. | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred in the .NET (managed) layer | O | A temporary issue has occurred. Please try again. [OK] |
| 255 | UNKNOWN_ERROR | An unknown error has occurred. | x |
If you receive the code below, you must exit the game. The game cannot proceed normally.
19INVALID_ACCESS_TOKEN— Your login session has expired; please close the game and restart it.
Error codes are divided into the following ranges: 0–31 (module-specific errors), 80–89 (payment-function-specific errors), and 251–255 (system/exception errors); codes outside these ranges are not used.
Example
using static Stove.PCSDK.IAP;
void OnFetchProductsFinished(CallbackResult callbackResult, StovePCProduct[] products)
{
if (!callbackResult.result.IsSuccessful())
{
if (callbackResult.result.resultCode == (uint)IAPSDKResultCode.NOT_INITIALIZED)
{
// Please implement the logic for cases where IAP_Initialize must be called first.
}
return;
}
}
Notes
- Although the range
80–89contains the same number range (e.g.,LANGUAGE_NOT_SET) in BaseSDKResultCode, they belong to different enumeration types; therefore, while the numbers are the same, their meanings differ. You must also check IAPSDKMethod to determine which module’s API returned the value. - There are two values that are not defined in this enumeration but are present in SDKResultCode of the native payment functionality.
90(WEBVIEW_CLOSE_FAIL, Failed to close WebView) is a code that may actually be returned during the payment process. When this code occurs, the unnamed number90is passed as-is to theresultCodefield; therefore, the developer must handle the branch based on the value itself (the integer90).33(POPUP_NOT_CREATED) is an internal cleanup code used when a popup (WebView) is closed without being created; since the SDK wrapper intercepts it and does not pass it to the user's callback, you will never actually receive this value.
See Also
Log_GetVersion
Kind Function · Module Log · Version 3.4.1
Description
Retrieves version information for the logging feature.
It fills the variable provided by the caller with the version string and returns it.
Declaration
public static Result Log_GetVersion(ref string version, uint length);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
version | ref string | Y | This is the variable that will hold the version string. Its value before the call is ignored and is replaced with the result string after the call. |
length | uint | Y | This is the length of the string buffer used internally. |
Returns
| Type | Description |
|---|---|
Result | Here are the results of the API call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | version No buffer, length is 0, or the buffer size is insufficient to hold the string | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to check the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
This function actually returns the BaseSDK integrated version as-is, rather than the LogSDK version itself. For a complete list, see LogSDKResultCode.
Example
using static Stove.PCSDK.Log;
string version = null;
Result result = Log_GetVersion(ref version, 64);
if (result.IsSuccessful())
{
// Please implement the logic for when the operation is successful. Use the `version` parameter.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
See Also
Log_Initialize
Kind Function · Module Log · Version 3.4.1
Description
Resets the log function.
You must call this method before calling any other APIs in this module. Since the code LogSDKResultCode.BASE_NOT_INITIALIZED is present, the SDK must be initialized first.
Declaration
public static Result Log_Initialize();
Parameters
None
Returns
| Type | Description |
|---|---|
Result | Here are the results of the API call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 16 | BASE_NOT_INITIALIZED | BaseSDK has not been initialized. You must call Base_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | The log feature is already initialized. | x | |
| 80 | LOCAL_DB_CREATE_WORKING_DIRECTORY_FAILED | Failed to create the local working directory to store logs | x | |
| 81 | LOCAL_DB_CONNECT_FAILED | Failed to connect to the local database for log storage | x | |
| 82 | LOCAL_DB_CREATE_TABLE_FAILED | Failed to create a local DB table for log storage | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to verify the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see LogSDKResultCode.
Example
using static Stove.PCSDK.Log;
Result result = Log_Initialize();
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- When you are finished using the module, you must call Log_UnInitialize to clean up the resources.
- The logging feature was added to the entire module in version 3.4.1.
See Also
Log_Send
Kind Function · Module Log · Version 3.4.1
Description
Sends logs to the STOVE log server. The value stored in StovePCLogSendParam is sent as-is as a log entry.
You must initialize it to Log_Initialize before calling it.
Declaration
public static void Log_Send(StovePCLogSendParam logSendParam, OnLogSendFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
logSendParam | StovePCLogSendParam | Y | The value of the log entry to be transmitted. |
onFinished | OnLogSendFinished | Y | This is a callback that receives the transmission results. |
Returns
None
Callback
public delegate void OnLogSendFinished(CallbackResult callbackResult);
| Name | Type | Description |
|---|---|---|
callbackResult | CallbackResult | Here are the results of the transmission call. Check callbackResult.result.IsSuccessful() to see if it was successful. |
The callback runs in the thread that called Base_RunCallback() and is passed once for each call to Log_Send().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | A log entry is recorded in the local database (this does not indicate that the data was successfully transmitted to the server) | x | |
| 17 | NOT_INITIALIZED | The log function has not been initialized. You must first call Log_Initialize. | x | |
| 84 | LOCAL_DB_BACKUP_LOG_FAILED | Failed to write logs to the local database | x | |
| 85 | INVALID_LOG_PARAMETER | contents is not in the correct JSON format | x | |
| 86 | LOG_SIZE_EXCEEDED | The log content size exceeds the allowed limit (50 KB). | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | There was a temporary issue. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check callbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see LogSDKResultCode.
Example
using static Stove.PCSDK.Log;
void OnLogSendFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
var logSendParam = new StovePCLogSendParam
{
auid = auid,
cuid = cuid,
gameVersion = "1.2.3",
contents = "{\"event\":\"login\"}"
};
Log_Send(logSendParam, OnLogSendFinished);
Notes
- This function is asynchronous, and the callback is executed once on the thread that calls
Base_RunCallback(). - Fields with unknown values can be left with their default values (the number 0, the string
null, or an empty value). - The logging feature was added to the entire module in version 3.4.1.
onFinishedThe callback is invoked atSUCCESSwhen the log is written to the local database. The actual transmission to the STOVE log server is handled separately, and even if the transmission to the server fails, this callback will not be triggered.- Except for failures when writing to the local database (such as
LOCAL_DB_BACKUP_LOG_FAILED), this callback virtually always returns a success. We recommend that you do not design your game logic to branch based on the result of this callback.
See Also
Log_UnInitialize
Kind Function · Module Log · Version 3.4.1
Description
Releases resources used by the logging feature.
This function cleans up resources initialized with Log_Initialize and should be called when you are done using the module.
Declaration
public static Result Log_UnInitialize();
Parameters
None
Returns
| Type | Description |
|---|---|
Result | Here are the results of the API call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The log feature is not initialized. | x | |
| 83 | LOCAL_DB_DISCONNECT_FAILED | Failed to disconnect from the local database used for log storage | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see LogSDKResultCode.
Example
using static Stove.PCSDK.Log;
Result result = Log_UnInitialize();
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- This is the function that pairs with Log_Initialize.
- The logging feature was added to the entire module in version 3.4.1.
See Also
LogSDKMethod
Kind Enum · Module Log · Version 3.4.1
Description
This identifies which logging function produced the result, based on the value returned as Result.methodCode or CallbackResult.result.methodCode.
Declaration
public enum LogSDKMethod
{
INITIALIZE = 1,
UNINITIALIZE = 2,
GET_VERSION = 5,
SEND = 80,
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 1 | INITIALIZE | This is the result created by Log_Initialize. |
| 2 | UNINITIALIZE | This is the result created by Log_UnInitialize. |
| — | 3, 4 | Not in use (reserved number) |
| 5 | GET_VERSION | This is the result created by Log_GetVersion. |
| — | 6 ~ 79 | Not in use (reserved number) |
| 80 | SEND | This is the result created by Log_Send. |
Example
if (callbackResult.result.methodCode == Convert.ToUInt32(LogSDKMethod.SEND))
{
// Here are the results from Log_Send.
}
Notes
- Since
Result.methodCodeis auintfield, you must convert it toConvert.ToUInt32()or similar when comparing it to this enumeration value.
See Also
LogSDKResultCode
Kind Result Code · Module Log · Version 3.4.1
Description
This is the value returned as Result.resultCode or CallbackResult.result.resultCode. A value of 0 (SUCCESS) indicates success; any other value indicates failure.
The first part (0–31, 251–255) consists of common code shared with other PCSDK legacy modules, while values 80 and above are error codes specific to the logging feature.
Declaration
public enum LogSDKResultCode
{
SUCCESS = 0,
FAIL = 1,
// ... See the "Values" table below
LOG_SIZE_EXCEEDED = 86,
}
Enum Values
Shared Code
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 1 | FAIL | General failure. Check log/exceptionMessage for the detailed cause. | x | |
| 2 | INVALID_CONFIG | The setting is invalid. Please check the setting. | x | |
| 3 | INVALID_LOG_LEVEL | The log level value is invalid. Please verify the log level value. | x | |
| 4 | INVALID_LOG_PATH | The log path is invalid. Please verify the log path. | x | |
| 5 | INVALID_PARAM | The parameter is invalid. Please check the parameter value in the calling code and correct it. | x | |
| — | 6 ~ 15 | Not in use (reserved section) | ||
| 16 | BASE_NOT_INITIALIZED | The SDK has not been initialized. Call Base_Initialize() first. | x | |
| 17 | NOT_INITIALIZED | The log function has not been initialized. Call Log_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | It has already been initialized. Remove the duplicate initialization call. | x | |
| 19 | INVALID_ACCESS_TOKEN | The AccessToken is invalid. Please check if the token needs to be reissued. | O | Your login session has expired. Please close the game and restart it. [OK] |
| 20 | NULL_TOKEN_ENTITY | The token entity is null. Check the token issuance status. | x | |
| 21 | NULL_ENTITY | The entity is null. Check whether the response object is null. | x | |
| 22 | HTTP_ERROR | An HTTP communication error has occurred. Please check your network connection and try again. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 23 | RESPONSE_ERROR | This is a server response error. Please check the server response. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 24 | RESPONSE_INVALID_CODE | The server response code is invalid. Please check the server response code. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 25 | RESPONSE_VALUE_IS_NULL | The server response is empty. Please check the server response. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 26 | RESPONSE_INVALID_VALUE_FORMAT | The server response format is incorrect. Check the server response format. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 27 | LOG_81PLUG_ERROR | 81 Plug transmission failed (Deprecated) | x | |
| 28 | UPDATE_81PLUG_FEED_ERROR | 81 Plug update failed (Deprecated) | x | |
| 29 | ASYNC_OPERATION_IN_PROGRESS | An asynchronous operation is already in progress. Please call again after the current asynchronous operation has completed. | x | |
| 30 | BASE_UNINITIALIZED | The SDK has already been uninitialized. Re-call Base_Initialize(). | x | |
| 31 | NOT_SUPPORTED_COUNTRY | This feature is not currently available in your country or region. Please check the country/region restrictions and stop the call. | x | |
| — | 32 ~ 79 | Not in use (reserved section) |
Unique Code for Logging Functionality
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 80 | LOCAL_DB_CREATE_WORKING_DIRECTORY_FAILED | Failed to create the local DB working directory. Please check the local repository path and permissions. | x | |
| 81 | LOCAL_DB_CONNECT_FAILED | Failed to initialize (connect to) the local database. Please check the status of the local repository and try again. | x | |
| 82 | LOCAL_DB_CREATE_TABLE_FAILED | Failed to create the local database table. Please check the status of the local storage and try again. | x | |
| 83 | LOCAL_DB_DISCONNECT_FAILED | Failed to initialize (disconnect from) the local database. Please check the status of the local storage and try again. | x | |
| 84 | LOCAL_DB_BACKUP_LOG_FAILED | Failed to back up the logs to the local database. Please check the status of the local storage and try again. | x | |
| 85 | INVALID_LOG_PARAMETER | The parameters passed to the log transmission API are invalid. Please check the parameters in the calling code. | x | |
| 86 | LOG_SIZE_EXCEEDED | The log size has exceeded the maximum allowed limit. Please reduce the size of the log and try again. | x | |
| — | 251 ~ 255 | System/Runtime Failure (Generic Code, see below) |
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 251 | PCSDK_DLL_NOT_FOUND | The PC SDK DLL cannot be found. Check the DLL location. | x | |
| 252 | NOT_IMPLEMENTED | This feature has not been implemented. Please remove the call or check for an alternative API. | x | |
| 253 | UNMANAGED_EXCEPTION | An unmanaged exception has occurred. Check the exception log. | O | There was a temporary issue. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | A managed exception has occurred. Check the exception log. | O | There was a temporary issue. Please try again. [OK] |
| 255 | UNKNOWN_ERROR | An unknown error has occurred. Check the detailed log. | x |
If you see the code below, you must exit the game. The game cannot proceed normally.
19INVALID_ACCESS_TOKEN— Your login session has expired; you must exit the game and restart it.
Example
void OnLogSendFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else if (callbackResult.result.resultCode == (uint)LogSDKResultCode.LOG_SIZE_EXCEEDED)
{
// Please implement logic to reduce the log size before resending it.
}
}
Notes
- Since
Result.resultCodeis auintfield, you must convert it using(uint)casting or similar methods when comparing it to this enumeration value. - When Log_Send() fails, error codes 80 through 86 may appear.
See Also
PCBang_CheckPCBangStatus
Kind Function · Module PCBang · Version 3.0.2
Description
Checks whether PC Bang is present and the product's usage status. The result is passed to the callback as StovePCBangStatus.
Declaration
public static void PCBang_CheckPCBangStatus(OnPCBangCheckPCBangStatusOnFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnPCBangCheckPCBangStatusOnFinished | Y | This is the callback that receives the query results. |
Returns
None
Callback
public delegate void OnPCBangCheckPCBangStatusOnFinished(CallbackResult result, StovePCBangStatus stovePCBangStatus);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Here are the results of the query. Check result.result.IsSuccessful() to see if it was successful. |
stovePCBangStatus | StovePCBangStatus | Here is the current status of PC Bang and the product code information. |
The callback runs in the thread that called Base_RunCallback() and is called only once for the query results.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | PC Bang The function has not been initialized. You must call PCBang_Initialize first. | x | |
| 22 | HTTP_ERROR | The network request failed due to an HTTP error | O | The network connection is not working properly. Please check your network status and try again. [OK] |
| 23 | RESPONSE_ERROR | There is an error in the server response. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 25 | RESPONSE_VALUE_IS_NULL | The server response data is empty. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 249 | NETWORK_TRANSPORT_ERROR | An error occurred at the network transport layer. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see PCBangSDKResultCode.
Example
using static Stove.PCSDK.PCBang;
void OnCheckStatusFinished(CallbackResult result, StovePCBangStatus status)
{
if (result.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
PCBang_CheckPCBangStatus(OnCheckStatusFinished);
Notes
- This function is asynchronous, and the callback is executed once on the thread that calls
Base_RunCallback(). - This is a separate lookup API from the login results for PCBang_UserLogin.
See Also
PCBang_GetVersion
Kind Function · Module PCBang · Version 3.0.2
Description
Retrieves version information for the PC Bang function.
It fills the variable provided by the caller with the version string and returns it.
Declaration
public static Result PCBang_GetVersion(ref string version, uint length);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
version | ref string | Y | This is the variable that will receive the version string. Any value it contains before the call is ignored and replaced with the resulting string after the call. |
length | uint | Y | This is the length of the string buffer used internally. |
Returns
| Type | Description |
|---|---|
Result | Here are the results of the API call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | version No buffer, length is 0, or the buffer size is insufficient to hold the string | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to retrieve the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | There was a temporary issue. Please try again. [OK] |
This function actually returns the BaseSDK integrated version as-is, rather than the PCBangSDK version itself. For a complete list, see PCBangSDKResultCode.
Example
using static Stove.PCSDK.PCBang;
string version = null;
Result result = PCBang_GetVersion(ref version, 64);
if (result.IsSuccessful())
{
// Please implement the logic for when the operation succeeds. Use the `version` parameter.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
See Also
PCBang_Initialize
Kind Function · Module PCBang · Version 3.0.2
Description
Initializes the PC Bang function.
You must call this method before calling any other APIs in this module. Since the code PCBangSDKResultCode.BASE_NOT_INITIALIZED is present, the SDK must be initialized first.
Declaration
public static Result PCBang_Initialize();
Parameters
None
Returns
| Type | Description |
|---|---|
Result | Here are the results of the API call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 16 | BASE_NOT_INITIALIZED | BaseSDK has not been initialized. You must call Base_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | PC Bang The feature has already been initialized. | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to verify the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see PCBangSDKResultCode.
Example
using static Stove.PCSDK.PCBang;
Result result = PCBang_Initialize();
if (result.IsSuccessful())
{
// Please implement the logic for the success case.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- When you are finished using the module, you must call PCBang_UnInitialize to clean up the resources.
See Also
PCBang_UnInitialize
Kind Function · Module PCBang · Version 3.0.2
Description
Free up resources for the PC Bang feature.
This function cleans up resources initialized with PCBang_Initialize and should be called when you are finished using the module.
Declaration
public static Result PCBang_UnInitialize();
Parameters
None
Returns
| Type | Description |
|---|---|
Result | Here are the results of the API call. Check result.IsSuccessful() to determine whether it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | PC Bang The feature has not been initialized. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | There was a temporary issue. Please try again. [OK] |
For the complete list, see PCBangSDKResultCode.
Example
using static Stove.PCSDK.PCBang;
Result result = PCBang_UnInitialize();
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- This is a function that pairs with PCBang_Initialize.
See Also
PCBang_UserLogin
Kind Function · Module PCBang · Version 3.0.2
Description
The service logs in the game user via PC Bang. The login result is sent to the onUserLoginFinished callback, and the PC Bang benefit information—which is updated every 4 minutes—is sent to the onRefreshBenefitsFinished callback.
You must initialize it to PCBang_Initialize before calling it.
In actual implementation, both callbacks are registered only when neither is
null. If even one isnull, neither callback is registered.
Declaration
public static void PCBang_UserLogin(OnPCBangUserLoginOnFinished onUserLoginFinished, OnPCBangRefreshUserBenefitsOnFinished onRefreshBenefitsFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onUserLoginFinished | OnPCBangUserLoginOnFinished | Y | This is the callback that receives the login results. |
onRefreshBenefitsFinished | OnPCBangRefreshUserBenefitsOnFinished | Y | This is a callback that receives updated benefit information every 4 minutes. You must specify both callbacks for registration to be complete. |
Returns
None
Callback
Login results and benefit update information are delivered separately via different callbacks.
Login Result Callback
public delegate void OnPCBangUserLoginOnFinished(CallbackResult result, StovePCBangUserLogin stovePCBangUserLogin);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Here are the results of the login request. Check result.result.IsSuccessful() to see if it was successful. |
stovePCBangUserLogin | StovePCBangUserLogin | Here is the login information (Premium status, PC Bang serial number, time remaining). |
Benefit Renewal Callback
public delegate void OnPCBangRefreshUserBenefitsOnFinished(CallbackResult result, StovePCRefreshUserBenefits stovePCRefreshUserBenefits);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Here are the results of your benefit renewal. |
stovePCRefreshUserBenefits | StovePCRefreshUserBenefits | Here is the updated benefit information (premium status, time remaining). |
Both callbacks run on the thread that called Base_RunCallback().
onUserLoginFinishedis called for each login request.onRefreshBenefitsFinishedis called every 4 minutes to provide updated benefit information.- If you call
PCBang_UserLoginagain, the previously registered benefit renewal callback will be replaced with the new callback.
Error Codes
The value of result.methodCode in the login results is PCBangSDKMethod.USER_LOGIN, and the value of result.methodCode in the benefit renewal results is PCBangSDKMethod.REFRESH_USER_BENEFITS.
Both callbacks use the same code shown below.
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | PC Bang The function has not been initialized. You must call PCBang_Initialize first. | x | |
| 22 | HTTP_ERROR | The network request failed due to an HTTP error | O | The network connection is not working properly. Please check your network status and try again. [OK] |
| 23 | RESPONSE_ERROR | There is an error in the server response | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 25 | RESPONSE_VALUE_IS_NULL | The server response data is empty. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 26 | RESPONSE_INVALID_VALUE_FORMAT | The server response data format is invalid | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 249 | NETWORK_TRANSPORT_ERROR | An error occurred at the network transport layer. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | There was a temporary issue. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For the complete list, see PCBangSDKResultCode.
Example
using static Stove.PCSDK.PCBang;
void OnUserLoginFinished(CallbackResult result, StovePCBangUserLogin login)
{
if (result.result.IsSuccessful())
{
// Please implement the logic for the success case.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnRefreshBenefitsFinished(CallbackResult result, StovePCRefreshUserBenefits benefits)
{
if (result.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
PCBang_UserLogin(OnUserLoginFinished, OnRefreshBenefitsFinished);
Notes
- This function is asynchronous, and the two callbacks run on the thread that calls
Base_RunCallback(). - To log out, call PCBang_UserLogout.
- Even when the status is "Free" (
PCBangPremium.PCBANG_FREE), benefit renewal callbacks will continue to be sent.
See Also
- PCBang_UserLogout
- PCBang_CheckPCBangStatus
- StovePCBangUserLogin
- StovePCRefreshUserBenefits
- PCBangPremium
PCBang_UserLogout
Kind Function · Module PCBang · Version 3.0.2
Description
Log out the game user from the PC Bang service.
PCBang_UserLogin Stops repeated calls to the benefit renewal callback that was initiated.
Declaration
public static void PCBang_UserLogout(OnPCBangUserLogoutOnFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnPCBangUserLogoutOnFinished | Y | This is the callback that receives the logout result. |
Returns
None
Callback
public delegate void OnPCBangUserLogoutOnFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | Here are the results of the logout call. Check result.result.IsSuccessful() to determine whether it was successful. |
The callback runs in the thread that called Base_RunCallback() and is called only once upon successful logout.
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | PC Bang The function has not been initialized. You must call PCBang_Initialize first. | x | |
| 22 | HTTP_ERROR | The network request failed due to an HTTP error | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 23 | RESPONSE_ERROR | There is an error in the server response. | O | The network connection is not working properly. Please check your network status and try again. [OK] |
| 25 | RESPONSE_VALUE_IS_NULL | The server response data is empty. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 249 | NETWORK_TRANSPORT_ERROR | An error occurred at the network transport layer. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see PCBangSDKResultCode.
Example
using static Stove.PCSDK.PCBang;
void OnUserLogoutFinished(CallbackResult result)
{
if (result.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
PCBang_UserLogout(OnUserLogoutFinished);
Notes
- This function is asynchronous, and the callback is executed once on the thread that calls
Base_RunCallback(). - You must call this function to stop the repeated calls to the benefit renewal callback for PCBang_UserLogin.
See Also
PCBangPremium
Kind Enum · Module PCBang · Version 3.0.2
Description
This value indicates the premium (paid) subscription status of the logged-in user. The premiumStatus field in StovePCBangUserLogin, StovePCBangStatus, and StovePCRefreshUserBenefits contains this value.
This enumeration does not have separate codes to indicate success or failure. PCBANG_ERROR is a value that indicates a server error or an unrecognizable status, and the success or failure of the operation is determined separately using CallbackResult.result.IsSuccessful().
Declaration
public enum PCBangPremium
{
PCBANG_ERROR = -1,
PCBANG_PREMIUM = 1,
PCBANG_FREE = 2,
PCBANG_FREE_OTHER = 3,
};
Enum Values
| Code | Name | Description |
|---|---|---|
| -1 | PCBANG_ERROR | Unable to determine the server error/status. |
| 1 | PCBANG_PREMIUM | Premium (paid) PC Bang benefits are currently available. |
| 2 | PCBANG_FREE | You are currently using the free version. |
| 3 | PCBANG_FREE_OTHER | This is a free service provided by a partner company (third party). |
Example
void OnUserLoginFinished(CallbackResult result, StovePCBangUserLogin login)
{
if (result.result.IsSuccessful())
{
if (login.premiumStatus == PCBangPremium.PCBANG_PREMIUM)
{
// Please implement the logic for premium benefits.
}
}
}
Notes
- This value is returned by all three structures: StovePCBangUserLogin, StovePCBangStatus, and StovePCRefreshUserBenefits.
- Even in the free status (
PCBANG_FREE), the benefit renewal callback continues to be called.
See Also
PCBangSDKMethod
Kind Enum · Module PCBang · Version 3.0.2
Description
Based on the value returned as Result.methodCode or CallbackResult.result.methodCode, this identifies which PC Bang function produced the result.
Declaration
public enum PCBangSDKMethod
{
INITIALIZE = 1,
UNINITIALIZE = 2,
INTERNAL_SEND_81PLUG = 3,
INTERNAL_UPDATE_81PLUG = 4,
GET_VERSION = 5,
USER_LOGIN = 80,
USER_LOGOUT = 81,
CHECK_PCBANG_STATUS = 82,
REFRESH_USER_BENEFITS = 83,
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 1 | INITIALIZE | This is the result created by PCBang_Initialize. |
| 2 | UNINITIALIZE | This is the result created by PCBang_UnInitialize. |
| 3 | INTERNAL_SEND_81PLUG | This is an internal-use-only value. |
| 4 | INTERNAL_UPDATE_81PLUG | This value is for internal use only. |
| 5 | GET_VERSION | This is the result created by PCBang_GetVersion. |
| — | 6~79 | Not in use (reserved number) |
| 80 | USER_LOGIN | This is the result generated by the login callback for PCBang_UserLogin. |
| 81 | USER_LOGOUT | This is the result created by PCBang_UserLogout. |
| 82 | CHECK_PCBANG_STATUS | This is the result created by PCBang_CheckPCBangStatus. |
| 83 | REFRESH_USER_BENEFITS | This is the result generated by the benefit renewal callback for PCBang_UserLogin. |
Internal-only values (INTERNAL_SEND_81PLUG, INTERNAL_UPDATE_81PLUG) are listed in the table above by name and number only and are not exposed via a separate public API.
Example
if (callbackResult.result.methodCode == Convert.ToUInt32(PCBangSDKMethod.USER_LOGIN))
{
// Here are the login results for PCBang_UserLogin.
}
Notes
- Since
Result.methodCodeis auintfield, you must convert it toConvert.ToUInt32()or similar when comparing it with this enumeration value. USER_LOGINandREFRESH_USER_BENEFITSare values used to distinguish between the two results passed as callbacks at different times during a single call to PCBang_UserLogin.
See Also
PCBangSDKResultCode
Kind Result Code · Module PCBang · Version 3.0.2
Description
This is the value returned by Result.resultCode or CallbackResult.result.resultCode. A value of 0 (SUCCESS) indicates success; any other value indicates failure.
This code is shared code that shares the same number range as the SDKResultCode series of other PCSDK legacy modules, including the SDK. You must check the Result.sdkName value to determine which module generated the result.
Declaration
public enum PCBangSDKResultCode
{
SUCCESS = 0,
FAIL = 1,
// ... See the "Values" table below
UNKNOWN_ERROR = 255,
}
Enum Values
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 1 | FAIL | This is a general error. Check the logs or exceptionMessage for the specific cause. | x | |
| 2 | INVALID_CONFIG | The setting is invalid. Please verify the setting. | x | |
| 3 | INVALID_LOG_LEVEL | The log level value is invalid. You must verify the log level value. | x | |
| 4 | INVALID_LOG_PATH | The log path is invalid. Please verify the log path. | x | |
| 5 | INVALID_PARAM | The parameter is invalid. Please check the parameter value in the calling code and correct it. | x | |
| — | 6 ~ 15 | Not in use (reserved section) | x | |
| 16 | BASE_NOT_INITIALIZED | The SDK has not been initialized. You must first call Base_Initialize(). | x | |
| 17 | NOT_INITIALIZED | PC Bang The function has not been initialized. You must call PCBang_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | It has already been initialized. You must remove the duplicate initialization call. | x | |
| 19 | INVALID_ACCESS_TOKEN | The AccessToken is invalid. The token must be reissued. | O | Your login session has expired. Please close the game and restart it. [OK] |
| 20 | NULL_TOKEN_ENTITY | The token entity is null. You must verify the token issuance status. | x | |
| 21 | NULL_ENTITY | The entity is null. You must check whether the response object is null. | x | |
| 22 | HTTP_ERROR | An HTTP communication error has occurred. Please check your network connection and try again. | O | The network connection is unstable. Please check your network connection and try again. [OK] |
| 23 | RESPONSE_ERROR | This is a server response error. You need to check the server response. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 24 | RESPONSE_INVALID_CODE | The server response code is invalid. You must verify the server response code. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 25 | RESPONSE_VALUE_IS_NULL | The server response is empty. You must verify the server response. | O | The network connection is unstable. Please check your network connection and try again. [OK] |
| 26 | RESPONSE_INVALID_VALUE_FORMAT | The server response format is incorrect. You must verify the server response format. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 27 | LOG_81PLUG_ERROR | 81 Plug transmission failed (Deprecated) | x | |
| 28 | UPDATE_81PLUG_FEED_ERROR | 81 Plug update failed (Deprecated) | x | |
| 29 | ASYNC_OPERATION_IN_PROGRESS | An asynchronous operation is already in progress. You must call this method again after the ongoing asynchronous operation is complete. | x | |
| 30 | BASE_UNINITIALIZED | The SDK has already been uninitialized. You must call Base_Initialize() again. | x | |
| 31 | NOT_SUPPORTED_COUNTRY | This feature is not currently available in your country/region. Please check the country/region restrictions and stop the call. | x | |
| — | 32 ~ 250 | Not in use (reserved section) | x | |
| 251 | PCSDK_DLL_NOT_FOUND | The PC SDK DLL cannot be found. Please check the DLL's location. | x | |
| 252 | NOT_IMPLEMENTED | This feature has not been implemented. You should remove the call or check for an alternative API. | x | |
| 253 | UNMANAGED_EXCEPTION | An unmanaged exception has occurred. You should check the exception log. | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | A managed exception has occurred. You should check the exception log. | O | There was a temporary issue. Please try again. [OK] |
| 255 | UNKNOWN_ERROR | This is an unknown error. You need to check the detailed log. | x |
If you see the code below, you must exit the game. The game cannot proceed normally.
19INVALID_ACCESS_TOKEN— Your login session has expired; you must close the game and restart it.
Example
Result result = PCBang_Initialize();
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else if (result.resultCode == (uint)PCBangSDKResultCode.ALREADY_INITIALIZED)
{
// Please implement the logic for cases where it has already been initialized.
}
Notes
28(UPDATE_81PLUG_FEED_ERROR) is a code used for internal integration and remains deprecated.- Since
Result.resultCodeis auintfield, you must convert it using(uint)casting or similar methods when comparing it to this enumeration value.
See Also
ProductTypeCode
Kind Enum · Module IAP · Version 3.0.0.4
Description
This indicates the type of product contained in the StovePCProduct.productTypeCode / StovePCProductEx.productTypeCode fields and passed to the IAP_FetchProducts / IAP_FetchProductsEx callbacks.
Declaration
public enum ProductTypeCode
{
NONE = 0,
INDIE_PACKAGE_GAME_ITEM = 1,
IN_GAME_ITEM,
PACKAGE_ITEM,
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | NONE | No type has been specified. |
| 1 | INDIE_PACKAGE_GAME_ITEM | This is an indie game bundle. |
| 2 | IN_GAME_ITEM | This is an in-game item. |
| 3 | PACKAGE_ITEM | This is a package deal. |
Example
using static Stove.PCSDK.IAP;
void OnFetchProductsFinished(CallbackResult callbackResult, StovePCProduct[] products)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var product in products)
{
if (product.productTypeCode == ProductTypeCode.IN_GAME_ITEM)
{
// Please implement the logic for in-game item sales.
}
}
}
Notes
- It is one of the values that, along with DiscountType and PurchaseLimitTypeCode, make up the product information.
See Also
PurchaseLimitTypeCode
Kind Enum · Module IAP · Version 3.0.0.4
Description
Stored in the StovePCProduct.purchaseLimitTypeCode / StovePCProductEx.purchaseLimitTypeCode fields, this indicates the unit in which purchaseLimitCount limits the purchase quantity.
Declaration
public enum PurchaseLimitTypeCode
{
NONE = 0,
UNLIMITED = 1,
MEMBER,
CHARACTER
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | NONE | No restrictions have been specified. |
| 1 | UNLIMITED | There are no purchase limits. |
| 2 | MEMBER | Purchases are limited to one per member (account). |
| 3 | CHARACTER | Purchases are limited on a per-character basis. |
Example
using static Stove.PCSDK.IAP;
void CheckPurchaseLimit(StovePCProduct product)
{
if (product.purchaseLimitTypeCode == PurchaseLimitTypeCode.CHARACTER)
{
// Please implement the UI logic for character-based purchase limits. `purchaseLimitCount` is the limit.
}
}
Notes
- It is used, along with the
purchaseLimitCountandsaleLimitCountfields, to determine the number of units of a product that can be purchased.
See Also
PurchaseProgress
Kind Enum · Module IAP · Version 3.0.0.4
Description
Stored in the StovePCPurchaseResult.purchaseProgress field and passed to the IAP_StartPurchase / IAP_StartPurchaseEx callback. Indicates whether a payment window should be displayed after the purchase request.
Declaration
public enum PurchaseProgress
{
NONE = 0,
NEED_PAYMENT_WINDOW = 1,
NOT_NEED_PAYMENT_WINDOW
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | NONE | The progress status has not been specified. |
| 1 | NEED_PAYMENT_WINDOW | You need to open an additional payment window. |
| 2 | NOT_NEED_PAYMENT_WINDOW | There is no need to open an additional payment window. |
Example
using static Stove.PCSDK.IAP;
void OnStartPurchaseFinished(CallbackResult callbackResult, StovePCPurchaseResult purchase)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
if (purchase.purchaseProgress == PurchaseProgress.NEED_PAYMENT_WINDOW)
{
// Please implement the logic to open the payment window using `oneTimePaymentUrl`.
}
}
Notes
- When
NEED_PAYMENT_WINDOWoccurs, you should also checkStovePCPurchaseResult.oneTimePaymentUrl.
See Also
Result
Kind Struct · Module Base · Version 3.0.0.4
Description
Result is both the result directly returned by the SDK Legacy’s synchronous APIs (e.g., Base_UnInitialize, Base_SetLanguage) and the result contained within CallbackResult that is passed via an asynchronous callback.
If resultCode equals 0 (BaseSDKResultCode.SUCCESS), it is successful. This is determined using the IsSuccessful() method.
Declaration
public struct Result
{
public string sdkName;
public uint methodCode;
public uint resultCode;
public string exceptionMessage;
}
Members
| Name | Type | Description |
|---|---|---|
sdkName | string | Name of the SDK (DLL) that generated the results |
methodCode | uint | The BaseSDKMethod value that identifies the API that generated this result |
resultCode | uint | Value BaseSDKResultCode. If 0, success |
exceptionMessage | string | Exception message when an exception occurs. May be empty if no exception occurs. |
Example
using static Stove.PCSDK.Base;
Result result = Base_SetLanguage(StoveLanguage.ko);
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for handling failures. Check `result.resultCode` and `result.exceptionMessage`.
}
Notes
result.IsSuccessful()is a method. Be careful not to confuse it with theresult.IsSuccessfulproperty of the new C# interface (Stove.PCSDK.V3).- All fields are public camelCase fields, not properties.
- If an exception occurs inside the C# wrapper,
resultCodeis set toBaseSDKResultCode.MANAGED_EXCEPTION(254).
See Also
StoveAPI_FreeStruct
Kind Function · Module Base · Version 3.4.0
Description
If you pass a native structure pointer (ptr) filled with query results such as Base_GetUser, Base_GetGds, Base_GetSignin, Base_GetTraceHint, etc., it releases the native-side resources occupied by that structure.
This function itself has a name that deviates from the Base_ prefix rule, and it is defined exactly as named in the source code. Within BaseAPI.cs, the internal implementation—such as Base_GetUser—calls this function only when stoveDeleter (a native deallocation function pointer) is set in the native structure, and then deallocates the managed buffer (Marshal.FreeHGlobal) as well.
Declaration
public static void StoveAPI_FreeStruct(IntPtr ptr);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
ptr | IntPtr | Y | A pointer to the native structure to be unwrapped |
Returns
| Type | Description |
|---|---|
void | None |
Error Codes
None. This function does not return Result/CallbackResult; if an exception occurs internally, the C# exception is rethrown as-is.
Example
using static Stove.PCSDK.Base;
// Use this only when dealing directly with native structure pointers.
StoveAPI_FreeStruct(nativePtr);
Notes
- In typical use, Base_GetUser, Base_GetGds, Base_GetSignin, and Base_GetTraceHint call this function internally, so it is rarely called directly from the game code.
ptrmust be a pointer to a native structure. You must not pass a managed structure value directly.
See Also
StoveLanguage
Kind Enum · Module Base · Version 3.0.0.4
Description
StoveLanguage is the language value passed when calling Base_SetLanguage. system corresponds to the system language, and the rest refer to individual languages.
Declaration
public enum StoveLanguage
{
system = 0,
en = 1,
ko = 2,
ja = 3,
zh_cn = 4,
zh_tw = 5,
de = 6,
fr = 7,
es = 8,
pt = 9,
th = 10,
vi = 11,
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | system | Follows the system language |
| 1 | en | English |
| 2 | ko | Korean |
| 3 | ja | Japanese |
| 4 | zh_cn | Chinese (Simplified) |
| 5 | zh_tw | Chinese (Traditional) |
| 6 | de | German |
| 7 | fr | French |
| 8 | es | Spanish |
| 9 | pt | Portuguese |
| 10 | th | Thai |
| 11 | vi | Vietnamese |
Example
using static Stove.PCSDK.Base;
Result result = Base_SetLanguage(StoveLanguage.ko);
if (result.IsSuccessful())
{
// Please implement the logic for the success case.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- Value names are written in lowercase with underscores. Since this notation differs from that of other SDK enumerations (such as
BaseSDKMethodandBaseSDKResultCode), be careful not to confuse them. - If you need to specify a language that is not listed here, you should use Base_SetLanguageEx. This function accepts a string instead of
StoveLanguage. - The four values
de,fr,es, andptwere added in v3.4.0. The remaining values have been available since the initial release.
See Also
StoveOverlayMode
Kind Enum · Module Base · Version 3.4.1
Description
StoveOverlayMode is the value of the overlayMode field for StovePCVietnamAgeRatingInfo and StovePCVietnamOverimmersionInfo. The SDK informs the game how to display the Vietnam Age Rating and Excessive Use overlays on the screen.
Declaration
public enum StoveOverlayMode
{
SHOW = 0,
HIDE = 1,
EXPANDED = 2,
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | SHOW | Displays the overlay |
| 1 | HIDE | Hide the overlay |
| 2 | EXPANDED | Displays the overlay in its expanded form |
Example
using static Stove.PCSDK.Base;
void OnVietnamAgeRatingFinished(CallbackResult callbackResult, StovePCVietnamAgeRatingInfo vietnamAgeRatingInfo)
{
if (callbackResult.result.IsSuccessful())
{
if (vietnamAgeRatingInfo.overlayMode == StoveOverlayMode.SHOW)
{
// Please implement the logic to display the overlay.
}
}
}
Notes
- This value is passed to the Base_VietnamAgeRatingNotification and Base_VietnamOverimmersionNotification callbacks; it is not generated directly by the game.
See Also
- StovePCVietnamAgeRatingInfo
- StovePCVietnamOverimmersionInfo
- Base_VietnamAgeRatingNotification
- Base_VietnamOverimmersionNotification
StovePCBangStatus
Kind Struct · Module PCBang · Version 3.0.2
Description
PCBang_CheckPCBangStatus is a structure passed as a callback that contains information about the current PC Bang status and product code.
This structure is created by the SDK and passed as a callback argument.
Declaration
public struct StovePCBangStatus
{
public PCBangPremium premiumStatus;
public int pcBangSerialNumber;
public int productCode;
}
Members
| Name | Type | Access | Description |
|---|---|---|---|
premiumStatus | PCBangPremium | Read | PC Bang This is a premium status. |
pcBangSerialNumber | int | Read | This is the PC Bang seat/session number assigned to the user. |
productCode | int | Read | There are currently PC Bang product codes available to users. |
Example
void OnCheckStatusFinished(CallbackResult result, StovePCBangStatus status)
{
if (result.result.IsSuccessful())
{
var premium = status.premiumStatus;
var psn = status.pcBangSerialNumber;
var productCode = status.productCode;
}
}
Notes
- It is passed only to the callback of PCBang_CheckPCBangStatus.
- It has a similar field structure to
StovePCBangUserLogin, but usesproductCodeinstead ofremainTime. - Since it is a C# struct, no separate creation or destruction procedures are required. The GC manages the memory.
See Also
StovePCBangUserLogin
Kind Struct · Module PCBang · Version 3.0.2
Description
PCBang_UserLogin is the structure passed to the onUserLoginFinished callback when this login is completed.
This structure is created by the SDK and passed as a callback argument.
Declaration
public struct StovePCBangUserLogin
{
public PCBangPremium premiumStatus;
public int pcBangSerialNumber;
public int remainTime;
}
Members
| Name | Type | Access | Description |
|---|---|---|---|
premiumStatus | PCBangPremium | Read | PC Bang This is a Premium status. |
pcBangSerialNumber | int | Read | This is the PC Bang seat/session number assigned to the user. |
remainTime | int | Read | Time remaining for paid benefits (in seconds). |
Example
void OnUserLoginFinished(CallbackResult result, StovePCBangUserLogin login)
{
if (result.result.IsSuccessful())
{
var premium = login.premiumStatus;
var psn = login.pcBangSerialNumber;
var remainTime = login.remainTime;
}
}
Notes
- It is passed only to the
onUserLoginFinishedcallback of PCBang_UserLogin. Subsequent benefit renewal information is passed separately to StovePCRefreshUserBenefits. - Since it is a C# struct, no separate creation or destruction procedures are required. The GC manages the memory.
See Also
StovePCChargeInfo
Kind Struct · Module IAP · Version 3.1.0
Description
The element type stored in the StovePCPurchaseResult.chargeInfos array and the IAP_ConfirmPurchase callback's chargeInfos array represents the type and amount of in-game currency deducted as payment for a purchase.
This is an output-only structure that the SDK populates with values and returns via a callback. It is not created directly by the caller.
Declaration
public struct StovePCChargeInfo
Members
| Name | Type | Description |
|---|---|---|
chargeDeductVal | double | This is the amount that has been deducted. |
chargeDisplayDeductVal | double | This is the deduction amount to be displayed on the screen. |
chargeType | int | This is the code for the type of goods deducted. |
chargeTypeName | string | This is the name of the type of goods that were deducted. |
Example
using static Stove.PCSDK.IAP;
void OnConfirmPurchaseFinished(CallbackResult callbackResult, bool status, StovePCPurchasedProduct[] purchasedProducts, StovePCChargeInfo[] chargeInfos)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var charge in chargeInfos)
{
// Please implement the logic for displaying deduction details using `charge.chargeTypeName`, `charge.chargeDisplayDeductVal`, and other similar parameters.
}
}
Notes
- It is used in both the callback for IAP_ConfirmPurchase and StovePCPurchaseResult.
See Also
StovePCFetchProductParam
Kind Struct · Module IAP · Version 3.0.0.4
Description
This is an input structure used to specify which category of products to retrieve and in what page increments when calling IAP_FetchProducts / IAP_FetchProductsEx.
The caller populates the value and passes it to the API.
Declaration
public struct StovePCFetchProductParam
Members
| Name | Type | Required | Description |
|---|---|---|---|
categoryId | string | Y | This is the category ID of the product you want to view. |
pageNumber | int | Y | This is the page number to look up. |
pageSize | int | Y | The number of products to display per page. |
Example
using static Stove.PCSDK.IAP;
StovePCFetchProductParam param = new StovePCFetchProductParam();
param.categoryId = "YOUR_CATEGORY_ID";
param.pageNumber = 1;
param.pageSize = 20;
IAP_FetchProducts(param, OnFetchProductsFinished);
Notes
- Both IAP_FetchProducts and IAP_FetchProductsEx accept the same structure as input. The difference between the two APIs lies in the type of the query results (StovePCProduct / StovePCProductEx).
See Also
StovePCGameProfile
Kind Struct · Module Base · Version 3.0.0.4
Description
StovePCGameProfile is a structure passed as an argument when Base_SetGameProfile is called. The game populates it with values and passes it along.
Declaration
public struct StovePCGameProfile
{
public string worldId;
public long characterNumber;
}
Members
| Name | Type | Description |
|---|---|---|
worldId | string | World ID |
characterNumber | long | Character Number |
Example
using static Stove.PCSDK.Base;
StovePCGameProfile gameProfile = new StovePCGameProfile
{
worldId = "world_01",
characterNumber = 12345L
};
Result result = Base_SetGameProfile(gameProfile);
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- None
See Also
StovePCGds
Kind Struct · Module Base · Version 3.0.0.4
Description
StovePCGds is a structure that Base_GetGds populates and returns. If the caller passes a previously declared variable as ref, the SDK fills in the values.
Declaration
public struct StovePCGds
{
public bool isDefault;
public string nation;
public string regulation;
public string timeZone;
public int utcOffset;
public string language;
}
Members
| Name | Type | Description |
|---|---|---|
isDefault | bool | Whether it is the default value |
nation | string | Country |
regulation | string | Regulations |
timeZone | string | Time Zone |
utcOffset | int | UTC Offset |
language | string | Language |
Example
using static Stove.PCSDK.Base;
StovePCGds gds = default;
Result result = Base_GetGds(ref gds);
if (result.IsSuccessful())
{
// Please implement logic that uses gds.nation, gds.regulation, and so on.
}
else
{
// Please implement the logic for when a failure occurs.
}
Notes
- The value will not be populated until Base_GetGds is called.
See Also
StovePCInitializeParam
Kind Struct · Module Base · Version 3.0.0.4
Description
StovePCInitializeParam is a structure passed as an input when calling Base_RestartAppIfNecessary, Base_RestartAppIfNecessaryAsync, Base_RestartAppIfNecessaryAsyncEx, and Base_Initialize. The game fills in the values and passes it.
If you need an extension initialization that requires passing waitTimeMillisec, launchLauncher, and others together, you must use StovePCInitializeParamEx2.
Declaration
public struct StovePCInitializeParam
{
public string environment;
public string gameId;
public string applicationKey;
}
Members
| Name | Type | Description |
|---|---|---|
environment | string | Service Environment to Connect To |
gameId | string | Game ID |
applicationKey | string | Application Key |
Example
using static Stove.PCSDK.Base;
StovePCInitializeParam initParam = new StovePCInitializeParam
{
environment = "real",
gameId = "your_game_id",
applicationKey = "your_application_key"
};
Base_Initialize(initParam, OnInitializeFinished);
Notes
- Base_InitializeEx does not accept this structure. It only accepts callbacks.
- Base_RestartAppIfNecessaryAsyncEx2 accepts StovePCInitializeParamEx2 instead of this structure.
See Also
StovePCInitializeParamEx2
Kind Struct · Module Base · Version 3.4.1
Description
StovePCInitializeParamEx2 is the input structure received by Base_RestartAppIfNecessaryAsyncEx2. In addition to the three fields of StovePCInitializeParam, it combines waitTimeMillisec, launchLauncher, and platformName—which were previously passed as separate parameters—along with five reserved fields into a single structure.
Declaration
public struct StovePCInitializeParamEx2
{
public string environment;
public string gameId;
public string applicationKey;
public uint waitTimeMillisec;
public bool launchLauncher;
public string platformName;
public ulong reserved1;
public ulong reserved2;
public ulong reserved3;
public ulong reserved4;
public ulong reserved5;
}
Members
| Name | Type | Description |
|---|---|---|
environment | string | Service Environment to Connect To |
gameId | string | Game ID |
applicationKey | string | Application Key |
waitTimeMillisec | uint | Wait Time (milliseconds) |
launchLauncher | bool | Whether to Run the Launcher |
platformName | string | Platform Name |
reserved1 | ulong | Reservation field. Not in use. |
reserved2 | ulong | Reservation field. Not in use. |
reserved3 | ulong | Reservation field. Not in use. |
reserved4 | ulong | Reservation field. Not in use. |
reserved5 | ulong | Reservation field. Not in use. |
Example
using static Stove.PCSDK.Base;
StovePCInitializeParamEx2 initParam = new StovePCInitializeParamEx2
{
environment = "real",
gameId = "your_game_id",
applicationKey = "your_application_key",
waitTimeMillisec = 3000,
launchLauncher = true,
platformName = "your_platform_name"
};
Base_RestartAppIfNecessaryAsyncEx2(initParam, OnRestartAppIfNecessaryAsyncFinished);
Notes
reserved1~reserved5appear to be reserved fields for future expansion based on their names; there is no need to enter values for them at this time.- Base_RestartAppIfNecessaryAsync and Base_RestartAppIfNecessaryAsyncEx accept StovePCInitializeParam and separate parameters (
waitTimeMillisecandlaunchLauncher) instead of this structure.
See Also
StovePCInventoryItem
Kind Struct · Module IAP · Version 3.0.0.4
Description
This is the type of the elements in the StovePCInventoryItem[] array passed to the IAP_FetchInventory callback. It represents a single item in the user's inventory.
This is an output-only structure that the SDK fills with values and returns via a callback. It is not created directly by the caller.
Declaration
public struct StovePCInventoryItem
Members
| Name | Type | Description |
|---|---|---|
transactionMasterNumber | long | This is the transaction master number. |
transactionDetailNumber | long | This is the transaction reference number. |
productId | long | This is the product ID corresponding to the item. |
gameItemId | string | This is the game item ID. |
productName | string | This is the product name. |
quantity | int | This is the quantity on hand. |
thumbnailUrl | string | This is the URL for the thumbnail image. |
Example
using static Stove.PCSDK.IAP;
void OnFetchInventoryFinished(CallbackResult callbackResult, StovePCInventoryItem[] inventoryItems)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var item in inventoryItems)
{
// Please implement the inventory UI logic using variables such as `item.productName` and `item.quantity`.
}
}
Notes
- None.
See Also
StovePCLogSendParam
Kind Struct · Module Log · Version 3.4.1
Description
These are the parameters used in the Log_Send() call. They contain all the values required for a single log entry, including user identification information, marketing integration information, game and server context, and the log group and body.
This is a struct in which the caller fills in the values and passes them directly to Log_Send().
For fields with unknown values in specific log entries, you can leave them at their default values (the number 0, the string
null, or an empty value).
Declaration
public struct StovePCLogSendParam
{
public long auid;
public long cuid;
public string mktType1;
public string mktId1;
public string mktType2;
public string mktId2;
public string gameVersion;
public string logGroupId;
public string serverCd;
public string serverCdDet;
public string lvCd;
public string lvCdDet;
public string contents;
}
Members
User Identification
| Name | Type | Access | Description |
|---|---|---|---|
auid | long | Reading and Writing | This is the account UID (STOVE account identifier). |
cuid | long | Reading and Writing | This is the character UID (in-game character identifier). |
Marketing Integration Information
| Name | Type | Access | Description |
|---|---|---|---|
mktType1 | string | Reading and Writing | This is the name of the integrated third-party marketing service (Slot 1). |
mktId1 | string | Reading and Writing | This is an identifier (campaign/referrer ID) issued by Slot 1 Marketing Services. |
mktType2 | string | Reading and Writing | This is the name of the integrated third-party marketing service (Slot 2). |
mktId2 | string | Reading and Writing | This is an identifier (campaign/referrer ID) issued by Slot 2 Marketing Services. |
mktType1/mktId1andmktType2/mktId2are two independent slots. Since they do not have a primary/fallback relationship, only the corresponding slot should be filled in.
Game · Server Context
| Name | Type | Access | Description |
|---|---|---|---|
gameVersion | string | Reading and Writing | This is the game client version string (e.g., "1.2.3"). |
serverCd | string | Reading and Writing | This is the server code (the world/region server the user is connected to). |
serverCdDet | string | Reading and Writing | Details of the server code (sub-servers, channels, and shards under serverCd). |
lvCd | string | Reading and Writing | This is the account level at the time the log entry was recorded. |
lvCdDet | string | Reading and Writing | This is the character's level at the time the log was recorded. |
lvCdDetis not a subentry oflvCd, despite the "Det" suffix in its name. It is the character range value corresponding tolvCd(account range).
Log Group · Main Text
| Name | Type | Access | Description |
|---|---|---|---|
logGroupId | string | Reading and Writing | A correlation ID that groups related log entries together. Entries with the same value are treated as a single logical set by the log backend. |
contents | string | Reading and Writing | This is a free-form log payload (typically a JSON document string) that contains values not covered by the above field types. It corresponds to the action_param field in the legacy 81plug. |
Example
var logSendParam = new StovePCLogSendParam
{
auid = auid,
cuid = cuid,
gameVersion = "1.2.3",
contents = "{\"event\":\"login\"}"
};
Log_Send(logSendParam, OnLogSendFinished);
Notes
- It is used only as an input parameter for Log_Send().
- Fields without values can be left with their default values (the number 0, the string
null, or an empty value). - Since it is a C# struct, no separate creation or destruction procedures are required. The garbage collector manages the memory.
- The logging feature was added to the entire module in version 3.4.1.
See Also
StovePCOrderProduct
Kind Struct · Module IAP · Version 3.0.0.4
Description
StovePCStartPurchaseParam.products is the element type of the array; it is an input structure that specifies the product ID, quantity, and selling price for a purchase request.
The caller fills in the values and passes them to IAP_StartPurchase / IAP_StartPurchaseEx.
Declaration
public struct StovePCOrderProduct
Members
| Name | Type | Required | Description |
|---|---|---|---|
productId | long | Y | This is the ID of the item you are purchasing. |
salePrice | double | Y | This is the selling price of the product. |
quantity | int | Y | The number of items to purchase. |
Example
using static Stove.PCSDK.IAP;
StovePCOrderProduct orderProduct = new StovePCOrderProduct();
orderProduct.productId = 123456;
orderProduct.salePrice = 1000;
orderProduct.quantity = 1;
Notes
salePricemust return the same value as StovePCProduct.salePrice, which is the product search result, in order to pass the server-side price validation.
See Also
StovePCOverImmersion
Kind Struct · Module Base · Version 3.0.0.4
Description
StovePCOverImmersion is a structure passed by the OnOverImmersionFinished callback registered with Base_OverImmersionNotification. The SDK populates the values and passes them to the callback.
Declaration
public struct StovePCOverImmersion
{
public string warningMessage;
public int elapsedTimeInHours;
public int minExposureTimeInSeconds;
}
Members
| Name | Type | Description |
|---|---|---|
warningMessage | string | Warning Message |
elapsedTimeInHours | int | Cumulative Usage Time (in hours) |
minExposureTimeInSeconds | int | Minimum exposure time (in seconds) |
Example
using static Stove.PCSDK.Base;
void OnOverImmersionFinished(CallbackResult callbackResult, StovePCOverImmersion overImmersion)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic to display warnings using `overImmersion.warningMessage` and similar methods.
}
}
Base_OverImmersionNotification(OnOverImmersionFinished);
Notes
- This structure is not created by the game itself; it is passed only via the Base_OverImmersionNotification callback.
See Also
StovePCPaymentOperation
Kind Enum · Module IAP · Version 3.0.0.4 · Deprecated
Description
This is a deprecated value specific to
IAP_StartPayment. If you are not usingIAP_StartPayment, do not use this value either.
This value is assigned to the StovePCPaymentOption.operation field and specifies how the payment web view popup behaves when IAP_StartPayment / IAP_StartPaymentEx is called.
This value indicates the operating mode, not whether the operation was successful or failed.
Declaration
public enum StovePCPaymentOperation
{
DEFAULT = 0,
WITH_WEBVIEW,
_MAX_COUNT
}
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | DEFAULT | Proceed with payment using the default action. |
| 1 | WITH_WEBVIEW | We process payments using WebView. |
| 2 | _MAX_COUNT | Not used (internal threshold value indicating the number of values) |
Example
using static Stove.PCSDK.IAP;
StovePCPaymentOption option = new StovePCPaymentOption();
option.operation = StovePCPaymentOperation.WITH_WEBVIEW;
Notes
- StovePCPurchaseOperation and StovePCTermsOperation have the same data type but belong to different enumeration types, so they cannot be used together.
See Also
StovePCPaymentOption
Kind Struct · Module IAP · Version 3.0.0.4 · Deprecated
Description
This is a deprecated structure specific to
IAP_StartPayment. Please use IAP_StartPurchase, which uses StovePCPurchaseOption, instead.
This is an input structure that specifies the behavior, position, and size of the payment web view pop-up when calling IAP_StartPayment / IAP_StartPaymentEx.
The caller passes the value by reference.
Declaration
public struct StovePCPaymentOption
Members
| Name | Type | Required | Description |
|---|---|---|---|
operation | StovePCPaymentOperation | Y | Here's how the payment pop-up works. |
webviewMode | WebViewMode | Y | Specifies whether the WebView should be displayed externally or internally. |
webviewPosX | int | Y | This is the X-coordinate of the WebView popup. |
webviewPosY | int | Y | This is the Y coordinate of the WebView popup. |
webviewWidth | int | Y | This is the width of the WebView popup. |
webviewHeight | int | Y | This is the height of the WebView popup. |
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCPaymentOption option = new StovePCPaymentOption();
option.operation = StovePCPaymentOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewPosX = 0;
option.webviewPosY = 0;
option.webviewWidth = 800;
option.webviewHeight = 600;
Notes
- StovePCPurchaseOption, StovePCTermsOption, and StovePCWithdrawGameOption also have the same WebView position and size field configurations.
See Also
StovePCPopupDisallowed
Kind Struct · Module View · Version 3.0.0.4
Description
This is the input parameter for View_SetPopupDisallowed. It specifies how many days to hide a pop-up.
The caller creates an object with the field values and passes it directly to View_SetPopupDisallowed. Since it is a value type (struct), it is managed by the garbage collector, and there is no API for creating or destroying it separately.
Declaration
public struct StovePCPopupDisallowed
{
public uint popupId;
public uint days;
}
Members
| Name | Type | Description |
|---|---|---|
popupId | uint | This is the identifier for the pop-up to be hidden. |
days | uint | The number of days for which the pop-up will be hidden. |
Example
var popupDisallowed = new StovePCPopupDisallowed
{
popupId = 1001,
days = 7,
};
// Call View_SetPopupDisallowed(popupDisallowed, ...);.
Notes
- Since it is a value type (struct), there is no need to free it separately after the API call is complete.
popupIdis not a value obtained through an SDK call. The callbacks for the AutoPopup, ManualPopup, NewsPopup, and CouponPopup API families do not return a popup identifier, and the block status is stored only in the client’s local database—not via a server API. Therefore, the game (Studio) must separately know the identifier assigned when the popup was registered in order to populate this value.
See Also
StovePCProduct
Kind Struct · Module IAP · Version 3.0.0.4 · Deprecated
Description
This is the callback type for the deprecated
IAP_FetchProductsbase class. Please use IAP_FetchProductsEx, which uses StovePCProductEx instead.
This is the element type of the StovePCProduct[] array passed to the callback of IAP_FetchProducts. It contains basic product information, price and discount information, and quantity and purchase limit information. It has 31 fields.
StovePCProductEx is an extended version of this structure that adds an availability code (purchaseAvailabilityCode) to all fields. IAP_FetchProducts uses StovePCProduct, and IAP_FetchProductsEx uses StovePCProductEx. Both APIs have the same input parameter (StovePCFetchProductParam); only the return type differs. Since IAP_FetchProducts has been deprecated, please always use IAP_FetchProductsEx for actual integration.
This is an output-only structure that the SDK populates with values and returns via a callback. It is not created directly by the caller.
Declaration
public struct StovePCProduct
Members
Basic Information
| Name | Type | Description |
|---|---|---|
productId | long | This is the product ID. |
gameItemId | string | This is the game item ID. |
name | string | This is the product name. |
description | string | Product description. |
quantity | int | This is the quantity supplied per item. |
productTypeCode | ProductTypeCode | Product Categories. |
categoryId | string | This is the category ID for the product. |
categoryName | string | This is the name of the category to which the product belongs. |
thumbnailUrl | string | This is the URL for the thumbnail image. |
Pricing and Discount Information
| Name | Type | Description |
|---|---|---|
currencyCode | string | This is the country code. |
price | double | This is the list price. |
displayPrice | double | This is the list price to be displayed on the screen. |
displayPriceString | string | This is the list of regular prices to be displayed on the screen. |
salePrice | double | This is the selling price. |
displaySalePrice | double | This is the selling price to be displayed on the screen. |
displaySalePriceString | string | This is the sales price string to be displayed on the screen. |
isDiscount | bool | Whether it's on sale. |
discountType | DiscountType | This is the discount method (fixed percentage/fixed amount). |
discountTypeValue | int | This is the discount rate or discount amount. |
discountBeginDate | long | The sale is about to begin. |
discountEndDate | long | The discount is about to end. |
Information on Quantity and Purchase Limits
| Name | Type | Description |
|---|---|---|
totalQuantity | int | This is the total number of items available for sale. |
memberQuantity | int | This is the maximum quantity that can be sold per member (account). |
guidQuantity | int | This is the available quantity for sale per GUID (character). |
canWithdraw | bool | Whether the product is eligible for a refund (cancellation). |
purchasedAtLeastOnce | bool | This indicates whether this user has ever made a purchase. |
purchaseLimitTypeCode | PurchaseLimitTypeCode | These are the purchase restriction criteria (for members, characters, etc.). |
purchaseLimitCount | int | This is the purchase limit. |
saleLimitCount | int | This is the sales limit. |
saleBeginDate | long | It's time for the sale to begin. |
saleEndDate | long | It is now time for the sale to end. |
Example
using static Stove.PCSDK.IAP;
void OnFetchProductsFinished(CallbackResult callbackResult, StovePCProduct[] products)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var product in products)
{
// Please implement the product list UI logic using `product.name`, `product.displaySalePriceString`, and similar properties.
}
}
Notes
isDiscountis valid only whentrue; in that case,discountType,discountTypeValue,discountBeginDate, anddiscountEndDateare valid.- When submitting a purchase request (StovePCOrderProduct), you must pass
salePriceas-is.
See Also
StovePCProductEx
Kind Struct · Module IAP · Version 3.4.1
Description
This is the element type of the StovePCProductEx[] array passed to the callback of IAP_FetchProductsEx. It retains all 31 fields of StovePCProduct and includes the purchaseAvailabilityCode field, for a total of 32 fields.
StovePCProduct and StovePCProductEx are different structures and cannot be converted to one another. IAP_FetchProducts uses StovePCProduct, and IAP_FetchProductsEx uses StovePCProductEx. The input parameters (StovePCFetchProductParam) for both APIs are the same.
This is an output-only struct that the SDK populates with values and returns via a callback. It is not created directly by the caller.
Declaration
public struct StovePCProductEx
Members
Basic Information
| Name | Type | Description |
|---|---|---|
productId | long | This is the product ID. |
gameItemId | string | This is the game item ID. |
name | string | This is the product name. |
description | string | Product description. |
quantity | int | This is the quantity supplied per item. |
productTypeCode | ProductTypeCode | Product Categories. |
categoryId | string | This is the category ID for the product. |
categoryName | string | This is the name of the category to which the product belongs. |
thumbnailUrl | string | This is the URL for the thumbnail image. |
Pricing and Discount Information
| Name | Type | Description |
|---|---|---|
currencyCode | string | This is the country code. |
price | double | This is the list price. |
displayPrice | double | This is the list price to be displayed on the screen. |
displayPriceString | string | This is the list price text to display on the screen. |
salePrice | double | This is the selling price. |
displaySalePrice | double | This is the selling price to be displayed on the screen. |
displaySalePriceString | string | This is the sales price string to be displayed on the screen. |
isDiscount | bool | Whether it's on sale. |
discountType | DiscountType | This is the discount method (fixed percentage/fixed amount). |
discountTypeValue | int | This is the discount rate or discount amount. |
discountBeginDate | long | The sale is about to begin. |
discountEndDate | long | The discount is about to end. |
Information on Quantity and Purchase Limits
| Name | Type | Description |
|---|---|---|
totalQuantity | int | This is the total available quantity for sale. |
memberQuantity | int | This is the available quantity for sale per member (account). |
guidQuantity | int | This is the available quantity for sale per GUID (character). |
canWithdraw | bool | Whether the product is eligible for a refund (cancellation). |
purchasedAtLeastOnce | bool | This refers to whether this user has ever made a purchase. |
purchaseLimitTypeCode | PurchaseLimitTypeCode | These are the purchase restriction criteria (for members, characters, etc.). |
purchaseLimitCount | int | This is the purchase limit. |
saleLimitCount | int | This is the sales limit. |
saleBeginDate | long | It's time for the sale to begin. |
saleEndDate | long | It is now the end of the sale. |
Availability (Ex: Extended Field)**
| Name | Type | Description |
|---|---|---|
purchaseAvailabilityCode | short | This code indicates whether this product is currently available for purchase. |
Example
using static Stove.PCSDK.IAP;
void OnFetchProductsExFinished(CallbackResult callbackResult, StovePCProductEx[] products)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var product in products)
{
// First, check purchase availability using `product.purchaseAvailabilityCode`, and then
// Please implement the product list UI logic using variables such as `product.name` and `product.displaySalePriceString`.
}
}
Notes
- The meanings of the remaining fields, excluding
purchaseAvailabilityCode, are the same as those of StovePCProduct. isDiscountis valid only whentrue; in that case,discountType,discountTypeValue,discountBeginDate, anddiscountEndDateare valid.
See Also
StovePCPurchasedProduct
Kind Struct · Module IAP · Version 3.1.0
Description
The element type contained in the StovePCPurchaseResult.purchasedProducts array and the IAP_ConfirmPurchase callback's purchasedProducts array, which represents the detailed quantity information for items that have actually been purchased.
This is an output-only structure that the SDK populates with values and returns via a callback. It is not created directly by the caller.
Declaration
public struct StovePCPurchasedProduct
Members
| Name | Type | Description |
|---|---|---|
transactionDetailNumber | long | This is the transaction reference number. |
productId | long | This is the ID of the purchased item. |
categoryId | string | This is the category ID for the product. |
totalQuantity | int | This is the total quantity dispensed. |
memberQuantity | int | This is the quantity issued per member (account). |
guidQuantity | int | This is the quantity issued per GUID (character). |
Example
using static Stove.PCSDK.IAP;
void OnConfirmPurchaseFinished(CallbackResult callbackResult, bool status, StovePCPurchasedProduct[] purchasedProducts, StovePCChargeInfo[] chargeInfos)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var purchased in purchasedProducts)
{
// Please implement the payment processing logic using variables such as `purchased.productId` and `purchased.totalQuantity`.
}
}
Notes
- It is used in both the callback for IAP_ConfirmPurchase and StovePCPurchaseResult.
See Also
StovePCPurchaseOperation
Kind Enum · Module IAP · Version 3.0.0.4
Description
This value is assigned to the StovePCPurchaseOption.operation field and specifies how the purchase webview popup behaves when the IAP_StartPurchase / IAP_StartPurchaseEx function is called.
This value indicates the operating mode, not whether the operation was successful or failed.
Declaration
public enum StovePCPurchaseOperation
{
DEFAULT = 0,
WITH_WEBVIEW,
WITH_WEBVIEW_AND_CONFIRM_RESULT,
_MAX_COUNT
}
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | DEFAULT | Proceed with the purchase using the default action |
| 1 | WITH_WEBVIEW | Use the Web View to complete the purchase. |
| 2 | WITH_WEBVIEW_AND_CONFIRM_RESULT | Use the WebView and complete the purchase, including the step to review the results. |
| 3 | _MAX_COUNT | Not used (internal boundary value indicating the number of values) |
Example
using static Stove.PCSDK.IAP;
StovePCPurchaseOption option = new StovePCPurchaseOption();
option.operation = StovePCPurchaseOperation.WITH_WEBVIEW;
Notes
- Although StovePCPaymentOperation and StovePCTermsOperation also have values of the same form (
DEFAULT/WITH_WEBVIEW/_MAX_COUNT), they are different enumeration types and therefore cannot be used interchangeably.
See Also
StovePCPurchaseOption
Kind Struct · Module IAP · Version 3.0.0.4
Description
This is an input structure stored in the StovePCStartPurchaseParam.option field that specifies the behavior, position, and size of the purchase webview popup when IAP_StartPurchase / IAP_StartPurchaseEx is called.
The caller passes the value by reference.
Declaration
public struct StovePCPurchaseOption
Members
| Name | Type | Required | Description |
|---|---|---|---|
operation | StovePCPurchaseOperation | Y | Here's how the purchase pop-up works. |
webviewMode | WebViewMode | Y | Specifies whether to display the WebView externally or internally. |
webviewPosX | int | Y | This is the X coordinate of the WebView popup. |
webviewPosY | int | Y | This is the Y-coordinate of the WebView popup. |
webviewWidth | int | Y | This is the width of the WebView pop-up. |
webviewHeight | int | Y | This is the height of the WebView popup. |
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCPurchaseOption option = new StovePCPurchaseOption();
option.operation = StovePCPurchaseOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewPosX = 0;
option.webviewPosY = 0;
option.webviewWidth = 800;
option.webviewHeight = 600;
Notes
- StovePCTermsOption, StovePCPaymentOption, and StovePCWithdrawGameOption also have the same WebView position and size field configuration.
See Also
StovePCPurchaseResult
Kind Struct · Module IAP · Version 3.0.0.4
Description
This is the purchase processing result passed as a callback from IAP_StartPurchase / IAP_StartPurchaseEx. It contains the transaction number, whether an additional payment window is required, and details of the items actually purchased and the in-game currency deducted.
This is an output-only structure that the SDK fills with values and returns via a callback. It is not created directly by the caller.
Declaration
public struct StovePCPurchaseResult
Members
| Name | Type | Description |
|---|---|---|
transactionMasterNumber | long | This is the transaction master number. |
transactionDetailNumbers | long[] | This is a list of transaction reference numbers. |
oneTimePaymentUrl | string | This is a one-time payment URL used when you need to open an additional payment window. |
purchaseProgress | PurchaseProgress | Indicates whether an additional payment window should be displayed. |
purchased | bool | Whether the purchase has been completed. |
extraData | string | The value passed to StovePCStartPurchaseParam.extraData is returned exactly as it was. |
purchasedProducts | StovePCPurchasedProduct[] | This is a list of items that were actually delivered. |
chargeInfos | StovePCChargeInfo[] | This is a list of the goods deducted as payment for the purchase. |
Example
using static Stove.PCSDK.IAP;
void OnStartPurchaseFinished(CallbackResult callbackResult, StovePCPurchaseResult purchase)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
if (purchase.purchaseProgress == PurchaseProgress.NEED_PAYMENT_WINDOW)
{
// Please implement the logic to display the payment window using `purchase.oneTimePaymentUrl`.
}
else if (purchase.purchased)
{
// Please implement the payment processing logic in `purchase.purchasedProducts`.
}
}
Notes
- If
purchaseProgressisNEED_PAYMENT_WINDOW, you must checkoneTimePaymentUrl. - This structure is independent of the result of IAP_ConfirmPurchase.
IAP_ConfirmPurchasereturnspurchasedProductsandchargeInfosas separate callback arguments.
See Also
StovePCRefreshUserBenefits
Kind Struct · Module PCBang · Version 3.0.2
Description
This is a structure that is passed to the onRefreshBenefitsFinished callback every 4 minutes after a successful PCBang_UserLogin login.
This structure is created by the SDK and passed as a callback argument.
This is a different structure from the initial login result (StovePCBangUserLogin).
Declaration
public struct StovePCRefreshUserBenefits
{
public PCBangPremium premiumStatus;
public int remainTime;
}
Members
| Name | Type | Access | Description |
|---|---|---|---|
premiumStatus | PCBangPremium | Read | PC Bang This is a Premium status. |
remainTime | int | Read | Time remaining for your paid benefits (in seconds). |
Example
void OnRefreshBenefitsFinished(CallbackResult result, StovePCRefreshUserBenefits benefits)
{
if (result.result.IsSuccessful())
{
var premium = benefits.premiumStatus;
var remainTime = benefits.remainTime;
}
}
Notes
- It is passed repeatedly every 4 minutes only to the
onRefreshBenefitsFinishedcallback of PCBang_UserLogin. - It has a similar field structure to
StovePCBangUserLogin, but does not include thepcBangSerialNumberfield. - Since it is a C# struct, no separate creation or destruction procedures are required. The GC manages the memory.
See Also
StovePCShopCategory
Kind Struct · Module IAP · Version 3.0.0.4
Description
This is the element type of the StovePCShopCategory[] array passed as a callback to IAP_FetchShopCategories. It represents a single category registered in the store.
This is an output-only structure that the SDK populates with values via a callback and returns. The caller does not create it directly.
Declaration
public struct StovePCShopCategory
Members
| Name | Type | Description |
|---|---|---|
categoryId | string | This is the category ID. |
parentCategoryId | string | This is the parent category ID. If this is the top-level category, the value may be empty. |
displayNumber | int | This is the order in which categories are displayed. |
name | string | This is the category name. |
depth | int | This is the depth in the category tree. |
Example
using static Stove.PCSDK.IAP;
void OnFetchShopCategoriesFinished(CallbackResult callbackResult, StovePCShopCategory[] shopCategories)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var category in shopCategories)
{
// Please implement logic that uses category.categoryId, category.name, and so on.
}
}
Notes
- You can use
parentCategoryIdanddepthto create a category tree structure.
See Also
StovePCShutdown
Kind Struct · Module Base · Version 3.0.0.4
Description
StovePCShutdown is a structure passed by the OnShutdownFinished callback registered as Base_ShutdownNotification. The SDK populates the values and passes them to the callback.
Declaration
public struct StovePCShutdown
{
public string shutdownMessage;
public int exposureTimeInSeconds;
public int inadvanceTimeInMinutes;
}
Members
| Name | Type | Description |
|---|---|---|
shutdownMessage | string | Shutdown Notice |
exposureTimeInSeconds | int | Exposure time (in seconds) |
inadvanceTimeInMinutes | int | Time remaining until shutdown (in minutes) |
Example
using static Stove.PCSDK.Base;
void OnShutdownFinished(CallbackResult callbackResult, StovePCShutdown shutdown)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic to display a message using `shutdown`, `shutdownMessage`, and similar functions.
}
}
Base_ShutdownNotification(OnShutdownFinished);
Notes
- This structure is not created directly by the game; it is passed only via the Base_ShutdownNotification callback.
- If an account is subject to a shutdown, this callback will be triggered even from overseas. This is not a feature exclusive to South Korea.
See Also
StovePCSignin
Kind Struct · Module Base · Version 3.0.0.4
Description
StovePCSignin is a structure that is filled in and returned by Base_GetSignin. When the caller passes a previously declared variable as ref, the SDK fills in the values.
Declaration
public struct StovePCSignin
{
public bool personVerify;
public bool emailVerify;
public string nationality;
public string providerCode;
public int accountType;
}
Members
| Name | Type | Description |
|---|---|---|
personVerify | bool | Whether Identity Verification Has Been Completed |
emailVerify | bool | Email Verification Status |
nationality | string | Nationality |
providerCode | string | Login Provider Code |
accountType | int | Account Type |
Example
using static Stove.PCSDK.Base;
StovePCSignin signin = default;
Result result = Base_GetSignin(ref signin);
if (result.IsSuccessful())
{
// Please implement logic that uses `signin.personVerify`, `signin.nationality`, and so on.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- The value is not populated until Base_GetSignin is called.
See Also
StovePCStartPurchaseParam
Kind Struct · Module IAP · Version 3.0.0.4
Description
This is an input structure used to specify the list of items to purchase, pop-up options, service transaction numbers, and additional data when making a IAP_StartPurchase / IAP_StartPurchaseEx call.
The caller passes the value by reference.
Declaration
public struct StovePCStartPurchaseParam
Members
| Name | Type | Required | Description |
|---|---|---|---|
products | StovePCOrderProduct[] | Y | Here is a list of items to purchase. |
productsSize | uint | Y | products is the number of elements in the array. |
option | StovePCPurchaseOption | Y | How the purchase pop-up works, as well as its position and size. |
serviceTxnNo | string | Y | This is a transaction number issued by the game (service). |
extraData | string | Y | This is bonus data that can be used freely in the game. Upon completion of the purchase, it will revert to StovePCPurchaseResult.extraData. |
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCOrderProduct orderProduct = new StovePCOrderProduct();
orderProduct.productId = 123456;
orderProduct.salePrice = 1000;
orderProduct.quantity = 1;
StovePCPurchaseOption option = new StovePCPurchaseOption();
option.operation = StovePCPurchaseOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewWidth = 800;
option.webviewHeight = 600;
StovePCStartPurchaseParam purchaseParam = new StovePCStartPurchaseParam();
purchaseParam.products = new StovePCOrderProduct[] { orderProduct };
purchaseParam.productsSize = 1;
purchaseParam.option = option;
purchaseParam.serviceTxnNo = "YOUR_SERVICE_TXN_NO";
purchaseParam.extraData = "";
IAP_StartPurchase(purchaseParam, OnStartPurchaseFinished);
Notes
productsSizemust match the actual length of theproductsarray.- Since
extraDatais preserved and returned until the purchase completion callback, it can be used to link the request and the result.
See Also
StovePCTermsOperation
Kind Enum · Module IAP · Version 3.0.0.4
Description
This value is assigned to the StovePCTermsOption.operation field and specifies how the terms and conditions agreement web view pop-up behaves when IAP_FetchTermsAgreement / IAP_FetchTermsAgreementEx is called.
This value indicates the operating mode, not success or failure.
Declaration
public enum StovePCTermsOperation
{
DEFAULT = 0,
WITH_WEBVIEW,
_MAX_COUNT
}
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | DEFAULT | By default, the system checks whether you have agreed to the terms and conditions. |
| 1 | WITH_WEBVIEW | We use a web view to process the terms and conditions agreement. |
| 2 | _MAX_COUNT | Not used (internal boundary value indicating the number of values) |
Example
using static Stove.PCSDK.IAP;
StovePCTermsOption option = new StovePCTermsOption();
option.operation = StovePCTermsOperation.WITH_WEBVIEW;
Notes
- StovePCPurchaseOperation and StovePCPaymentOperation have the same data type but belong to different enumeration types, so they cannot be used together.
See Also
StovePCTermsOption
Kind Struct · Module IAP · Version 3.0.0.4
Description
This is an input structure that specifies the behavior, position, and size of the web view pop-up for agreeing to the terms and conditions when IAP_FetchTermsAgreement / IAP_FetchTermsAgreementEx is called.
The caller passes the value by reference.
Declaration
public struct StovePCTermsOption
Members
| Name | Type | Required | Description |
|---|---|---|---|
operation | StovePCTermsOperation | Y | Here's how the Terms of Service consent pop-up works. |
webviewMode | WebViewMode | Y | Specifies whether to display the WebView externally or internally. |
webviewPosX | int | Y | This is the X coordinate of the WebView popup. |
webviewPosY | int | Y | This is the Y-coordinate of the WebView popup. |
webviewWidth | int | Y | This is the width of the WebView popup. |
webviewHeight | int | Y | This is the height of the WebView popup. |
Example
using static Stove.PCSDK.Base;
using static Stove.PCSDK.IAP;
StovePCTermsOption option = new StovePCTermsOption();
option.operation = StovePCTermsOperation.WITH_WEBVIEW;
option.webviewMode = WebViewMode.INTERNAL;
option.webviewPosX = 0;
option.webviewPosY = 0;
option.webviewWidth = 800;
option.webviewHeight = 600;
Notes
- StovePCPurchaseOption, StovePCPaymentOption, and StovePCWithdrawGameOption also have the same WebView position and size field configurations.
See Also
StovePCToken
Kind Struct · Module Base · Version 3.0.0.4
Description
StovePCToken is a structure passed by the OnRenewTokenFinished callback registered as Base_AccessTokenRenewed. The SDK populates the values and passes them to the callback.
Declaration
public struct StovePCToken
{
public string accessToken;
public int expireIn;
}
Members
| Name | Type | Description |
|---|---|---|
accessToken | string | Renewed Access Token |
expireIn | int | Expiration Time |
Example
using static Stove.PCSDK.Base;
void OnRenewTokenFinished(CallbackResult callbackResult, StovePCToken token)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement logic that uses `token.accessToken` and `token.expireIn`.
}
}
Base_AccessTokenRenewed(OnRenewTokenFinished);
Notes
- Base_GetAccessToken returns the string directly, rather than this structure.
StovePCTokenis passed only as a callback when the token is renewed.
See Also
StovePCTraceHint
Kind Struct · Module Base · Version 3.0.0.4 · Deprecated
Description
This feature is deprecated. It is not available in the new interface either.
StovePCTraceHint is a structure that is filled in and returned by Base_GetTraceHint. If the caller passes a previously declared variable as ref, the SDK fills in the values.
Declaration
public struct StovePCTraceHint
{
public string sessionId;
public string refSessionId;
public string uuid;
public string serviceProtocol;
public string refSourceType;
}
Members
| Name | Type | Description |
|---|---|---|
sessionId | string | Session ID |
refSessionId | string | Reference Session ID |
uuid | string | UUID |
serviceProtocol | string | Service Protocol |
refSourceType | string | Reference Source Type |
Example
using static Stove.PCSDK.Base;
StovePCTraceHint traceHint = default;
Result result = Base_GetTraceHint(ref traceHint);
if (result.IsSuccessful())
{
// Please implement logic to log items such as `traceHint.sessionId`.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- The value is not populated until Base_GetTraceHint is called.
See Also
StovePCUser
Kind Struct · Module Base · Version 3.0.0.4
Description
StovePCUser is a structure that is filled in and returned by Base_GetUser. If the caller passes a previously declared variable as ref, the SDK fills in the values.
Declaration
public struct StovePCUser
{
public string nickname;
public ulong gameUserId;
}
Members
| Name | Type | Description |
|---|---|---|
nickname | string | Nickname |
gameUserId | ulong | Game User ID |
Example
using static Stove.PCSDK.Base;
StovePCUser user = default;
Result result = Base_GetUser(ref user);
if (result.IsSuccessful())
{
// Please implement the logic that uses `user.nickname` and `user.gameUserId`.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- The value will not be populated until Base_GetUser is called.
See Also
StovePCVietnamAgeRatingInfo
Kind Struct · Module Base · Version 3.4.1
Description
StovePCVietnamAgeRatingInfo is a structure passed by the OnVietnamAgeRatingFinished callback registered as Base_VietnamAgeRatingNotification. The SDK populates the values and passes them to the callback.
Declaration
public struct StovePCVietnamAgeRatingInfo
{
public StoveOverlayMode overlayMode;
public int overlayType;
public float overlayScale;
public float overlayOpacity;
public int ageRating;
public string message;
public float displayPositionX;
public float displayPositionY;
public string language;
}
Members
| Name | Type | Description |
|---|---|---|
overlayMode | StoveOverlayMode | Overlay Display Mode |
overlayType | int | Overlay Type |
overlayScale | float | Overlay Size Ratio |
overlayOpacity | float | Overlay Transparency |
ageRating | int | Age Rating |
message | string | Display Message |
displayPositionX | float | Display Position X-Coordinate |
displayPositionY | float | Display Position Y-Coordinate |
language | string | Language |
Example
using static Stove.PCSDK.Base;
void OnVietnamAgeRatingFinished(CallbackResult callbackResult, StovePCVietnamAgeRatingInfo vietnamAgeRatingInfo)
{
if (callbackResult.result.IsSuccessful())
{
// such as vietnamAgeRatingInfo.message, vietnamAgeRatingInfo.ageRating, etc.
// Please implement the logic for drawing overlays.
}
}
Base_VietnamAgeRatingNotification(OnVietnamAgeRatingFinished);
Notes
- This structure is not created directly by the game; it is passed only via the Base_VietnamAgeRatingNotification callback.
- This callback must be registered after rendering is possible.
See Also
StovePCVietnamOverimmersionInfo
Kind Struct · Module Base · Version 3.4.1
Description
StovePCVietnamOverimmersionInfo is a structure passed by the OnVietnamOverimmersionFinished callback registered as Base_VietnamOverimmersionNotification. The SDK populates the values and passes them to the callback.
Declaration
public struct StovePCVietnamOverimmersionInfo
{
public StoveOverlayMode overlayMode;
public int overlayType;
public float overlayScale;
public float overlayOpacity;
public int ageRating;
public string message;
public string styledMessage;
public int elapsedTime;
public int exposureTime;
public float expandAnimationTime;
public float displayPositionX;
public float displayPositionY;
public string language;
}
Members
| Name | Type | Description |
|---|---|---|
overlayMode | StoveOverlayMode | Overlay Display Mode |
overlayType | int | Overlay Type |
overlayScale | float | Overlay Size Ratio |
overlayOpacity | float | Overlay Transparency |
ageRating | int | Age Rating |
message | string | Display Message |
styledMessage | string | Display message with applied style |
elapsedTime | int | Total Usage Time |
exposureTime | int | Exposure Time |
expandAnimationTime | float | Expansion Animation Duration |
displayPositionX | float | Display Position X Coordinate |
displayPositionY | float | Display Position Y Coordinate |
language | string | Language |
Example
using static Stove.PCSDK.Base;
void OnVietnamOverimmersionFinished(CallbackResult callbackResult, StovePCVietnamOverimmersionInfo vietnamOverimmersionInfo)
{
if (callbackResult.result.IsSuccessful())
{
// such as vietnamOverimmersionInfo.message, vietnamOverimmersionInfo.styledMessage, etc.
// Please implement the logic for drawing overlays.
}
}
Base_VietnamOverimmersionNotification(OnVietnamOverimmersionFinished);
Notes
- This structure is not created directly by the game; it is passed only via the Base_VietnamOverimmersionNotification callback.
- This callback must be registered after rendering is possible.
See Also
StovePCVoidedPurchase
Kind Struct · Module IAP · Version 3.0.0.4 · Deprecated
Description
The refund inquiry feature has been deprecated. It is not available in the new interface.
This is the element type of the StovePCVoidedPurchase[] array passed as a callback to IAP_FetchVoidedPurchases. It represents a single purchase record that has been canceled (refunded) on the marketplace.
This is an output-only structure that the SDK populates with values and returns via a callback. It is not created directly by the caller.
Declaration
public struct StovePCVoidedPurchase
Members
| Name | Type | Description |
|---|---|---|
tid | long | This is the transaction ID. |
marketCode | string | This is the marketplace code where the purchase took place. |
productId | string | This is the product ID. |
marketProductId | string | This is the product ID used in the marketplace. |
userId | string | This is the user ID. |
characterNo | long | This is the character number. |
purchaseMillis | long | This is the purchase time (in milliseconds). |
voidedMillis | long | This is the time (in milliseconds) when the cancellation was processed. |
Example
using static Stove.PCSDK.IAP;
void OnFetchVoidedPurchasesFinished(CallbackResult callbackResult, StovePCVoidedPurchase[] voidedPurchase)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var voided in voidedPurchase)
{
// Please implement the logic for handling canceled payments using `voided.productId`, `voided.voidedMillis`, and similar variables.
}
}
Notes
- IAP_FetchVoidedPurchasesEx and StovePCVoidedPurchasesEx, which previously provided market-specific filtering and additional field queries, are no longer available in the SDK.
See Also
StovePCVoidedPurchasesEx
Kind Struct · Module IAP · Version 3.4.1 · Deprecated
Description
This type is not currently supported by the SDK. The
IAP_FetchVoidedPurchasesEx()function, which used this structure, is also not supported. The refund inquiry feature itself has been deprecated.
This is the element type of the StovePCVoidedPurchasesEx[] array passed to the callback of IAP_FetchVoidedPurchasesEx. It serves the same purpose as StovePCVoidedPurchase, but provides additional fields such as membership number (memberNo), GUID, and market transaction ID.
This is an output-only structure that the SDK populates with values and returns via a callback. It is not created directly by the caller.
Declaration
public struct StovePCVoidedPurchasesEx
Members
| Name | Type | Description |
|---|---|---|
tid | long | This is the transaction ID. |
marketCode | string | This is the marketplace code where the purchase was made. |
memberNo | long | This is your membership number. |
guid | string | This is a GUID (character identifier). |
characterNo | long | This is the character number. |
inserviceItemId | string | This is the item ID within the service. |
marketItemId | string | This is the item ID used in the Market. |
marketTid | string | This is the transaction ID from the marketplace. |
marketUserId | string | This is the user ID for the marketplace. |
purchaseDt | long | This is the time of purchase. |
voidedDt | long | This is the time the cancellation was processed. |
Example
using static Stove.PCSDK.IAP;
void OnFetchVoidedPurchasesExFinished(CallbackResult callbackResult, StovePCVoidedPurchasesEx[] voidedPurchase)
{
if (!callbackResult.result.IsSuccessful())
{
return;
}
foreach (var voided in voidedPurchase)
{
// Please implement the logic for recovering canceled payments using variables such as `voided.marketTid` and `voided.voidedDt`.
}
}
Notes
- The field structure differs from StovePCVoidedPurchase, and the two are not interchangeable. This is specific to IAP_FetchVoidedPurchasesEx.
See Also
StovePCVoidedPurchasesMarketType
Kind Enum · Module IAP · Version 3.4.1 · Deprecated
Description
This type is not currently supported by the SDK.
IAP_FetchVoidedPurchasesEx(), which used this value, is also no longer supported. The refund inquiry feature itself has been deprecated.
Pass this to the marketType parameter of IAP_FetchVoidedPurchasesEx to specify which marketplace's purchase cancellation records to retrieve.
Declaration
public enum StovePCVoidedPurchasesMarketType
{
ALL = 0,
STEAM = 1,
GOOGLE_PLAY = 2,
APPLE_APP_STORE = 3
}
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | ALL | View cancellation history for all markets |
| 1 | STEAM | This feature only displays the cancellation history on the Steam Marketplace. |
| 2 | GOOGLE_PLAY | This feature only displays the cancellation history from the Google Play Store. |
| 3 | APPLE_APP_STORE | This feature only retrieves cancellation history from the Apple App Store. |
Example
using static Stove.PCSDK.IAP;
IAP_FetchVoidedPurchasesEx(StovePCVoidedPurchasesMarketType.STEAM, OnFetchVoidedPurchasesExFinished);
Notes
- Prior to version 3.4.1, IAP_FetchVoidedPurchases only retrieves the entire transaction history without distinguishing between markets.
See Also
View_AutoPopup
Kind Function · Module View · Version 3.0.0.4
Description
AutoPopup is launched using WebView. The WebView is displayed using the method specified as mode (external browser or internal style).
It must be initialized to View_Initialize or View_InitializeWithWndInfo before the call.
Declaration
public static void View_AutoPopup(WebViewMode mode, OnPopupFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
mode | WebViewMode | Y | This is the mode in which WebView runs. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of the WebView execution. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is passed once when the WebView execution results are returned. The callback runs on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The pop-up feature has not been initialized. You must first call View_Initialize. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups before creating a new one | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For a complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnAutoPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
View_AutoPopup(WebViewMode.INTERNAL, OnAutoPopupFinished);
Notes
- Use View_AutoPopupEx to receive a notification when the popup's native resources are released.
- To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
See Also
View_AutoPopupEx
Kind Function · Module View · Version 3.3.4
Description
Launch AutoPopup using WebView. It works the same as View_AutoPopup, but you can also receive the onDestroy callback, which is triggered when the popup's native resources have been completely released.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before it is called.
Declaration
public static void View_AutoPopupEx(WebViewMode mode, OnPopupFinished onFinished, OnViewPopupDestroyFinished onDestroy);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
mode | WebViewMode | Y | This is the mode in which WebView runs. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of running WebView. |
onDestroy | OnViewPopupDestroyFinished | N | This is the callback function that is called when the pop-up is closed. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
public delegate void OnViewPopupDestroyFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is called once when the WebView execution results are returned. onDestroy is called once when the popup's native resources have been completely released. Both callbacks are executed on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The pop-up feature has not been initialized. You must call View_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all pop-ups that were already open before creating a new pop-up | x | |
| 85 | WEBVIEW_CLOSE_FAIL | Failed to close the pop-up (passed to the onDestroy callback) | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnAutoPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnAutoPopupDestroyed(CallbackResult callbackResult)
{
// Please implement the logic after the pop-up resources have been released.
}
View_AutoPopupEx(WebViewMode.INTERNAL, OnAutoPopupFinished, OnAutoPopupDestroyed);
Notes
- Unlike View_AutoPopup, it also receives the
onDestroycallback, which is notified when the popup is destroyed. - To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
See Also
View_CloseAllPopups
Kind Function · Module View · Version 3.1.3
Description
Closes all pop-ups opened using the pop-up feature.
Declaration
public static Result View_CloseAllPopups();
Parameters
None
Returns
| Type | Description |
|---|---|
Result | Here are the results of the function call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The pop-up feature is not initialized | x | |
| 80 | VIEWUI_NOT_INITIALIZED | The WebView of the popup to be closed has not been initialized | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all open pop-ups | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
Result result = View_CloseAllPopups();
if (result.IsSuccessful())
{
// Please implement the logic for when the operation is successful.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- This is used to close all pop-ups opened by View_AutoPopup, View_ManualPopup, View_NewsPopup, View_CouponPopup, etc., at once.
See Also
View_CouponPopup
Kind Function · Module View · Version 3.0.0.4
Description
Launch CouponPopup using WebView.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before being called.
Declaration
public static void View_CouponPopup(WebViewMode mode, OnPopupFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
mode | WebViewMode | Y | This is the mode for running WebView. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of the WebView execution. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is passed once when the WebView execution results are returned. The callback runs on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | The game server world connection information (worldId) is empty (not connected to the world). | x | |
| 17 | NOT_INITIALIZED | The pop-up feature has not been initialized. You must call View_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView that displays the pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up web view | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups before creating a new one | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For a complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnCouponPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
View_CouponPopup(WebViewMode.INTERNAL, OnCouponPopupFinished);
Notes
- Use View_CouponPopupEx to receive a notification when the pop-up's native resources are released.
- To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
See Also
View_CouponPopupEx
Kind Function · Module View · Version 3.3.4
Description
Launch CouponPopup using WebView. This works the same as View_CouponPopup, but you can also receive the onDestroy callback, which is triggered when the popup's native resources have been completely released.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before being called.
Declaration
public static void View_CouponPopupEx(WebViewMode mode, OnPopupFinished onFinished, OnViewPopupDestroyFinished onDestroy);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
mode | WebViewMode | Y | This is the mode in which WebView runs. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of running WebView. |
onDestroy | OnViewPopupDestroyFinished | N | This is the callback function that is called when the popup is closed. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
public delegate void OnViewPopupDestroyFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is called once when the WebView execution results are available. onDestroy is called once when the popup's native resources have been fully released. Both callbacks are executed on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | The game server world connection information (worldId) is empty (not connected to the world) | x | |
| 17 | NOT_INITIALIZED | The pop-up feature has not been initialized. You must call View_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups before creating a new one | x | |
| 85 | WEBVIEW_CLOSE_FAIL | Failed to close the popup (passed to the onDestroy callback) | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnCouponPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnCouponPopupDestroyed(CallbackResult callbackResult)
{
// Please implement the logic after the pop-up resources have been released.
}
View_CouponPopupEx(WebViewMode.INTERNAL, OnCouponPopupFinished, OnCouponPopupDestroyed);
Notes
- Unlike View_CouponPopup, it also receives the
onDestroycallback, which is triggered when the popup is destroyed. - To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
See Also
View_FetchWebOpenKey
Kind Function · Module View · Version 3.3.0 · Deprecated
Description
This feature is deprecated. It is not available in the new interface either.
Obtain a one-time key to use the "Web Open in Game" feature. Use this only when you need to display the Stove Community or Customer Support via an external browser.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before the call.
Declaration
public static void View_FetchWebOpenKey(OnFetchWebOpenKeyFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
onFinished | OnFetchWebOpenKeyFinished | Y | This is a callback function that receives the results of the FetchWebOpenKey execution. |
Returns
None
Callback
public delegate void OnFetchWebOpenKeyFinished(CallbackResult result, string key);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
key | string | This is a one-time key that has been issued. |
onFinished is dispatched once when the key issuance result is available. The callback runs on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The pop-up feature has not been initialized. You must call View_Initialize first. | x | |
| 25 | RESPONSE_VALUE_IS_NULL | The server response data is empty | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 26 | RESPONSE_INVALID_VALUE_FORMAT | The server response data format is invalid. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 249 | NETWORK_TRANSPORT_ERROR | An error occurred at the network transport layer | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary problem has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnFetchWebOpenKeyFinished(CallbackResult callbackResult, string key)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic to open the Stove Community, Customer Support, and other pages in an external browser using the key.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
View_FetchWebOpenKey(OnFetchWebOpenKeyFinished);
Notes
- Use this only when you need to display the Stove Community or Customer Support page in an external browser.
See Also
View_GetVersion
Kind Function · Module View · Version 3.4.1
Description
Retrieves version information for the pop-up feature.
Declaration
public static Result View_GetVersion(ref string version, uint length);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
version | ref string | Y | This is the variable that will hold the version string. Any value it contains before the call is ignored and replaced with the resulting string after the call. |
length | uint | Y | This is the length of the string buffer used internally. |
Returns
| Type | Description |
|---|---|
Result | Here are the results of the function call. Check whether it was successful by looking at result.IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | version No buffer, length is 0, or the buffer size is insufficient to hold the string | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to check the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
This function actually returns the BaseSDK integrated version as-is, rather than the ViewSDK version itself. For a complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
string version = null;
Result result = View_GetVersion(ref version, 64);
if (result.IsSuccessful())
{
// Please implement the logic for when the operation succeeds. Use the `version` parameter.
}
else
{
// Please implement the logic for when a failure occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
See Also
View_Initialize
Kind Function · Module View · Version 3.0.0.4
Description
Resets the pop-up functionality. Use this when the parent window handle for the Internal Style pop-up is not required. If you need to specify a parent window handle, use View_InitializeWithWndInfo.
You must call this function first before calling any other functions provided by the popup feature.
Declaration
public static Result View_Initialize();
Parameters
None
Returns
| Type | Description |
|---|---|
Result | Here are the results of the function call. Check result.IsSuccessful() to see if it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 16 | BASE_NOT_INITIALIZED | BaseSDK was not initialized. You must call Base_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | The pop-up feature is already initialized. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the popup | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to verify the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred inside the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For a complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
Result result = View_Initialize();
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- Use View_InitializeWithWndInfo to specify the parent window handle for the Internal Style pop-up.
- When you are finished using it, release the resource to View_UnInitialize.
See Also
View_InitializeWithWndInfo
Kind Function · Module View · Version 3.3.3
Description
Resets the pop-up functionality. Use this when you need the handle to the main window that will serve as the parent window for the Internal Style pop-up.
You must call this function first before calling any other functions provided by the pop-up feature.
Declaration
public static Result View_InitializeWithWndInfo(IntPtr mainWndHandle);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
mainWndHandle | IntPtr | Y | This is the handle (HWND) of the main window that will serve as the parent window for the Internal Style pop-up. |
Returns
| Type | Description |
|---|---|
Result | Here are the results of the function call. Check whether it was successful by looking at result.IsSuccessful(). |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 16 | BASE_NOT_INITIALIZED | BaseSDK has not been initialized. You must call Base_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | The pop-up feature is already initialized. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the pop-up | x | |
| 251 | PCSDK_DLL_NOT_FOUND | Failed to verify the version because the SDK file path could not be found. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
Result result = View_InitializeWithWndInfo(mainWndHandle);
if (result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- If you do not need the parent window handle for the Internal Style pop-up, use View_Initialize.
- When you are finished using it, release the resource to View_UnInitialize.
See Also
View_ManualPopup
Kind Function · Module View · Version 3.0.0.4
Description
Use WebView to launch the ManualPopup specified as resourceKey.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before the call.
Declaration
public static void View_ManualPopup(string resourceKey, WebViewMode mode, OnPopupFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
resourceKey | string | Y | This is the ResourceKey for Manual Popup. |
mode | WebViewMode | Y | This is the mode in which WebView runs. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of executing WebView. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is passed once when the WebView execution results are returned. The callback runs on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | resourceKey is an empty string | x | |
| 17 | NOT_INITIALIZED | The popup feature has not been initialized. You must call View_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups before creating a new one | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary problem has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For a complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnManualPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
View_ManualPopup("YOUR_RESOURCE_KEY", WebViewMode.INTERNAL, OnManualPopupFinished);
Notes
- Use View_ManualPopupEx to receive a notification until the popup's native resources are released.
- To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
See Also
View_ManualPopupEx
Kind Function · Module View · Version 3.3.4
Description
Use WebView to launch the ManualPopup specified as resourceKey. It functions the same as View_ManualPopup, but you can also receive the onDestroy callback, which is triggered when the popup's native resources have been completely released.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before the call.
Declaration
public static void View_ManualPopupEx(string resourceKey, WebViewMode mode, OnPopupFinished onFinished, OnViewPopupDestroyFinished onDestroy);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
resourceKey | string | Y | This is the ResourceKey for Manual Popup. |
mode | WebViewMode | Y | This is the mode in which WebView runs. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of the WebView execution. |
onDestroy | OnViewPopupDestroyFinished | N | This is the callback function that is called when the pop-up is closed. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
public delegate void OnViewPopupDestroyFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is called once when the WebView execution results are returned. onDestroy is called once when the popup’s native resources have been fully released. Both callbacks are executed on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 5 | INVALID_PARAM | resourceKey is an empty string | x | |
| 17 | NOT_INITIALIZED | The pop-up feature has not been initialized. You must call View_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the popup | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups before creating a new one | x | |
| 85 | WEBVIEW_CLOSE_FAIL | Failed to close the popup (passed to the onDestroy callback) | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnManualPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnManualPopupDestroyed(CallbackResult callbackResult)
{
// Please implement the logic after the pop-up resources have been released.
}
View_ManualPopupEx("YOUR_RESOURCE_KEY", WebViewMode.INTERNAL, OnManualPopupFinished, OnManualPopupDestroyed);
Notes
- Unlike View_ManualPopup, it also receives a
onDestroycallback that is triggered when the popup is destroyed. - To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
See Also
View_NewsPopup
Kind Function · Module View · Version 3.0.0.4
Description
Launch NewsPopup using WebView.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before being called.
Declaration
public static void View_NewsPopup(WebViewMode mode, OnPopupFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
mode | WebViewMode | Y | This is the mode in which WebView runs. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of running WebView. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is passed once when the WebView execution results are returned. The callback runs on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The pop-up feature has not been initialized. You must call View_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups before creating a new one | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | There was a temporary issue. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnNewsPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
View_NewsPopup(WebViewMode.INTERNAL, OnNewsPopupFinished);
Notes
- Use View_NewsPopupEx to receive a notification when the popup's native resources are released.
- To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
See Also
View_NewsPopupEx
Kind Function · Module View · Version 3.3.4
Description
Launch NewsPopup using WebView. It works the same as View_NewsPopup, but you can also receive the onDestroy callback, which is triggered when the popup's native resources have been completely released.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before the call.
Declaration
public static void View_NewsPopupEx(WebViewMode mode, OnPopupFinished onFinished, OnViewPopupDestroyFinished onDestroy);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
mode | WebViewMode | Y | This is the mode in which WebView runs. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of executing WebView. |
onDestroy | OnViewPopupDestroyFinished | N | This is the callback function that is called when the pop-up is closed. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
public delegate void OnViewPopupDestroyFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is called once when the WebView execution results are returned. onDestroy is called once when the popup's native resources have been completely released. Both callbacks are executed on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The pop-up feature has not been initialized. You must call View_Initialize first. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups before creating a new one | x | |
| 85 | WEBVIEW_CLOSE_FAIL | Failed to close the popup (passed to the onDestroy callback) | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnNewsPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnNewsPopupDestroyed(CallbackResult callbackResult)
{
// Please implement the logic after the pop-up resources have been released.
}
View_NewsPopupEx(WebViewMode.INTERNAL, OnNewsPopupFinished, OnNewsPopupDestroyed);
Notes
- Unlike View_NewsPopup, it also receives a callback
onDestroythat is notified when the popup is destroyed. - To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
See Also
View_SetPopupDisallowed
Kind Function · Module View · Version 3.0.0.4
Description
Suppresses the display of the pop-up identifier specified in popupDisallowed for the specified number of days (days).
It must be initialized to View_Initialize or View_InitializeWithWndInfo before the call.
Declaration
public static void View_SetPopupDisallowed(StovePCPopupDisallowed popupDisallowed, OnSetPopupDisallowedFinished onFinished);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
popupDisallowed | StovePCPopupDisallowed | Y | This is the information required when pop-ups are not displayed (pop-up identifier, suppression period). |
onFinished | OnSetPopupDisallowedFinished | Y | This is a callback function that receives the results of the PopupDisallowed execution. |
Returns
None
Callback
public delegate void OnSetPopupDisallowedFinished(CallbackResult result);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
onFinished is called once when the processing results are available. The callback runs on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 1 | FAIL | Failed to save pop-up display limit information locally | x | |
| 17 | NOT_INITIALIZED | The popup feature has not been initialized. You must call View_Initialize first. | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | There was a temporary issue. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For a complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnSetPopupDisallowedFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when a failure occurs.
}
}
var popupDisallowed = new StovePCPopupDisallowed
{
popupId = 1001,
days = 7,
};
View_SetPopupDisallowed(popupDisallowed, OnSetPopupDisallowedFinished);
Notes
- This function is not an API that closes the pop-up; rather, it is an API that suppresses the pop-up from reappearing for a specified period of time.
- To immediately close the pop-up displayed on the screen, use View_CloseAllPopups.
See Also
View_UnInitialize
Kind Function · Module View · Version 3.0.0.4
Description
Releases resources associated with the pop-up feature. This function pairs with View_Initialize or View_InitializeWithWndInfo.
Declaration
public static Result View_UnInitialize();
Parameters
None
Returns
| Type | Description |
|---|---|
Result | Here are the results of the function call. Check result.IsSuccessful() to determine whether it was successful. |
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The pop-up feature is not initialized. | x | |
| 81 | VIEWUI_UNINIT_FAILED | Failed to close the pop-up WebView | x | |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check Result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
Result result = View_UnInitialize();
if (result.IsSuccessful())
{
// Please implement the logic for the success case.
}
else
{
// Please implement the logic for when a failure occurs.
}
Notes
- This function is synchronous and does not accept callbacks.
- This is the termination function that pairs with View_Initialize / View_InitializeWithWndInfo.
See Also
View_VerifyIdentificationPopup
Kind Function · Module View · Version 3.3.4
Description
Use WebView to launch the identity verification pop-up. Specify whether to use SDI for verification with compareIdentifier; if set to false, onDestroy is provided instead of simKey.
It must be initialized to View_Initialize or View_InitializeWithWndInfo before the call.
Starting with version 3.4.1, this feature has been restricted to use in Korea.
Declaration
public static void View_VerifyIdentificationPopup(bool compareIdentifier, WebViewMode mode,
OnPopupFinished onFinished, OnVerifyIdentificationPopupDestroyFinished onDestroy);
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
compareIdentifier | bool | Y | This refers to whether verification is performed using SDI. If false, simKey is provided. |
mode | WebViewMode | Y | This is the mode in which WebView runs. |
onFinished | OnPopupFinished | Y | This is a callback function that receives the results of the WebView execution. |
onDestroy | OnVerifyIdentificationPopupDestroyFinished | Y | This is the callback function that is called when the pop-up is closed. |
Returns
None
Callback
public delegate void OnPopupFinished(CallbackResult result);
public delegate void OnVerifyIdentificationPopupDestroyFinished(CallbackResult result, string simKey);
| Name | Type | Description |
|---|---|---|
result | CallbackResult | This is the callback result. |
simKey | string | This is the SIM key issued upon successful authentication. |
onFinished is sent once when the WebView execution results are returned. onDestroy is triggered once when the identity verification pop-up closes, and if verification is successful, simKey is triggered as well. Both callbacks are executed on the thread that called Base_RunCallback().
Error Codes
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 17 | NOT_INITIALIZED | The popup feature has not been initialized. You must call View_Initialize first. | x | |
| 31 | NOT_SUPPORTED_COUNTRY | This feature is not supported when the call is made from outside South Korea. | x | |
| 80 | VIEWUI_NOT_INITIALIZED | Failed to initialize the WebView to display the pop-up | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a pop-up WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Unable to load the page in the pop-up WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close all previously open pop-ups before creating a new one | x | |
| 85 | WEBVIEW_CLOSE_FAIL | Failed to close the pop-up (passed to the onDestroy callback) | x | |
| 87 | NO_POPUP_DATA | There is no pop-up configuration information to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| 253 | UNMANAGED_EXCEPTION | An exception occurred within the Native SDK | O | A temporary issue has occurred. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | An exception occurred within the C# wrapper (e.g., marshaling). Please check CallbackResult.result.exceptionMessage. | O | A temporary issue has occurred. Please try again. [OK] |
For the complete list, see ViewSDKResultCode.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnVerifyIdentificationPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else
{
// Please implement the logic for when an error occurs.
}
}
void OnVerifyIdentificationPopupDestroyed(CallbackResult callbackResult, string simKey)
{
if (!string.IsNullOrEmpty(simKey))
{
// Please use simKey wherever needed.
}
}
View_VerifyIdentificationPopup(false, WebViewMode.INTERNAL,
OnVerifyIdentificationPopupFinished, OnVerifyIdentificationPopupDestroyed);
Notes
- Unlike other popup APIs, the
onDestroycallback type isOnVerifyIdentificationPopupDestroyFinishedand passes an additionalsimKeyargument. - If
onFinishedisnull, thencompareIdentifieris automatically converted tofalse, triggering the internal function. - To close all pop-ups displayed on the screen at once, use View_CloseAllPopups.
Changelog
| Version | Change |
|---|---|
| 3.3.4 | First Published |
| 3.4.1 | Limited to features available only in Korea |
See Also
ViewSDKMethod
Kind Enum · Module View · Version 3.0.0.4
Description
This value, retrieved as Result.methodCode, identifies which method of the pop-up feature generated this result.
Declaration
public enum ViewSDKMethod
{
INITIALIZE = 1,
UNINITIALIZE = 2,
// ... See the "Values" table below
FETCH_WEB_OPEN_KEY = 162,
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 1 | INITIALIZE | View_Initialize / View_InitializeWithWndInfo |
| 2 | UNINITIALIZE | View_UnInitialize |
| 5 | GET_VERSION | View_GetVersion |
| — | 6 ~ 79 | Not in use (reserved section) |
| 80 | FETCH_AUTO | Judging by the name, this appears to be an internal step for fetching AutoPopup content; no separate public API is provided. |
| 81 | AUTO_POPUP | View_AutoPopup / View_AutoPopupEx |
| 82 | FETCH_MANUAL | Judging by the name, this appears to be an internal step for fetching ManualPopup content; no separate public API is provided. |
| 83 | MANUAL_POPUP | View_ManualPopup / View_ManualPopupEx |
| 84 | FETCH_NEWS | Judging by the name, this appears to be an internal step for fetching NewsPopup content; no separate public API is provided. |
| 85 | NEWS_POPUP | View_NewsPopup / View_NewsPopupEx |
| 86 | FETCH_COUPON | Judging by the name, this appears to be an internal step for fetching CouponPopup content; no separate public API is provided. |
| 87 | COUPON_POPUP | View_CouponPopup / View_CouponPopupEx |
| 88 | FETCH_COMMUNITY | Judging by the name, this appears to be an internal step for fetching community content; no separate public API is provided. |
| 89 | COMMUNITY_POPUP | Based on the name, it appears to be designed to handle community pop-ups, and no separate public API is provided. |
| 90 | FETCH_VERIFY_IDENTIFICATION | Based on the name, this appears to be an internal process for retrieving (fetching) identity verification content; no separate public API is provided. |
| 91 | VERIFY_IDENTIFICATION_POPUP | View_VerifyIdentificationPopup |
| 92 | FETCH_CS | Based on the name, this appears to be an internal process for retrieving (fetching) customer service content; no separate public API is provided. |
| 93 | CS_POPUP | Based on the name, it appears to handle customer service pop-ups, and no separate public API is provided. |
| — | 94 ~ 159 | Not in use (reserved section) |
| 160 | SET_POPUP_DISALLOWED | View_SetPopupDisallowed |
| 161 | CLOSE_ALL_POPUPS | View_CloseAllPopups |
| 162 | FETCH_WEB_OPEN_KEY | View_FetchWebOpenKey |
Values (3, 4) that contain INTERNAL in their names are excluded from the table. Values intended for internal use only are not included in the document.
Example
using static Stove.PCSDK.View;
Result result = View_Initialize();
if (result.methodCode == (uint)ViewSDKMethod.INITIALIZE)
{
// Please implement logic to verify that this result was generated by a call to `View_Initialize()`.
}
Notes
- Even for the same pop-up, the values differ between the new interface and the old one. The new interface (such as
Stove_AutoPopup) returns values from the1000series ofEStoveViewMethodCode. The old interface retains the values listed in this document. While using both versions simultaneously, please separate the log aggregation criteria by version. - There are no corresponding public APIs for the values
FETCH_*,COMMUNITY_POPUP, andCS_POPUP. - Since
Result.methodCodeis of typeuint, it is cast to(uint)ViewSDKMethod....when compared with this enumeration value.
See Also
ViewSDKResultCode
Kind Result Code · Module View · Version 3.0.0.4
Description
This is the value returned by the query Result.resultCode / CallbackResult.result.resultCode. A value of 0 (SUCCESS) indicates success.
Declaration
public enum ViewSDKResultCode
{
SUCCESS = 0,
FAIL = 1,
// ... See the "Values" table below
NO_POPUP_DATA = 87,
}
Enum Values
General Results
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 0 | SUCCESS | Success | x | |
| 1 | FAIL | General failure. Check log/errorMessage for detailed causes. | x |
Configuration/Parameter Validation Failed
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 2 | INVALID_CONFIG | The setting is invalid. Please check the setting. | x | |
| 3 | INVALID_LOG_LEVEL | The log level value is invalid. Please verify the log level value. | x | |
| 4 | INVALID_LOG_PATH | The log path is invalid. Please verify the log path. | x | |
| 5 | INVALID_PARAM | The parameter is invalid. Please check the parameter value in the calling code and correct it. | x | |
| — | 6 ~ 15 | Not in use (reserved section) |
Initialization Error
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 16 | BASE_NOT_INITIALIZED | The SDK has not been initialized. Call Base_Initialize() first. | x | |
| 17 | NOT_INITIALIZED | The pop-up feature is not initialized. Call View_Initialize first. | x | |
| 18 | ALREADY_INITIALIZED | It has already been initialized. Remove the duplicate initialization call. | x |
Token/Entity Error
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 19 | INVALID_ACCESS_TOKEN | The AccessToken is invalid. Please reissue the token. | O | Your login session has expired. Please close the game and restart it. [OK] |
| 20 | NULL_TOKEN_ENTITY | The token entity is null. Check the token issuance status. | x | |
| 21 | NULL_ENTITY | The entity is null. Check whether the response object is null. | x |
HTTP/Response Errors
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 22 | HTTP_ERROR | An HTTP error has occurred. Please check your network connection and try again. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 23 | RESPONSE_ERROR | This is a server response error. Please check the server response. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 24 | RESPONSE_INVALID_CODE | The server response code is invalid. Please check the server response code. | O | The network connection is unstable. Please check your network status and try again. [OK] |
| 25 | RESPONSE_VALUE_IS_NULL | The server response value is null. Please check the server response value. | O | The network connection is unstable. Please check your network connection and try again. [OK] |
| 26 | RESPONSE_INVALID_VALUE_FORMAT | The server response format is invalid. Please verify the server response format. | O | The network connection is unstable. Please check your network status and try again. [OK] |
Errors Related to 81Plug
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 27 | LOG_81PLUG_ERROR | An error occurred while processing 81Plug logs. Please check the log and network status. | x | |
| 28 | UPDATE_81PLUG_FEED_ERROR | An error occurred while updating the 81Plug feed. Please check the logs and network status. | x |
Other Status
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 29 | ASYNC_OPERATION_IN_PROGRESS | An asynchronous operation is already in progress. Please call again after the current asynchronous operation has completed. | x | |
| 30 | BASE_UNINITIALIZED | The SDK has already been uninitialized. Please call Base_Initialize() again. | x | |
| 31 | NOT_SUPPORTED_COUNTRY | This country/region is not supported. Please check the country/region restrictions and stop the call. | x | |
| — | 32 ~ 79 | Not in use (reserved section) |
Error specific to pop-ups
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 80 | VIEWUI_NOT_INITIALIZED | The View UI has not been initialized. Check the preceding calls: View_Initialize / View_InitializeWithWndInfo | x | |
| 81 | VIEWUI_UNINIT_FAILED | Failed to uninitialize the View UI (UnInit) | x | |
| 82 | WEBVIEW_CREATE_FAIL | Failed to create a WebView | x | |
| 83 | WEBVIEW_LOAD_URL_FAIL | Failed to load the URL in the WebView | x | |
| 84 | WEBVIEW_CLOSE_ALL_FAIL | Failed to close the entire WebView | x | |
| 85 | WEBVIEW_CLOSE_FAIL | Failed to close the WebView | x | |
| 86 | WEBVIEW_CREATE_COOKIE_FAIL | Failed to create a WebView cookie | O | The page cannot be loaded. Please try again. [OK] |
| 87 | NO_POPUP_DATA | There is no pop-up data to display. | O | There is no pop-up configuration information, so there is no window to display. [OK] |
| — | 88 ~ 250 | Not in use (reserved section) |
System/Runtime Failure
| Code | Name | Description | Show to User | In-Game Message |
|---|---|---|---|---|
| 251 | PCSDK_DLL_NOT_FOUND | The PCSDK DLL cannot be found. Check the location of the PCSDK DLL. | x | |
| 252 | NOT_IMPLEMENTED | This feature has not been implemented. Please remove the call or check for an alternative API. | x | |
| 253 | UNMANAGED_EXCEPTION | An unmanaged exception has occurred. Check the exception log. | O | There was a temporary issue. Please try again. [OK] |
| 254 | MANAGED_EXCEPTION | A managed exception has occurred. Check the exception log. | O | There was a temporary issue. Please try again. [OK] |
| 255 | UNKNOWN_ERROR | An unknown error has occurred. Check the detailed log. | x |
If you receive the code below, you must exit the game. The game cannot proceed normally.
19INVALID_ACCESS_TOKEN— Your login session has expired; you must exit the game and restart it.
Example
using static Stove.PCSDK.View;
using static Stove.PCSDK.Base;
void OnAutoPopupFinished(CallbackResult callbackResult)
{
if (callbackResult.result.IsSuccessful())
{
// Please implement the logic for a successful outcome.
}
else if (callbackResult.result.resultCode == (uint)ViewSDKResultCode.NO_POPUP_DATA)
{
// Please implement the logic for when there is no pop-up data to display.
}
else
{
// Please implement the logic for other failure scenarios.
}
}
Notes
- The ranges 0–31 and 251–255 have the same values and meanings as
*SDKResultCodein other modules. - Since
resultCodeis of typeuint, a type cast is required when comparing it to this enumeration value.
See Also
WebViewMode
Kind Enum · Module Base · Version 3.0.0.4
Description
Based on the value names (EXTERNAL, INTERNAL), WebViewMode is presumed to be a value that determines whether the WebView opens in an external browser or in the SDK's internal view.
Declaration
public enum WebViewMode
{
EXTERNAL,
INTERNAL
};
Enum Values
| Code | Name | Description |
|---|---|---|
| 0 | EXTERNAL | Opens the WebView using an external method |
| 1 | INTERNAL | Opens the WebView internally |
Example
using static Stove.PCSDK.Base;
WebViewMode mode = WebViewMode.EXTERNAL;
Notes
- None
See Also
- None