버전 비교

  • 이 줄이 추가되었습니다.
  • 이 줄이 삭제되었습니다.
  • 서식이 변경되었습니다.
목차
stylenone

1. Installation and Runtime Environment

  • Minimum Version

    • Unity 2021.3.37f1 or later

  • Recommended Version

    • Unity 2022.3.21f1 or later

참고사항

If you do not use the recommended version, you may encounter the following issues:

  • The app may crash upon execution with the message "USING MEMORY ADDRESSES FROM MORE THAN 16GB OF MEMORY." (Related Issues)

  • In version 2018.x, there is a bug that causes a black screen to appear when building for Android 12 or higher.

  • As gradle uses 6.7.1, certain Unity versions may require an upgrade.

2. SDK File Structure

The provided KakaoGamesSDK_Unity_[버전].zip file consists of the following files

File

Description

KakaoGamesSDK.unitypackage

  • The distributed unitypackage file.

  • Dependencies are included.

com.kakaogames.sdk-[버전].tgz

  • The distributed tgz file.

  • Dependencies are not included.

    • Download Google packages for Unity Adds dependencies.

    • You need to download and install EDM, FirebaseApp, and FirebaseCrashlytics tgz files in order, or install FirebaseCrashlytics.unitypackage.

SampleApp.zip

  • Sample project.

ApiReference.zip

  • API reference documentation for KakaoGames Unity SDK.

3. SDK Installation

3.1. Installing via unitypackage

First, open the game project in Unity.
Run the KakaoGamesSDK.unitypackage file, and a menu will appear in Unity allowing you to import it. Proceed with the import with all items checked.

참고사항

When building on macOS, you may encounter a warning like below:

...

Click ? > Click Open Privacy & Security Settings > Click Allow Anyway, then

...

click Open.

...

3.1.1 Installing Newtonsoft.Json Package

As the SDK uses Newtonsoft.Json, this package must be installed.

Open Packages/manifest.json in your project’s root directory and add "com.unity.nuget.newtonsoft-json": "3.0.2".

코드 블럭
languagejson
{
  "dependencies": {
    //...
    "com.unity.nuget.newtonsoft-json": "3.0.2"
    }
}
참고사항

If not added, the following error will occur, and the build will fail.

...

정보

If installed via Package Manager, it will be installed automatically.

3.2. Installing via Package Manager (tgz file)

  1. Open the Package Manager via the "Window" menu.

    Image Added
  2. Install the dependencies via Add Package from tarball…

    Image Added
  3. Install in the following order: EDM, Firebase App, Firebase Crashlytics.

    Image Added
  4. Similarly, install using the file com.kakaogames.sdk-<버전>.tgz package.

    Image AddedImage Added

4. Kakao Game SDK Configuration

4.1. Opening the Kakao Game SDK Configuration Inspector

  1. SOnce the SDK installation is complete, you’ll see a new menu in Unity: KakaoGames/Configure SDK.

    Image Added

    Clicking on it will take you to KGTConfiguration.asset. Alternatively, you can directly check the Assets/KakaoGames/KGTConfiguration.asset file's Inspector.

    Image Added
  2. You can configure the properties to be used in Kakao Games through the KGTConfiguration.asset Inspector.

    Image Added

4.2. Common Settings

4.2.1. Basic Settings

  • First, configure the basic settings for Kakao Games. Be sure to check the descriptions for each setting.

Kakao Games SDK Basic Settings

Key

Type

Required

Description

Example

App Id

String

O

Can be found in one of the two following locations.
Kakao Developers Page > My Applications > Select App > App Settings > Summary Information
KakaoGames Admin > Game Build > Client Version Management

909428

App Secret

String

O

Same as the native app key found in the Kakao Developers Page > My Applications > Select App > App Settings > Summary Information.

c3c38bbfa3828b342d946e9770c974d0

Log Level

Enum

O

