lasttime 및 Get_ServerTime 제거
This commit is contained in:
parent
4628cc1786
commit
1c55295857
|
|
@ -267,6 +267,8 @@ function Get_JsonUserData()
|
|||
}
|
||||
function Set_JsonUserData(urod)
|
||||
{
|
||||
urod.LastTime = Get_CurKoreaTime();
|
||||
log.info(urod.LastTime);
|
||||
server.UpdateUserReadOnlyData({ PlayFabId: currentPlayerId, Permission: "Public", Data: {"UserInfo": JSON.stringify(urod)} });
|
||||
}
|
||||
function Get_Return(errorval, add) {
|
||||
|
|
@ -283,7 +285,7 @@ function Get_Return(errorval, add) {
|
|||
}
|
||||
}
|
||||
|
||||
log.info(rtn.error + ", " + rtn.time);
|
||||
//log.info(rtn.error + ", " + rtn.time);
|
||||
return rtn;
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -188,7 +188,7 @@ public partial class ServerData
|
|||
{ // 서버로 보내는 저장 데이터
|
||||
ServerData_Read temp = new ServerData_Read();
|
||||
|
||||
temp.LastTime = LastTime.ToString("yyyyMMddHHmmss");
|
||||
//temp.LastTime = LastTime.ToString("yyyyMMddHHmmss"); // 서버에서 함
|
||||
temp.MapData = new Dictionary<string, Dictionary<string, SD_MapData_Read>>();
|
||||
foreach (var item in MapData)
|
||||
{
|
||||
|
|
@ -255,7 +255,7 @@ public partial class ServerData
|
|||
[Serializable]
|
||||
public class ServerData_Read
|
||||
{
|
||||
public string LastTime;
|
||||
public DateTime LastTime;
|
||||
public Dictionary<string, Dictionary<string, SD_MapData_Read>> MapData = new Dictionary<string, Dictionary<string, SD_MapData_Read>>();
|
||||
public SD_Buff_Read Buff;
|
||||
public SD_Equip_Read Equip;
|
||||
|
|
@ -288,7 +288,7 @@ public class ServerData_Read
|
|||
{ // 서버 데이터 로드
|
||||
ServerData temp = new ServerData();
|
||||
temp.IsEnemy = _isEnemy;
|
||||
temp.LastTime = DateTime.ParseExact(LastTime, "yyyyMMddHHmmss", new System.Globalization.CultureInfo("en-US"));
|
||||
temp.LastTime = LastTime;
|
||||
temp.MapData = new Dictionary<string, Dictionary<string, SD_MapData>>();
|
||||
foreach (var item in MapData)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ public class ServerInfo : MyCoroutine
|
|||
if (m_serverTimeRefresh > 300f) // 5분
|
||||
{
|
||||
m_serverTimeRefresh = 0f;
|
||||
Get_ServerTime(null);
|
||||
//Get_ServerTime(null); // TODO 정인호 : 시간 동기화
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -221,7 +221,7 @@ public class ServerInfo : MyCoroutine
|
|||
m_LoginInfo = loginresult;
|
||||
if (m_LoginInfo.InfoResultPayload != null && m_LoginInfo.InfoResultPayload.PlayerProfile != null)
|
||||
UserName = m_LoginInfo.InfoResultPayload.PlayerProfile.DisplayName;
|
||||
ServerSave_LoginToken(() => { Get_ServerTime(_servercomplete); }, _fail);
|
||||
ServerSave_LoginToken(() => { Get_TitleData(_servercomplete); }, _fail);
|
||||
},
|
||||
error =>
|
||||
{
|
||||
|
|
@ -230,22 +230,23 @@ public class ServerInfo : MyCoroutine
|
|||
});
|
||||
}
|
||||
|
||||
public void Get_ServerTime(Action<bool> _servercomplete)
|
||||
{
|
||||
PlayFabClientAPI.GetTime(new GetTimeRequest(),
|
||||
success =>
|
||||
{
|
||||
ServerTime = success.Time.AddHours(MyValue.UTC);
|
||||
ServerTimeUpdate = true;
|
||||
if (_servercomplete != null)
|
||||
Get_TitleData(_servercomplete);
|
||||
},
|
||||
fail =>
|
||||
{
|
||||
Get_ServerTime(_servercomplete);
|
||||
Debug.Log("서버 시간 받아오기 실패 : " + fail.ErrorMessage);
|
||||
});
|
||||
}
|
||||
// 서버에서 전달
|
||||
//public void Get_ServerTime(Action<bool> _servercomplete)
|
||||
//{
|
||||
// PlayFabClientAPI.GetTime(new GetTimeRequest(),
|
||||
// success =>
|
||||
// {
|
||||
// ServerTime = success.Time.AddHours(MyValue.UTC);
|
||||
// ServerTimeUpdate = true;
|
||||
// if (_servercomplete != null)
|
||||
// Get_TitleData(_servercomplete);
|
||||
// },
|
||||
// fail =>
|
||||
// {
|
||||
// Get_ServerTime(_servercomplete);
|
||||
// Debug.Log("서버 시간 받아오기 실패 : " + fail.ErrorMessage);
|
||||
// });
|
||||
//}
|
||||
|
||||
void Get_TitleData(Action<bool> _servercomplete)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue