mirror of
https://github.com/vrm-c/UniVRM.git
synced 2026-08-22 10:34:54 -05:00
Fix for failed tests.
This commit is contained in:
@@ -51,6 +51,11 @@ namespace UniVRM10
|
||||
|
||||
public Vrm10Runtime(Vrm10Instance target, bool useControlRig)
|
||||
{
|
||||
if (!Application.isPlaying)
|
||||
{
|
||||
Debug.LogWarning($"{nameof(Vrm10Runtime)} expects runtime behaviour.");
|
||||
}
|
||||
|
||||
m_target = target;
|
||||
|
||||
if (!target.TryGetBoneTransform(HumanBodyBones.Head, out m_head))
|
||||
|
||||
@@ -96,8 +96,6 @@ namespace UniVRM10
|
||||
|
||||
private static Transform InitializeLookAtOriginTransform(Transform rawHead, Transform actualHead, Vector3 eyeOffsetValue)
|
||||
{
|
||||
if (!Application.isPlaying) return null;
|
||||
|
||||
// NOTE: このメソッドを実行するとき、モデル全体は初期姿勢(T-Pose)でなければならない。
|
||||
var lookAtOrigin = new GameObject("_look_at_origin_").transform;
|
||||
lookAtOrigin.SetParent(actualHead);
|
||||
@@ -108,19 +106,19 @@ namespace UniVRM10
|
||||
}
|
||||
|
||||
#region Obsolete
|
||||
[Obsolete]
|
||||
[Obsolete("Use " + nameof(LookAtOriginTransform))]
|
||||
public Transform GetLookAtOrigin(Transform head)
|
||||
{
|
||||
return LookAtOriginTransform;
|
||||
}
|
||||
|
||||
[Obsolete]
|
||||
[Obsolete("Use " + nameof(SetYawPitchManually))]
|
||||
public void SetLookAtYawPitch(float yaw, float pitch)
|
||||
{
|
||||
SetYawPitchManually(yaw, pitch);
|
||||
}
|
||||
|
||||
[Obsolete]
|
||||
[Obsolete("Use " + nameof(Yaw) + " & " + nameof(Pitch))]
|
||||
public (float, float) GetLookAtYawPitch(
|
||||
Transform head,
|
||||
VRM10ObjectLookAt.LookAtTargetTypes lookAtTargetType,
|
||||
|
||||
Reference in New Issue
Block a user