---
tags:
    - "Animation, Clip, Play, Animate"
---

# Animator Get Bone Transform

[Animation](../index.md) / [Animator](index.md) / **Animator Get Bone Transform**

## Description

Compares the Get Bone Transform method of Animator component to another value

## Parameters

| Name | Description |
| :--- | :---------- |
| Animator |  |
| Human Bone Id |  |
| Value |  |

## Code

```cs
// <auto-generated>
// This script was automatically generated using the Visual Script Transpiler.
// Do not modify. Changes to this file will be lost when updating the package.
// </auto-generated>

using System;
using UnityEngine;
using VisualScript.Icons;

namespace VisualScript.Runtime
{
    [Title("Animator Get Bone Transform")]
    [Category("Animation/Animator/Get Bone Transform")]
    [Description("Compares the Get Bone Transform method of Animator component to another value")]
    
    [Image(typeof(IconAnimator), ColorTheme.Type.Teal)]
    [Keywords("Animation, Clip, Play, Animate")]
    
    [Parameter("Animator")]
    [Parameter("Human Bone Id")]
    [Parameter("Value")]
    
    [Serializable]
    public class GenConditionGameObject_Animator_CheckGetBoneTransform_1 : Condition
    {
        [SerializeField] private GetGameObject m_Animator = new GetGameObject(
            new GenTypeGameObject_Animator()
        );
        
        [SerializeField] private GetGameObject m_Value = new GetGameObject();
        
        [SerializeField] private HumanBodyBones m_HumanBoneId = default;
        
        protected override string GetTitle(GameObject source)
        {
            string method = TextUtils.ThemeAsKeyword("Get Bone Transform");
            string parameters = $"({this.m_HumanBoneId})";
            return $"{this.m_Animator} {method} = {this.m_Value}";
        }
        
        protected override bool Run(Args args)
        {
            Animator component = this.m_Animator.Get<Animator>(args);
            if (component == null) return false;
            
            Transform value = component.GetBoneTransform(
                this.m_HumanBoneId
            );
            
            return value == this.m_Value.Get<Transform>(args);
        }
    }
}


```

