implementation of drecon in unity 2022 lts forked from: https://github.com/joanllobera/marathon-envs
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
1.4 KiB

9 months ago
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class MocapRangeOfMotionAnimatorController : MonoBehaviour
{
Animator _anim;
Animation _animation;
public Motion[] Motions;
// Start is called before the first frame update
void Start()
{
_anim = GetComponent<Animator>();
foreach (var motion in Motions)
{
// _anim.CrossFade()
// _anim.()
// _animation.CrossFadeQueued(motion.name);
}
// _animation = GetComponent<Animation>();
// // _characterController = GetComponent<CharacterController>();
// // _spawnableEnv = GetComponentInParent<SpawnableEnv>();
// // _inputController = _spawnableEnv.GetComponentInChildren<InputController>();
// // _targetDirection = Quaternion.Euler(0, 90, 0);
// // var ragDoll = _spawnableEnv.GetComponentInChildren<RagDollAgent>( true);//we include inactive childs
// _animation.CrossFadeQueued("jump");
// _animation.CrossFadeQueued("animation2");
// _animation.CrossFadeQueued("animation3");
// var anim = _animation["animation3"];
}
// Update is called once per frame
void Update()
{
}
// Called each physics step (so long as the Animator component is set to Animate Physics) after FixedUpdate to override root motion.
void OnAnimatorMove()
{
// do nothing
}
}