38f1ddb...178a853: v0.8.9.1, removed content folder

This commit is contained in:
Joonas Rikkonen
2019-03-18 19:46:58 +02:00
parent 38f1ddb6fe
commit 6c0679c297
1054 changed files with 151673 additions and 144931 deletions
@@ -14,10 +14,13 @@ namespace Barotrauma
public readonly IEnumerator<object> Coroutine;
public readonly string Name;
public Exception Exception;
public CoroutineHandle(IEnumerator<object> coroutine, string name = "")
{
Coroutine = coroutine;
Name = string.IsNullOrWhiteSpace(name) ? coroutine.ToString() : name;
Exception = null;
}
}
@@ -37,9 +40,9 @@ namespace Barotrauma
return handle;
}
public static void InvokeAfter(Action action, float delay)
public static CoroutineHandle InvokeAfter(Action action, float delay)
{
StartCoroutine(DoInvokeAfter(action, delay));
return StartCoroutine(DoInvokeAfter(action, delay));
}
private static IEnumerable<object> DoInvokeAfter(Action action, float delay)
@@ -107,6 +110,7 @@ namespace Barotrauma
catch (Exception e)
{
DebugConsole.ThrowError("Coroutine " + handle.Name + " threw an exception: " + e.Message + "\n" + e.StackTrace.ToString());
handle.Exception = e;
return true;
}
}