换成国际版的参数后在尝试登录时报错

首先Unity版本应该不分国际版和大陆版吧,理论上为了降低维护成本,都是一套SDK。

我分别注册了华北账号和国际账号。

又下载了最新的Unity SDK。

换成华北账号下的应用参数时,注册 和 登录 都没有问题(可能是我之前SDK版本不新导致了奇怪的问题,即默认的数据库class被全部删掉了)。

但是换成国际账号下的应用参数时,在调用注册或登录接口时都会报错,后来我考虑到,可能是国际账号对应的服务器,大陆ip无法访问(被墙),然后开启了梯子,但还是不行,报错还是一样的。相关信息如下:

=== HTTP Response Start ===
URL: https://czscpxvn.api.lncldglobal.com/1.1/login
Status Code: Forbidden
Content: error code: 1020
=== HTTP Response End ===

Newtonsoft.Json.JsonReaderException
Unexpected character encountered while parsing value: e. Path '', line 0, position 0.
at Newtonsoft.Json.JsonTextReader.ParseValue () [0x002b3] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.JsonTextReader.Read () [0x0004c] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.JsonReader.ReadAndMoveToContent () [0x00000] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.JsonReader.ReadForType (Newtonsoft.Json.Serialization.JsonContract contract, System.Boolean hasConverter) [0x0004a] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize (Newtonsoft.Json.JsonReader reader, System.Type objectType, System.Boolean checkAdditionalContent) [0x000db] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.JsonSerializer.DeserializeInternal (Newtonsoft.Json.JsonReader reader, System.Type objectType) [0x00054] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.JsonSerializer.Deserialize (Newtonsoft.Json.JsonReader reader, System.Type objectType) [0x00000] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.JsonConvert.DeserializeObject (System.String value, System.Type type, Newtonsoft.Json.JsonSerializerSettings settings) [0x0002d] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.JsonConvert.DeserializeObject (System.String value, System.Type type, Newtonsoft.Json.JsonConverter[] converters) [0x00017] in <394015232cf841bc8e43c6c98d8e6545>:0
at Newtonsoft.Json.JsonConvert.DeserializeObject[T] (System.String value, Newtonsoft.Json.JsonConverter[] converters) [0x00000] in <394015232cf841bc8e43c6c98d8e6545>:0
at LeanCloud.Storage.Internal.Http.LCHttpClient.HandleErrorResponse (System.Net.HttpStatusCode statusCode, System.String responseContent) [0x00004] in <109eda799e47497bbd313cc0d62b823a>:0
UnityEngine.Debug:LogWarning(Object)

403 - error code: 1020

你好,SDK 是不分国内版和国际版的,您可以使用同一套 SDK 访问国内版和国际版的服务。

访问服务时遇到 1020 错误是因为您从中国大陆通过共享域名访问了国际版服务。可以参阅这篇公告了解解决办法。

国内版数据存储服务的问题刚刚在另一个帖子中说明了。目前该问题已解决。