123456789101112131415161718192021 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- public class PlayerAnimator : MonoBehaviour
- {
- private const string IS_WALKING = "IsWalking";
- [SerializeField] private Player player;
- private Animator animator;
- private void Awake()
- {
- animator = GetComponent<Animator>();
- }
- private void Update()
- {
- animator.SetBool(IS_WALKING, player.IsWalking());
- }
- }
|