美文网首页UNITY游戏开发
[unity]加入动画的一些代码

[unity]加入动画的一些代码

作者: suxsho_枫2 | 来源:发表于2018-08-03 16:53 被阅读0次

    private Animator animator;

    - start

    animator = GetComponent <Animator>();

    - update

    //检测速度,然后执行

    animator.SetFloat ("velocityX", Mathf.Abs (velocity.x))

    相关文章

      网友评论

        本文标题:[unity]加入动画的一些代码

        本文链接:https://www.haomeiwen.com/subject/qqkuvftx.html