Added tree grwoth camera animation, fixed combat camera state, fixed many errors in the console

This commit is contained in:
2024-12-28 10:28:50 +01:00
parent e75b093317
commit f59a127a4e
10 changed files with 872 additions and 831 deletions

View File

@@ -85,7 +85,9 @@ namespace Invector
if (transform == null) return false;
var animator = transform.GetComponent<Animator>();
if (animator == null) return false;
var leftFoot = animator.GetBoneTransform(HumanBodyBones.LeftFoot);
Transform leftFoot = null;
if (animator.isHuman)
leftFoot = animator.GetBoneTransform(HumanBodyBones.LeftFoot);
vFootStepTrigger leftFoot_trigger = null;
if (leftFoot != null)
leftFoot_trigger = leftFoot.GetComponentInChildren<vFootStepTrigger>();
@@ -112,7 +114,9 @@ namespace Invector
collider.radius = 0.1f;
}
var rightFoot = animator.GetBoneTransform(HumanBodyBones.RightFoot);
Transform rightFoot = null;
if (animator.isHuman)
rightFoot = animator.GetBoneTransform(HumanBodyBones.RightFoot);
vFootStepTrigger rightFoot_trigger = null;
if (rightFoot != null)
rightFoot_trigger = rightFoot.GetComponentInChildren<vFootStepTrigger>();