Created
January 12, 2019 18:47
-
-
Save OhkuboSGMS/5d05f3abd5f959316e29ac408eec58d5 to your computer and use it in GitHub Desktop.
OAuthの事前認証のためのスクリプト
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
public class UploadTest : UnityEngine.MonoBehaviour | |
{ | |
private void Start() | |
{ | |
StartCoroutine(Upload()); | |
} | |
IEnumerator Upload() | |
{ | |
var data = new UnityGoogleDrive.Data.File | |
{Name = "Test.txt", Content = System.Text.Encoding.UTF8.GetBytes("Hello Google Drive ")}; | |
var req = UnityGoogleDrive.GoogleDriveFiles.Create(data); | |
print("Start Test Upload"); | |
yield return req.Send(); | |
print("Finish Test Upload"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment