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
// written by https://github.com/FreyaHolmer so use at your own risk c: | |
using System.Collections.Generic; | |
using UnityEditor; | |
using UnityEngine; | |
/// <summary>Utility functions to copy GUIDs, as well as Copy/Paste import settings</summary> | |
public static class AssetCopyUtils { | |
const int CTX_MENU_LOCATION = 70; |
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
public static class ExtensionMethods | |
{ | |
public static TaskAwaiter GetAwaiter(this AsyncOperation asyncOp) | |
{ | |
var tcs = new TaskCompletionSource<object>(); | |
asyncOp.completed += obj => { tcs.SetResult(null); }; | |
return ((Task)tcs.Task).GetAwaiter(); | |
} | |
} |