mirror of
https://github.com/vrm-c/UniVRM.git
synced 2026-04-24 23:18:04 -05:00
throw if not IsCompleted
This commit is contained in:
parent
3b3756af89
commit
5af97a569e
|
|
@ -59,7 +59,10 @@ namespace UniHumanoid
|
|||
public static void RebuildHumanAvatar(Animator animator)
|
||||
{
|
||||
var task = RebuildHumanAvatarAsync(animator, new ImmediateCaller());
|
||||
task.Wait();
|
||||
if (!task.IsCompleted)
|
||||
{
|
||||
throw new Exception("task not completed");
|
||||
}
|
||||
}
|
||||
|
||||
public static async Task RebuildHumanAvatarAsync(Animator animator, IAwaitCaller awaitCaller)
|
||||
|
|
|
|||
|
|
@ -57,7 +57,10 @@ namespace VRM
|
|||
public static void Execute(GameObject go, bool forceTPose, bool useCurrentBlendShapeWeight)
|
||||
{
|
||||
var task = ExecuteAsync(go, forceTPose, useCurrentBlendShapeWeight, new ImmediateCaller());
|
||||
task.Wait();
|
||||
if (!task.IsCompleted)
|
||||
{
|
||||
throw new Exception("task not completed");
|
||||
}
|
||||
}
|
||||
|
||||
public static async Task ExecuteAsync(GameObject go, bool forceTPose, bool useCurrentBlendShapeWeight, IAwaitCaller awaitCaller)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user