zhangjiannan 2025-05-22 14:51:06 +08:00
parent b4fad0727d
commit fa1ace99e5
2 changed files with 7 additions and 3 deletions

View File

@ -32,7 +32,8 @@ SDKSubMitType = {
TYPE_CHANGENAME = 10,
TYPE_TUTORIAL_COMPLETED = 11,
TYPE_SELF_LV = 12,
TYPE_PURCHE = 13
TYPE_PURCHE = 13,
TYPE_FIRST_ENTER_GAME = 14
}
SDK_RESULT = {

View File

@ -292,7 +292,9 @@ end
--秒转换成文字对应时间
function GetTimeStrBySeconds(_seconds)
return os.date(GetLanguageStrById(10779), _seconds)
-- 计算时区偏移UTC+4 即东4区偏移量为14400秒
local utc_offset = 43200
return os.date(GetLanguageStrById(10779), _seconds - utc_offset)
end
--秒转换成文字对应时间 只有分秒
@ -1491,7 +1493,8 @@ function TimeToYMDHMS(t)
if not t or t < 0 then
return 0
end
return os.date(GetLanguageStrById(1013022), t)
local utc_offset = 43200
return os.date(GetLanguageStrById(1013022), t - utc_offset)
end
--- 将一段时间转换为时分