Sets the SDK log output level. You can choose from "Verbose," "Debug," "Error," or "None."

None

  • Enter the Kakao Games basic settings as shown in the image below.

    • Image Added
  • After configuring, click the "Test Configuration" button.

  • If configured correctly

    • Image Added
  • If configured incorrectly

    • Image Added

4.3. Android Settings

4.3.1. Custom Build File Settings

Navigate to Player → Publishing Settings → Build to configure the custom files.

The following custom build files are mandatory for the SDK:

 

2021.3

2022.3

Required Items

 

스크린샷 2024-04-25 오후 4.20.09.pngImage Added

 

 

스크린샷 2024-04-25 오후 4.19.22.pngImage Added

 

AndroidManifest.xml

Automatically generated by the SDK's internal logic.

Automatically generated by the SDK's internal logic.

mainTemplate.gradle

Must be checked, and necessary dependencies are automatically configured by EDM.

Android dependencies are set up through the External Dependency Manager.

Must be checked, and necessary dependencies are automatically configured by EDM.

Android dependencies are set up through the External Dependency Manager.

launcherTemplate.gradle

Add the following lines to the automatically generated file:

코드 블럭
apply plugin: 'com.google.firebase.firebase-perf'
apply plugin: 'com.google.firebase.crashlytics'

Add the following lines to the automatically generated file:

코드 블럭
apply plugin: 'com.google.firebase.firebase-perf'
apply plugin: 'com.google.firebase.crashlytics'

baseProjectTemplate.gradle

Add the following lines to the automatically generated file:

코드 블럭
classpath 'com.google.gms:google-services:4.3.3'
classpath 'com.google.firebase:perf-plugin:1.2.0'
classpath 'com.google.firebase:firebase-crashlytics-gradle:2.2.0'

Add the following lines to the automatically generated file:

코드 블럭
// Make sure that you have the Google services Gradle plugin dependency
id 'com.google.gms.google-services' version "4.3.15" apply false
// Add the dependency for the Performance Monitoring Gradle plugin
id 'com.google.firebase.firebase-perf' version "1.4.2" apply false
// Add the dependency for the Crashlytics Gradle plugin
id 'com.google.firebase.crashlytics' version "2.9.8" apply false

gradleTemplate.properties

Use the file automatically generated by Unity and EDM.

Use the file automatically generated by Unity and EDM.

settingTemplate.gradle

File doesn't exist in version 2021.3.

Use the automatically generated file.

4.3.2. Permission Settings

You can add the permissions needed by the game in the Assets/Plugins/Android/AndroidManifest.xml file.

코드 블럭
<uses-permission android:name="android.permission.XXXXXX" />

4.3.3. Setting google-services.json

  1. Download the google-services.json file that matches the game's settings.

  2. Place the downloaded file under the Assets/Plugins/Android folder.

  3. Firebase sdk will automatically generate google-services.xml or google-services-desktop.json.

    Image Added
  4. If not using firebase sdk isn’t installed, download generate_xml_from_google_services_json.exe and generate_xml_from_google_services_json.py from https://github.com/firebase/firebase-cpp-sdk and add them to the project. Or manually create google-services.xml or google-services-desktop.json.

코드 블럭
  "generate_xml_from_google_services_json.exe" -i "{original google-services.json path}" -o "{Project Path}/Assets/Plugins/Android/KakaoGameSDK.androidlib/res/values/google-services.xml" -p "{package name}"

4.4. iOS Settings

4.4.1. Setting Minimum Supported Version

  1. In Unity3D, go to "File" -> "Build Settings...". 

  2. Set the platform to iOS in the "Build Settings" window, then click "Player Settings...

    Image Added
  3. The minimum supported iOS version for the KakaoGames SDK is iOS 13.0.

  4. Image Added

    Click the Build button to build, which will generate an Xcode project upon success.

4.4.2. Multi-App Login Settings

