feat: 뒤끝 서버 연결 테스트 및 에셋 추가
This commit is contained in:
31
Gameton-06/Assets/Gameton/Scripts/Common/BackendManager.cs
Normal file
31
Gameton-06/Assets/Gameton/Scripts/Common/BackendManager.cs
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
// 뒤끝 SDK namespace 추가
|
||||||
|
using BackEnd;
|
||||||
|
|
||||||
|
namespace TON
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 랭킹 데이터 관리를 위한 뒤끝 서버 매니저
|
||||||
|
/// </summary>
|
||||||
|
public class BackendManager : MonoBehaviour
|
||||||
|
{
|
||||||
|
void Start()
|
||||||
|
{
|
||||||
|
var bro = Backend.Initialize(); // 뒤끝 초기화
|
||||||
|
|
||||||
|
// 뒤끝 초기화에 대한 응답값
|
||||||
|
if (bro.IsSuccess())
|
||||||
|
{
|
||||||
|
Debug.Log("초기화 성공 : " + bro); // 성공일 경우 statusCode 204 Success
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.LogError("초기화 실패 : " + bro); // 실패일 경우 statusCode 400대 에러 발생
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 997aacd350268d041bba7f34cf767394
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Gameton-06/Assets/TheBackend.meta
Normal file
8
Gameton-06/Assets/TheBackend.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: a7a10178843a13a499e865edc4480d42
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Gameton-06/Assets/TheBackend/Plugins.meta
Normal file
8
Gameton-06/Assets/TheBackend/Plugins.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b5cdcec3ee32c5045841d598540aae91
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Gameton-06/Assets/TheBackend/Plugins/Android.meta
Normal file
8
Gameton-06/Assets/TheBackend/Plugins/Android.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: bde01bc416932a2478cd660e19a744b9
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/Android/Backend.aar
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/Android/Backend.aar
Normal file
Binary file not shown.
@@ -0,0 +1,32 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 53bbc4cf3e51b014bb5f4cf116cbca91
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
Android: Android
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/Backend.dll
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/Backend.dll
LFS
Normal file
Binary file not shown.
33
Gameton-06/Assets/TheBackend/Plugins/Backend.dll.meta
Normal file
33
Gameton-06/Assets/TheBackend/Plugins/Backend.dll.meta
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5236b6994bfbd7e4799c095f2e85a2c2
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
- first:
|
||||||
|
Windows Store Apps: WindowsStoreApps
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Gameton-06/Assets/TheBackend/Plugins/Editor.meta
Normal file
8
Gameton-06/Assets/TheBackend/Plugins/Editor.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 7e72a29c073fd224b92d1162440cdeb1
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/Editor/TheBackendMultiSettingEditor.dll
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/Editor/TheBackendMultiSettingEditor.dll
LFS
Normal file
Binary file not shown.
@@ -0,0 +1,33 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 34bdab53604471144853f229a2a8a4a4
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings:
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
- first:
|
||||||
|
Windows Store Apps: WindowsStoreApps
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/Editor/TheBackendSettingEditor.dll
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/Editor/TheBackendSettingEditor.dll
LFS
Normal file
Binary file not shown.
@@ -0,0 +1,33 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 8eb7725abfacf504d9b015c58c95420a
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings:
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
- first:
|
||||||
|
Windows Store Apps: WindowsStoreApps
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/LitJSON.dll
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/LitJSON.dll
LFS
Normal file
Binary file not shown.
33
Gameton-06/Assets/TheBackend/Plugins/LitJSON.dll.meta
Normal file
33
Gameton-06/Assets/TheBackend/Plugins/LitJSON.dll.meta
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 881a7d2468927f944b4a556d3bcf64ad
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
- first:
|
||||||
|
Windows Store Apps: WindowsStoreApps
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Gameton-06/Assets/TheBackend/Plugins/Settings.meta
Normal file
8
Gameton-06/Assets/TheBackend/Plugins/Settings.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 049d8146771287b4492c2d0ecf3e132e
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/Settings/TheBackendHashKeySettings.dll
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/Settings/TheBackendHashKeySettings.dll
LFS
Normal file
Binary file not shown.
@@ -0,0 +1,116 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 4ced5682f94d6c94989bd8d365f15037
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
'': Any
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
Exclude Android: 1
|
||||||
|
Exclude Editor: 0
|
||||||
|
Exclude Linux: 1
|
||||||
|
Exclude Linux64: 1
|
||||||
|
Exclude LinuxUniversal: 1
|
||||||
|
Exclude OSXUniversal: 1
|
||||||
|
Exclude Win: 1
|
||||||
|
Exclude Win64: 1
|
||||||
|
Exclude WindowsStoreApps: 1
|
||||||
|
Exclude iOS: 1
|
||||||
|
- first:
|
||||||
|
Android: Android
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: ARMv7
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
OS: AnyOS
|
||||||
|
- first:
|
||||||
|
Facebook: Win
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
- first:
|
||||||
|
Facebook: Win64
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
- first:
|
||||||
|
Standalone: Linux
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: x86
|
||||||
|
- first:
|
||||||
|
Standalone: Linux64
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: x86_64
|
||||||
|
- first:
|
||||||
|
Standalone: LinuxUniversal
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: None
|
||||||
|
- first:
|
||||||
|
Standalone: OSXUniversal
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
- first:
|
||||||
|
Standalone: Win
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
- first:
|
||||||
|
Standalone: Win64
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
- first:
|
||||||
|
Windows Store Apps: WindowsStoreApps
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
DontProcess: false
|
||||||
|
PlaceholderPath:
|
||||||
|
SDK: AnySDK
|
||||||
|
ScriptingBackend: AnyScriptingBackend
|
||||||
|
- first:
|
||||||
|
iPhone: iOS
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
AddToEmbeddedBinaries: false
|
||||||
|
CompileFlags:
|
||||||
|
FrameworkDependencies:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/Settings/TheBackendMultiSettings.dll
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/Settings/TheBackendMultiSettings.dll
LFS
Normal file
Binary file not shown.
@@ -0,0 +1,33 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: cd59f86991e115e4fb5b2ee874c89e25
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
- first:
|
||||||
|
Windows Store Apps: WindowsStoreApps
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/Settings/TheBackendSettings.dll
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/Settings/TheBackendSettings.dll
LFS
Normal file
Binary file not shown.
@@ -0,0 +1,33 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f624596d5fe1bd5459a5da424a8abc1b
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
- first:
|
||||||
|
Windows Store Apps: WindowsStoreApps
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Plugins/WebSocket4Net.dll
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Plugins/WebSocket4Net.dll
LFS
Normal file
Binary file not shown.
33
Gameton-06/Assets/TheBackend/Plugins/WebSocket4Net.dll.meta
Normal file
33
Gameton-06/Assets/TheBackend/Plugins/WebSocket4Net.dll.meta
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 56470701fb6855e4e910733ec1bb6e56
|
||||||
|
PluginImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
iconMap: {}
|
||||||
|
executionOrder: {}
|
||||||
|
defineConstraints: []
|
||||||
|
isPreloaded: 0
|
||||||
|
isOverridable: 0
|
||||||
|
isExplicitlyReferenced: 0
|
||||||
|
validateReferences: 1
|
||||||
|
platformData:
|
||||||
|
- first:
|
||||||
|
Any:
|
||||||
|
second:
|
||||||
|
enabled: 1
|
||||||
|
settings: {}
|
||||||
|
- first:
|
||||||
|
Editor: Editor
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
DefaultValueInitialized: true
|
||||||
|
- first:
|
||||||
|
Windows Store Apps: WindowsStoreApps
|
||||||
|
second:
|
||||||
|
enabled: 0
|
||||||
|
settings:
|
||||||
|
CPU: AnyCPU
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Gameton-06/Assets/TheBackend/Resources.meta
Normal file
8
Gameton-06/Assets/TheBackend/Resources.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: da4c3a5327f1b3a4b87dbcb6179db2a7
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Gameton-06/Assets/TheBackend/Resources/TheBackendSettings.asset
LFS
Normal file
BIN
Gameton-06/Assets/TheBackend/Resources/TheBackendSettings.asset
LFS
Normal file
Binary file not shown.
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f2ddab498f026c74f9f2e174428402f0
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Gameton-06/Assets/TheBackend/Toolkit.meta
Normal file
8
Gameton-06/Assets/TheBackend/Toolkit.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 6fd5effa45be36449bcb185854f2e5d5
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
67
Gameton-06/Assets/TheBackend/Toolkit/SendQueueMgr.cs
Normal file
67
Gameton-06/Assets/TheBackend/Toolkit/SendQueueMgr.cs
Normal file
@@ -0,0 +1,67 @@
|
|||||||
|
using System;
|
||||||
|
using UnityEngine;
|
||||||
|
using BackEnd;
|
||||||
|
|
||||||
|
// SendQueue를 손쉽게 사용하기 위한 SendQueueMgr 클래스 입니다.
|
||||||
|
// 해당 스크립트를 유니티 객체에 스크롤 해서 적용해주세요.
|
||||||
|
// SendQueue에 대한 자세한 설명은 아래 개발자 문서를 참고해주세요.
|
||||||
|
// https://developer.thebackend.io/unity3d/guide/Async/SendQueue/
|
||||||
|
|
||||||
|
public class SendQueueMgr : MonoBehaviour
|
||||||
|
{
|
||||||
|
void Awake()
|
||||||
|
{
|
||||||
|
// 씬이 바뀌어도 계속 SendQueue를 사용하기 위해서
|
||||||
|
// 아래 DontDestroyOnLoad 함수를 통해 SendQueue 객체를 파괴되지 않는 오브젝트로 만듭니다.
|
||||||
|
// 자세한 설명은 아래 유니티 개발자문서를 참고해주세요.
|
||||||
|
// https://docs.unity3d.com/kr/current/ScriptReference/Object.DontDestroyOnLoad.html
|
||||||
|
DontDestroyOnLoad(this);
|
||||||
|
|
||||||
|
// 만약 SendQueue가 초기화 되지 않았다면 초기화 수행
|
||||||
|
if (SendQueue.IsInitialize == false)
|
||||||
|
{
|
||||||
|
// SendQueue는 시작과 동시에 초기화가 수행됩니다.
|
||||||
|
// 디버그 로그 활성화, 예외 이벤트 핸들러 등록
|
||||||
|
SendQueue.StartSendQueue(true, ExceptionEvent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void Update()
|
||||||
|
{
|
||||||
|
// SendQueue가 초기화 되었을 때만 Poll 함수를 호출
|
||||||
|
if (SendQueue.IsInitialize)
|
||||||
|
{
|
||||||
|
// SendQueue를 정상적으로 사용하기 위해서는
|
||||||
|
// 아래 Poll 함수가 반드시 정기적으로 호출되어야 합니다.
|
||||||
|
BackEnd.SendQueue.Poll();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// SendQueue 내부에서 예외가 발생했을 경우
|
||||||
|
// 아래 이벤트 핸들러를 통해 예외 이벤트가 전달됩니다.
|
||||||
|
void ExceptionEvent(Exception e)
|
||||||
|
{
|
||||||
|
Debug.Log(e.ToString());
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void OnApplicationPause(bool isPause)
|
||||||
|
{
|
||||||
|
if (isPause == false)
|
||||||
|
{
|
||||||
|
// 어플리케이션이 재실행 되었을 때 SendQueue를 재실행 시킴
|
||||||
|
SendQueue.ResumeSendQueue();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// 어플리케이션이 정지되었을 때 SendQueue를 일시 정지 시킴
|
||||||
|
SendQueue.PauseSendQueue();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void OnApplicationQuit()
|
||||||
|
{
|
||||||
|
// 어플리케이션이 종료되었을 때 SendQueue를 정지 시킴
|
||||||
|
BackEnd.SendQueue.StopSendQueue();
|
||||||
|
}
|
||||||
|
}
|
||||||
11
Gameton-06/Assets/TheBackend/Toolkit/SendQueueMgr.cs.meta
Normal file
11
Gameton-06/Assets/TheBackend/Toolkit/SendQueueMgr.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 7140c56c72cb4b44ba191242cb642c85
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
Reference in New Issue
Block a user