示例#1
0
        public WWW Export_Google_CreateWWWcall(eSpreadsheetUpdateMode UpdateMode = eSpreadsheetUpdateMode.Replace)
        {
            string  value   = Export_Google_CreateData();
            WWWForm wWWForm = new WWWForm();

            wWWForm.AddField("key", Google_SpreadsheetKey);
            wWWForm.AddField("action", "SetLanguageSource");
            wWWForm.AddField("data", value);
            wWWForm.AddField("updateMode", UpdateMode.ToString());
            return(new WWW(LocalizationManager.GetWebServiceURL(this), wWWForm));
        }
示例#2
0
        public WWW Export_Google_CreateWWWcall(eSpreadsheetUpdateMode UpdateMode = eSpreadsheetUpdateMode.Replace)
        {
                        #if UNITY_WEBPLAYER
            Debug.Log("Contacting google translation is not yet supported on WebPlayer");
            return(null);
                        #else
            string Data = Export_Google_CreateData();

            WWWForm form = new WWWForm();
            form.AddField("key", Google_SpreadsheetKey);
            form.AddField("action", "SetLanguageSource");
            form.AddField("data", Data);
            form.AddField("updateMode", UpdateMode.ToString());

            WWW www = new WWW(Google_WebServiceURL, form);
            return(www);
                        #endif
        }
        public UnityWebRequest Export_Google_CreateWWWcall(eSpreadsheetUpdateMode UpdateMode = eSpreadsheetUpdateMode.Replace)
        {
            #if UNITY_WEBPLAYER
            Debug.Log("Contacting google translation is not yet supported on WebPlayer");
            return(null);
#else
            string Data = Export_Google_CreateData();

            WWWForm form = new WWWForm();
            form.AddField("key", Google_SpreadsheetKey);
            form.AddField("action", "SetLanguageSource");
            form.AddField("data", Data);
            form.AddField("updateMode", UpdateMode.ToString());

            #if UNITY_EDITOR
            form.AddField("password", Google_Password);
#endif


            UnityWebRequest www = UnityWebRequest.Post(LocalizationManager.GetWebServiceURL(this), form);
            I2Utils.SendWebRequest(www);
            return(www);
                        #endif
        }