If the game uses multi-app login, check the "Kakao MultiApp Login" checkbox in the Inspector before building.

...

정보

Important: For games that will only use a single app, leave this checkbox unchecked. (If enabled, it may cause issues with the redirect URI settings, so it should remain unchecked for apps that do not require multi-app login.)

4.4.3. Native SDK Dependency Configuration

You can remove or add dependencies as needed in the Kakaogames/Edtior/KakaoGamesDependencies.xml file.
Modify the iosPods section by removing or adding iosPod entries as required.

정보

The core module must always be configured.

For example, if you only want to use the Kakao module,

코드 블럭
<?xml version="1.0" encoding="utf-8"?>
<dependencies>
    <androidPackages>
        ...
    </androidPackages>
    <iosPods>
        <!-- kakaogames Core Module -->
        <iosPod name="KakaoGameTubeSDK/KakaoGame" version="4.0.0" />
        
        <!-- kakaogames Kakao Module -->
        <iosPod name="KakaoGameTubeSDK/KakaoGameKakao" version="4.0.0" />
    </iosPods>
</dependencies>

You can configure it as shown.

4.4.4. iOS App Localization Settings

This section covers the steps to configure localization.

For example, we'll set up localization for the "User Tracking Usage Description.”

  1. Install Localization.

    스크린샷 2024-06-26 오후 5.30.21.pngImage Added
  2. Go to Project Settings - Localization and click Create.

    스크린샷 2024-06-26 오후 5.31.54.pngImage Added
  3. Click the Locale Generator and select the desired countries.

    스크린샷 2024-06-26 오후 5.36.18.pngImage Added스크린샷 2024-06-26 오후 5.38.20.pngImage Added
  4. In MetaData, click on iOS-App Info.

    스크린샷 2024-06-26 오후 5.39.14.pngImage Added
  5. Set the default country. In this example, we’ll use “en.”

    스크린샷 2024-06-26 오후 5.42.36.pngImage Added
  6. Open the "Localization Table" window from Window > Asset Management > Localization Scene Controls and create a table named 'App Data'.

    스크린샷 2024-06-26 오후 6.26.04.pngImage Added
  7. In Edit Table Collection configure the multilingual setting.

    스크린샷 2024-06-26 오후 6.25.38.pngImage Added
  8. Finally, add the table to the User Tracking Usage Description.

    스크린샷 2024-06-26 오후 6.26.56.pngImage Added
  9. If set up correctly, the app will apply the localization.

KakaoTalk_Photo_2024-06-26-19-14-31 002.jpegImage AddedKakaoTalk_Photo_2024-06-26-19-14-31 001.jpegImage Added

4.5. IDP Settings

4.5.1. Kakao Information Settings

If your game uses Kakao authentication, configure the settings accordingly.

  1. Click the Kakao checkbox if using Kakao authentication.

  2. Set the App Key if using the Windows SDK.

    Image Added

4.5.2. Sign in with Apple Information Settings

If your game uses Sign in with Apple, configure the settings accordingly.

  1. Click the SignInWithApple checkbox if using Sign in with Apple.

  2. Enter the ClientId issued by the Apple Admin.

    Image Added

Additional Sign in with Apple settings may be required depending on your Unity version.

경고

https://docs.unity3d.com/2018.4/Documentation/ScriptReference/iOS.Xcode.PBXCapabilityType.SignInWithApple.html
If your Unity version does not support this API, a build error may occur.

4.6. Notes for Using Unity SDK

4.6.1. Reference When Using PlayerPref Class

  1. The iOS/Android Native SDK has internal logic that stores necessary values in the app data.

  2. If the developer calls PlayerPref deleteAll to clean up game data, the SDK may malfunction because it deletes data that the SDK requires.

  3. To avoid this, the developer should organize the keys/values used and implement the cleanup using the deleteKey API (not deleteAll), ensuring only the game data saved by the game itself is deleted.