예제 #1
0
    override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
    {
        nangkuriBase = animator.GetComponent <Base_Nangkuri>();
        rBody        = animator.GetComponent <Rigidbody2D>();

        if (Random.Range(0, 1) == 0)
        {
            nangkuriBase.SwitchDirection();
        }
    }
예제 #2
0
 override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
 {
     nangkuriBase = animator.GetComponent <Base_Nangkuri>();
     animator.GetComponent <Rigidbody2D>().velocity = new Vector2(0.0f, animator.GetComponent <Rigidbody2D>().velocity.y);
 }
예제 #3
0
    override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
    {
        nangkuriBase = animator.GetComponent <Base_Nangkuri>();

        nangkuriBase.PlayerHurt.enabled = false;
    }
예제 #4
0
 override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
 {
     nangkuriBase = animator.GetComponent <Base_Nangkuri>();
     rBody        = animator.GetComponent <Rigidbody2D>();
 }