Execution
Open the Playnanoo Help Desk to allow users to submit and view inquiries.
This feature uses the help.playnanoo.com domain.
Feature Overview
The Help Desk operates in two modes:
- Guest Mode: Allows inquiries from users who are not logged in
- Player Mode: Registers inquiries with logged-in user information
Authentication Method
Player mode authenticates through the authKey parameter.
AuthKey Generation
#include "Misc/Base64.h"
FString CreateAuthKey(const FString& GameId, const FString& UserId)
{
// AuthKey = Base64(GameId + UserId)
FString AuthKeySource = GameId + UserId;
return FBase64::Encode(AuthKeySource);
}
Unreal C++ Implementation
Opening in Player Mode
Opens the Help Desk with logged-in user information.
void OpenHelpDeskPlayerMode()
{
// AuthKey 생성
FString AuthKey = CreateAuthKey(GameId, UUID);
// URL 생성
FString Url = FString::Printf(
TEXT("https://help.playnanoo.com/%s?userId=%s&authKey=%s"),
*GameId,
*FGenericPlatformHttp::UrlEncode(UUID),
*FGenericPlatformHttp::UrlEncode(AuthKey)
);
// 브라우저에서 열기
FPlatformProcess::LaunchURL(*Url, nullptr, nullptr);
}
URL Parameters:
| Parameter | Description |
|---|---|
| userId | Unique user ID (UUID) |
| authKey | Base64 encoded authentication key |
Opening in Guest Mode
Help Desk for users who are not logged in. No authentication required.
void OpenHelpDeskGuestMode()
{
FString Url = FString::Printf(
TEXT("https://help.playnanoo.com/%s?mode=guest"),
*GameId
);
FPlatformProcess::LaunchURL(*Url, nullptr, nullptr);
}
Optional Parameters
You can pass additional custom information per game.
void OpenHelpDeskWithOptional()
{
// Optional 파라미터를 JSON으로 생성
TSharedPtr<FJsonObject> OptionalJson = MakeShareable(new FJsonObject());
OptionalJson->SetStringField(TEXT("GAME_SERVER"), TEXT("ASIA"));
OptionalJson->SetStringField(TEXT("PLAYER_LEVEL"), TEXT("50"));
OptionalJson->SetStringField(TEXT("CHARACTER_CLASS"), TEXT("Warrior"));
// JSON을 문자열로 변환
FString OptionalString;
TSharedRef<TJsonWriter<>> Writer = TJsonWriterFactory<>::Create(&OptionalString);
FJsonSerializer::Serialize(OptionalJson.ToSharedRef(), Writer);
// Base64 인코딩
FString OptionalBase64 = FBase64::Encode(OptionalString);
// AuthKey 생성
FString AuthKey = CreateAuthKey(GameId, UUID);
// URL 생성 (optional 파라미터 포함)
FString Url = FString::Printf(
TEXT("https://help.playnanoo.com/%s?userId=%s&authKey=%s&optional=%s"),
*GameId,
*FGenericPlatformHttp::UrlEncode(UUID),
*FGenericPlatformHttp::UrlEncode(AuthKey),
*FGenericPlatformHttp::UrlEncode(OptionalBase64)
);
FPlatformProcess::LaunchURL(*Url, nullptr, nullptr);
}
Optional Parameter Examples
| Parameter | Description |
|---|---|
| GAME_SERVER | Game server (e.g., ASIA, NA, EU) |
| PLAYER_LEVEL | Player level |
| CHARACTER_CLASS | Character class/job |
| GUILD_NAME | Guild/clan name |
| LAST_STAGE | Last played stage |
| ERROR_CODE | Error code (when error occurs) |
By passing game state information along with user inquiries through optional parameters, the customer support team can identify and resolve issues more quickly.
Usage Examples
Branching Based on Login Status
void OpenHelpDesk()
{
if (bIsLoggedIn)
{
OpenHelpDeskPlayerMode();
}
else
{
OpenHelpDeskGuestMode();
}
}
Automatically Opening on Error
void OnApplicationError(const FString& ErrorMessage)
{
// Optional에 에러 정보 포함
TSharedPtr<FJsonObject> OptionalJson = MakeShareable(new FJsonObject());
OptionalJson->SetStringField(TEXT("ERROR_MESSAGE"), ErrorMessage);
OptionalJson->SetStringField(TEXT("ERROR_TIME"), FDateTime::Now().ToString());
// ... (이후 OpenHelpDeskWithOptional과 동일)
}
The Help Desk automatically detects the browser's language settings and displays in the corresponding language.
For a better user experience, we recommend using a WebView plugin instead of FPlatformProcess::LaunchURL.