• 请不要在回答技术问题时复制粘贴 AI 生成的内容
loverorser
V2EX  ›  程序员

有开发 Unity3d 的朋友吗,遇到个神奇 bug 求解决。

  •  
  •   loverorser · Jul 13, 2020 · 802 views
    This topic created in 2129 days ago, the information mentioned may be changed or developed.
    animator.Play("slash1");
    Debug.LogError(animator.GetCurrentAnimatorStateInfo(0).IsName("slash1"));
    yield return new WaitForEndOfFrame();
    Debug.LogError(animator.GetCurrentAnimatorStateInfo(0).IsName("slash1"));

    返回 false 和 true
    照理说,我都 play 了,那不应该马上变吗,还要等一帧才能获取到 是 bug 吗?
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   930 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 36ms · UTC 21:20 · PVG 05:20 · LAX 14:20 · JFK 17:20
    ♥ Do have faith in what you're doing.