Добавление рук

This commit is contained in:
2025-01-25 13:22:39 +03:00
parent 2e85e07d1a
commit c2bcb1ecd8
36 changed files with 4210 additions and 14 deletions

View File

@ -0,0 +1,28 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.InputSystem;
public class AnimateHandOnInputScript : MonoBehaviour
{
public InputActionProperty PinchAnimationAction;
public InputActionProperty GripAnimationAction;
public Animator HandAnimator;
// Start is called before the first frame update
void Start()
{
}
// Update is called once per frame
void Update()
{
float tiggerValue = PinchAnimationAction.action.ReadValue<float>();
HandAnimator.SetFloat("Trigger", tiggerValue);
float gripValue = GripAnimationAction.action.ReadValue<float>();
HandAnimator.SetFloat("Grip", gripValue);
}
}