From 674d89e3c69999b63356d84bdce6f3bcca86632e Mon Sep 17 00:00:00 2001 From: LimeCake Date: Sun, 19 Jul 2020 19:06:58 +0900 Subject: [PATCH] 1.1.5 release with offline support --- Assets/Scripts/Network/NetworkModule.cs | 99 +++++++++++++++++++------ Assets/Scripts/Title/AutoConnector.cs | 13 ++-- 2 files changed, 84 insertions(+), 28 deletions(-) diff --git a/Assets/Scripts/Network/NetworkModule.cs b/Assets/Scripts/Network/NetworkModule.cs index ad18145d..6d7b072f 100644 --- a/Assets/Scripts/Network/NetworkModule.cs +++ b/Assets/Scripts/Network/NetworkModule.cs @@ -78,6 +78,7 @@ internal static class OnGameInfo public class NetworkModule { private static NetworkModule INSTANCE; + public static bool IS_OFFLINE_MODE = false; public interface OnServerConnectListener { @@ -424,8 +425,16 @@ public void RequestUserLogin(string _id, string _pw) #else Debug.WriteLine("RequestUserLogin"); #endif - JObject data = new JObject {{"id", _id}, {"pw", _pw}}; - netC2SProxy.OnLoginRequest(HostID.HostID_Server, RmiContext.ReliableSend, data.ToString()); + if (IS_OFFLINE_MODE) + { + string offlineData = "{\"result\": 1,\"num\": 204,\"id\": \"235ecbadeb8e3ccac7b86a01ca09d85d23880e95\",\"nick\": \"SQUARIAN\",\"rank\": 1383,\"money\": 20000,\"cash\": 10000,\"weapon\": 0,\"skin\": 0,\"game\": -1,\"message\": \"오프라인 모드로 입장합니다!\"}"; + OnEventUserLogin(0, null, offlineData); + } + else + { + JObject data = new JObject {{"id", _id}, {"pw", _pw}}; + netC2SProxy.OnLoginRequest(HostID.HostID_Server, RmiContext.ReliableSend, data.ToString()); + } } catch (Exception e) { @@ -453,8 +462,16 @@ public void RequestUserStatus(string _id) #else Debug.WriteLine("RequestUserStatus"); #endif - JObject data = new JObject {{"id", _id}}; - netC2SProxy.OnStatusRequest(HostID.HostID_Server, RmiContext.ReliableSend, data.ToString()); + if (IS_OFFLINE_MODE) + { + string offlineData = "{\n\"result\": 1,\n\"num\": 204,\n\"id\": \"235ecbadeb8e3ccac7b86a01ca09d85d23880e95\",\n\"nick\": \"DEBUGGER\",\n\"rank\": 1383,\n\"money\": 20000,\n\"cash\": 10000,\n\"weapon\": 0,\n\"skin\": 0,\n\"game\": -1,\n\"message\": \"\"\n}"; + OnEventUserStatus(0, null, offlineData); + } + else + { + JObject data = new JObject {{"id", _id}}; + netC2SProxy.OnStatusRequest(HostID.HostID_Server, RmiContext.ReliableSend, data.ToString()); + } } catch (Exception e) { @@ -512,8 +529,17 @@ public void RequestUserSystemRank(string _id) #else Debug.WriteLine("RequestUserSystemRank"); #endif - JObject data = new JObject { { "type", "rank" }, { "id", _id } }; - netC2SProxy.OnSystemRequest(HostID.HostID_Server, RmiContext.ReliableSend, data.ToString()); + if (IS_OFFLINE_MODE) + { + //string offlineData = "{\n\"result\": 1,\n\"type\": \"rank\",\n\"data\": \"{\r\n \"global_ranking\": [\r\n {\r\n \"user_id\": \"03575f09481fb807951a37f3531a929c\",\r\n \"user_nick\": \"RAZER\",\r\n \"user_rank\": 2794,\r\n \"user_played\": 41,\r\n \"user_win\": 21,\r\n \"user_lose\": 15,\r\n \"user_kill\": 26,\r\n \"user_death\": 26,\r\n \"user_assist\": 0,\r\n \"user_damage_give\": 4750,\r\n \"user_damage_take\": 3910,\r\n \"user_character_1\": 15,\r\n \"user_character_2\": 8,\r\n \"user_character_3\": 18\r\n },\r\n {\r\n \"user_id\": \"a8f7003546104473bbbefe4fb8bc614d105545e5\",\r\n \"user_nick\": \"faedf\",\r\n \"user_rank\": 1891,\r\n \"user_played\": 246,\r\n \"user_win\": 74,\r\n \"user_lose\": 105,\r\n \"user_kill\": 79,\r\n \"user_death\": 137,\r\n \"user_assist\": 0,\r\n \"user_damage_give\": 10715,\r\n \"user_damage_take\": 17185,\r\n \"user_character_1\": 145,\r\n \"user_character_2\": 45,\r\n \"user_character_3\": 56\r\n },\r\n {\r\n \"user_id\": \"ff1b9a99c8db6c5bf37c577f2bd6cf44\",\r\n \"user_nick\": \"LIMECAKE\",\r\n \"user_rank\": 1854,\r\n \"user_played\": 23,\r\n \"user_win\": 13,\r\n \"user_lose\": 6,\r\n \"user_kill\": 59,\r\n \"user_death\": 30,\r\n \"user_assist\": 23,\r\n \"user_damage_give\": 6460,\r\n \"user_damage_take\": 5625,\r\n \"user_character_1\": 4,\r\n \"user_character_2\": 6,\r\n \"user_character_3\": 13\r\n }\r\n ],\r\n \"user_id\": \"235ecbadeb8e3ccac7b86a01ca09d85d23880e95\",\r\n \"user_nick\": \"SQUARIAN\",\r\n \"user_rank\": 1383,\r\n \"user_played\": 36,\r\n \"user_win\": 11,\r\n \"user_lose\": 19,\r\n \"user_kill\": 22,\r\n \"user_death\": 36,\r\n \"user_assist\": 3,\r\n \"user_damage_give\": 6095,\r\n \"user_damage_take\": 3335,\r\n \"user_character_1\": 18,\r\n \"user_character_2\": 12,\r\n \"user_character_3\": 5,\r\n \"user_ranking\": 6,\r\n \"winner_rank\": 1532,\r\n \"winner_nick\": \"DEB9\",\r\n \"winner_character_1\": 0,\r\n \"winner_character_2\": 0,\r\n \"winner_character_3\": 11,\r\n \"loser_rank\": 1283,\r\n \"loser_nick\": \"의현\",\r\n \"loser_character_1\": 21,\r\n \"loser_character_2\": 2,\r\n \"loser_character_3\": 2\r\n}\"\n}"; + string offlineData = "{\r\n\"result\": 1,\r\n\"type\": \"rank\",\r\n\"data\": \"{\\r\\n \\\"global_ranking\\\": [\\r\\n {\\r\\n \\\"user_id\\\": \\\"03575f09481fb807951a37f3531a929c\\\",\\r\\n \\\"user_nick\\\": \\\"RAZER\\\",\\r\\n \\\"user_rank\\\": 2794,\\r\\n \\\"user_played\\\": 41,\\r\\n \\\"user_win\\\": 21,\\r\\n \\\"user_lose\\\": 15,\\r\\n \\\"user_kill\\\": 26,\\r\\n \\\"user_death\\\": 26,\\r\\n \\\"user_assist\\\": 0,\\r\\n \\\"user_damage_give\\\": 4750,\\r\\n \\\"user_damage_take\\\": 3910,\\r\\n \\\"user_character_1\\\": 15,\\r\\n \\\"user_character_2\\\": 18,\\r\\n \\\"user_character_3\\\": 14\\r\\n },\\r\\n {\\r\\n \\\"user_id\\\": \\\"a8f7003546104473bbbefe4fb8bc614d105545e5\\\",\\r\\n \\\"user_nick\\\": \\\"NAMOO\\\",\\r\\n \\\"user_rank\\\": 1891,\\r\\n \\\"user_played\\\": 246,\\r\\n \\\"user_win\\\": 74,\\r\\n \\\"user_lose\\\": 105,\\r\\n \\\"user_kill\\\": 79,\\r\\n \\\"user_death\\\": 137,\\r\\n \\\"user_assist\\\": 0,\\r\\n \\\"user_damage_give\\\": 10715,\\r\\n \\\"user_damage_take\\\": 17185,\\r\\n \\\"user_character_1\\\": 145,\\r\\n \\\"user_character_2\\\": 45,\\r\\n \\\"user_character_3\\\": 56\\r\\n },\\r\\n {\\r\\n \\\"user_id\\\": \\\"ff1b9a99c8db6c5bf37c577f2bd6cf44\\\",\\r\\n \\\"user_nick\\\": \\\"LIMECAKE\\\",\\r\\n \\\"user_rank\\\": 1854,\\r\\n \\\"user_played\\\": 23,\\r\\n \\\"user_win\\\": 13,\\r\\n \\\"user_lose\\\": 6,\\r\\n \\\"user_kill\\\": 59,\\r\\n \\\"user_death\\\": 30,\\r\\n \\\"user_assist\\\": 23,\\r\\n \\\"user_damage_give\\\": 6460,\\r\\n \\\"user_damage_take\\\": 5625,\\r\\n \\\"user_character_1\\\": 4,\\r\\n \\\"user_character_2\\\": 6,\\r\\n \\\"user_character_3\\\": 13\\r\\n }\\r\\n ],\\r\\n \\\"user_id\\\": \\\"235ecbadeb8e3ccac7b86a01ca09d85d23880e95\\\",\\r\\n \\\"user_nick\\\": \\\"SQUARIAN\\\",\\r\\n \\\"user_rank\\\": 1383,\\r\\n \\\"user_played\\\": 44,\\r\\n \\\"user_win\\\": 23,\\r\\n \\\"user_lose\\\": 19,\\r\\n \\\"user_kill\\\": 42,\\r\\n \\\"user_death\\\": 36,\\r\\n \\\"user_assist\\\": 3,\\r\\n \\\"user_damage_give\\\": 4595,\\r\\n \\\"user_damage_take\\\": 3335,\\r\\n \\\"user_character_1\\\": 18,\\r\\n \\\"user_character_2\\\": 12,\\r\\n \\\"user_character_3\\\": 5,\\r\\n \\\"user_ranking\\\": 6,\\r\\n \\\"winner_rank\\\": 1532,\\r\\n \\\"winner_nick\\\": \\\"PANDORA\\\",\\r\\n \\\"winner_character_1\\\": 0,\\r\\n \\\"winner_character_2\\\": 0,\\r\\n \\\"winner_character_3\\\": 11,\\r\\n \\\"loser_rank\\\": 1283,\\r\\n \\\"loser_nick\\\": \\\"CUBE\\\",\\r\\n \\\"loser_character_1\\\": 21,\\r\\n \\\"loser_character_2\\\": 2,\\r\\n \\\"loser_character_3\\\": 2\\r\\n}\"\r\n}"; + OnEventSystem(0, null, offlineData); + } + else + { + JObject data = new JObject { { "type", "rank" }, { "id", _id } }; + netC2SProxy.OnSystemRequest(HostID.HostID_Server, RmiContext.ReliableSend, data.ToString()); + } } catch (Exception e) { @@ -541,8 +567,17 @@ public void RequestUserSystemMedal(int _userIndex) #else Debug.WriteLine("RequestUserSystemMedal"); #endif - JObject data = new JObject { { "type", "medal" }, { "index", _userIndex } }; - netC2SProxy.OnSystemRequest(HostID.HostID_Server, RmiContext.ReliableSend, data.ToString()); + if (IS_OFFLINE_MODE) + { + //string offlineData = "{\"result\": 1,\"type\": \"medal\",\"data\": \"{\r\n \"medal_status\": [\r\n {\r\n \"medal_type\": 1,\r\n \"medal_count\": 2\r\n },\r\n {\r\n \"medal_type\": 2,\r\n \"medal_count\": 1\r\n },\r\n {\r\n \"medal_type\": 4,\r\n \"medal_count\": 1\r\n },\r\n {\r\n \"medal_type\": 5,\r\n \"medal_count\": 18\r\n },\r\n {\r\n \"medal_type\": 7,\r\n \"medal_count\": 2\r\n },\r\n {\r\n \"medal_type\": 8,\r\n \"medal_count\": 1\r\n },\r\n {\r\n \"medal_type\": 9,\r\n \"medal_count\": 5\r\n },\r\n {\r\n \"medal_type\": 10,\r\n \"medal_count\": 1\r\n },\r\n {\r\n \"medal_type\": 11,\r\n \"medal_count\": 2\r\n },\r\n {\r\n \"medal_type\": 12,\r\n \"medal_count\": 14\r\n }\r\n ],\r\n \"user_played\": 36,\r\n \"user_win\": 11,\r\n \"user_kill\": 22,\r\n \"user_death\": 36,\r\n \"user_assist\": 3,\r\n \"user_damage_give\": 6095,\r\n \"user_damage_take\": 3335,\r\n \"user_character_1\": 18,\r\n \"user_character_2\": 12,\r\n \"user_character_3\": 5,\r\n \"user_character_1_win\": 54,\r\n \"user_character_2_win\": 7,\r\n \"user_character_3_win\": 14\r\n}\" }"; + string offlineData = "{\r\n \"result\": 1,\r\n \"type\": \"medal\",\r\n \"data\": \"{\\r\\n \\\"medal_status\\\": [\\r\\n {\\r\\n \\\"medal_type\\\": 1,\\r\\n \\\"medal_count\\\": 2\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 2,\\r\\n \\\"medal_count\\\": 1\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 4,\\r\\n \\\"medal_count\\\": 1\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 5,\\r\\n \\\"medal_count\\\": 18\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 7,\\r\\n \\\"medal_count\\\": 2\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 8,\\r\\n \\\"medal_count\\\": 1\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 9,\\r\\n \\\"medal_count\\\": 5\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 10,\\r\\n \\\"medal_count\\\": 1\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 11,\\r\\n \\\"medal_count\\\": 2\\r\\n },\\r\\n {\\r\\n \\\"medal_type\\\": 12,\\r\\n \\\"medal_count\\\": 14\\r\\n }\\r\\n ],\\r\\n \\\"user_played\\\": 36,\\r\\n \\\"user_win\\\": 11,\\r\\n \\\"user_kill\\\": 22,\\r\\n \\\"user_death\\\": 36,\\r\\n \\\"user_assist\\\": 3,\\r\\n \\\"user_damage_give\\\": 6095,\\r\\n \\\"user_damage_take\\\": 3335,\\r\\n \\\"user_character_1\\\": 18,\\r\\n \\\"user_character_2\\\": 12,\\r\\n \\\"user_character_3\\\": 5,\\r\\n \\\"user_character_1_win\\\": 54,\\r\\n \\\"user_character_2_win\\\": 7,\\r\\n \\\"user_character_3_win\\\": 14\\r\\n}\" \r\n}"; + OnEventSystem(0, null, offlineData); + } + else + { + JObject data = new JObject { { "type", "medal" }, { "index", _userIndex } }; + netC2SProxy.OnSystemRequest(HostID.HostID_Server, RmiContext.ReliableSend, data.ToString()); + } } catch (Exception e) { @@ -845,6 +880,7 @@ private static bool OnEventUserLogin(HostID remote, RmiContext rmiContext, strin #else Debug.WriteLine("OnEventUserLogin"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int result = data.GetValue("result").Value(); int user_num = data.GetValue("num").Value(); @@ -889,6 +925,7 @@ private static bool OnEventUserStatus(HostID remote, RmiContext rmiContext, stri #else Debug.WriteLine("OnEventUserStatus"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int result = data.GetValue("result").Value(); int user_num = data.GetValue("num").Value(); @@ -933,6 +970,7 @@ private static bool OnEventSystem(HostID remote, RmiContext rmiContext, string _ #else Debug.WriteLine("OnEventSystem"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int result = data.GetValue("result").Value(); string type = data.GetValue("type").Value(); @@ -980,6 +1018,7 @@ private static bool OnEventGameQueue(HostID remote, RmiContext rmiContext, strin #else Debug.WriteLine("OnEventGameQueue"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int result = data.GetValue("result").Value(); int room = data.GetValue("room").Value(); @@ -1014,6 +1053,7 @@ private static bool OnEventGameInfo(HostID remote, RmiContext rmiContext, string #else Debug.WriteLine("OnEventGameInfo"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int result = data.GetValue("result").Value(); int room = data.GetValue("room").Value(); @@ -1062,6 +1102,7 @@ private static bool OnEventGameStatusCountdown(HostID remote, RmiContext rmiCont #else Debug.WriteLine("OnEventGameStatusCountdown"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int count = data.GetValue("count").Value(); if (onGameStatusListeners != null && onGameStatusListeners.Count > 0) @@ -1094,6 +1135,7 @@ private static bool OnEventGameStatusTime(HostID remote, RmiContext rmiContext, #else Debug.WriteLine("OnEventGameStatusTime"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int time = data.GetValue("time").Value(); if (onGameStatusListeners != null && onGameStatusListeners.Count > 0) @@ -1127,6 +1169,7 @@ private static bool OnEventGameStatusReady(HostID remote, RmiContext rmiContext, #else Debug.WriteLine("OnEventGameStatusReady"); #endif + Debug.Log("Requested Network data : \n" + _data); if (onGameStatusListeners != null && onGameStatusListeners.Count > 0) { foreach (OnGameStatusListener listener in onGameStatusListeners) @@ -1157,6 +1200,7 @@ private static bool OnEventGameStatusScore(HostID remote, RmiContext rmiContext, #else Debug.WriteLine("OnEventGameStatusScore"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int blueKill = data.GetValue("blueKill").Value(); int blueDeath = data.GetValue("blueDeath").Value(); @@ -1194,6 +1238,7 @@ private static bool OnEventGameStatusMessage(HostID remote, RmiContext rmiContex #else Debug.WriteLine("OnEventGameStatus"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int type = data.GetValue("type").Value(); string message = data.GetValue("message").ToString(); @@ -1227,6 +1272,7 @@ private static bool OnEventGameEventHealth(HostID remote, RmiContext rmiContext, #else Debug.WriteLine("OnEventGameEventHealth"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int num = data.GetValue("num").Value(); int health = data.GetValue("health").Value(); @@ -1260,6 +1306,7 @@ private static bool OnEventGameEventDamage(HostID remote, RmiContext rmiContext, #else Debug.WriteLine("OnEventGameEventDamage"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int from = data.GetValue("from").Value(); int to = data.GetValue("to").Value(); @@ -1295,6 +1342,7 @@ private static bool OnEventGameEventObject(HostID remote, RmiContext rmiContext, #else Debug.WriteLine("OnEventGameEventObject"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int num = data.GetValue("num").Value(); int health = data.GetValue("health").Value(); @@ -1328,6 +1376,7 @@ private static bool OnEventGameEventItem(HostID remote, RmiContext rmiContext, s #else Debug.WriteLine("OnEventGameEventItem"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int type = data.GetValue("type").Value(); int num = data.GetValue("num").Value(); @@ -1362,6 +1411,7 @@ private static bool OnEventGameEventKill(HostID remote, RmiContext rmiContext, s #else Debug.WriteLine("OnEventGameEventKill"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int from = data.GetValue("from").Value(); int to = data.GetValue("to").Value(); @@ -1396,6 +1446,7 @@ private static bool OnEventGameEventRespawn(HostID remote, RmiContext rmiContext #else Debug.WriteLine("OnEventGameEventRespawn"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); int num = data.GetValue("num").Value(); int time = data.GetValue("time").Value(); @@ -1429,6 +1480,7 @@ private static bool OnEventGameResult(HostID remote, RmiContext rmiContext, stri #else Debug.WriteLine("OnEventGameResult"); #endif + Debug.Log("Requested Network data : \n" + _data); JObject data = JObject.Parse(_data); string resultData = data.GetValue("resultData").ToString(); if (onGameResultListeners != null && onGameResultListeners.Count > 0) @@ -1452,22 +1504,23 @@ private static bool OnEventGameResult(HostID remote, RmiContext rmiContext, stri return true; } - private static bool OnEventGameUserMove(HostID remote, RmiContext rmiContext, string data) + private static bool OnEventGameUserMove(HostID remote, RmiContext rmiContext, string _data) { try { +#if (!NOUNITY) + Debug.Log("OnEventGameUserMove"); +#else + Debug.WriteLine("OnEventGameUserMove"); +#endif + Debug.Log("Requested Network data : \n" + _data); if (onGameUserMoveListeners != null && onGameUserMoveListeners.Count > 0) { foreach (OnGameUserMoveListener listener in onGameUserMoveListeners) { - listener?.OnGameUserMove(data); + listener?.OnGameUserMove(_data); } } -#if (!NOUNITY) - Debug.Log("OnEventGameUserMove"); -#else - Debug.WriteLine("OnEventGameUserMove"); -#endif } catch (Exception e) { @@ -1482,22 +1535,24 @@ private static bool OnEventGameUserMove(HostID remote, RmiContext rmiContext, st return true; } - private static bool OnEventGameUserSync(HostID remote, RmiContext rmiContext, string data) + private static bool OnEventGameUserSync(HostID remote, RmiContext rmiContext, string _data) { try { +#if (!NOUNITY) + Debug.Log("OnEventGameUserSync"); +#else + Debug.WriteLine("OnEventGameUserSync"); +#endif + Debug.Log("Requested Network data : \n" + _data); if (onGameUserSyncListeners != null && onGameUserSyncListeners.Count > 0) { foreach (OnGameUserSyncListener listener in onGameUserSyncListeners) { - listener?.OnGameUserSync(data); + listener?.OnGameUserSync(_data); } } -#if (!NOUNITY) - Debug.Log("OnEventGameUserSync"); -#else - Debug.WriteLine("OnEventGameUserSync"); -#endif + } catch (Exception e) { diff --git a/Assets/Scripts/Title/AutoConnector.cs b/Assets/Scripts/Title/AutoConnector.cs index b871f844..c2156ce2 100644 --- a/Assets/Scripts/Title/AutoConnector.cs +++ b/Assets/Scripts/Title/AutoConnector.cs @@ -89,10 +89,8 @@ public static void OnConnectResult(bool result, string msg) SERVER_CONNECTED = false; instance.AutoConnectorText.GetComponent().text = "서버 연결 실패"; AUTO_FAILED = true; - try - { - NetworkModule.GetInstance().Disconnect(); - } catch (Exception) { } + NetworkModule.IS_OFFLINE_MODE = true; + attemptLogin(); } } @@ -126,6 +124,8 @@ public void startConnector() catch (Exception e) { AutoConnectorText.GetComponent().text = "서버 연결 실패"; + NetworkModule.IS_OFFLINE_MODE = true; + attemptLogin(); return; } } @@ -144,7 +144,7 @@ public void createRandomAccount() playerPW = playerID; } - public void attemptLogin() + public static void attemptLogin() { //AutoConnectorText.GetComponent().text = "로그인 중입니다"; if (string.IsNullOrEmpty(playerID) && string.IsNullOrEmpty(playerPW)) @@ -161,7 +161,7 @@ public void attemptLogin() playerPW = envArguments[3]; } } - networkModule.RequestUserLogin(playerID, playerPW); + NetworkModule.GetInstance().RequestUserLogin(playerID, playerPW); } public static void loginResult(bool _result, UserData _user, int _game, string _message) @@ -189,6 +189,7 @@ public static void loginResult(bool _result, UserData _user, int _game, string _ } instance.AutoConnectorText.GetComponent().text = LocalUser.Instance.localUserData.userNick + "님, 환영합니다!"; + if (LocalUser.Instance.localUserData.userNick.Equals("SQUARIAN")) instance.AutoConnectorText.GetComponent().text = "오프라인 모드로 입장합니다"; instance.StartCoroutine(switchLobbyScene()); } else {