因此,对于某些上下文,我创建了一个在52秒后加载的健康栏(等待52秒,然后从0健康到100健康),现在我也设置了检查点。两者各自工作良好,但当我死时,健康条动画重置,我必须等待52秒才能看到健康栏。当您在检查点死亡和重生时,我试着禁用动画器,但这不起作用,因为它被我的健康栏脚本覆盖了。这是我的健康栏脚本: using System.Collections.Generic; using UnityEngine.UI;
public class
我试着用unity 教程制作一个简单的miltiplayer游戏。播放器的代码如下所示: using System.Collections.Generic; using[SyncVar(hook="OnChangeHealth")] public int currentHealth = maxHeath;
public RectTransform healthBar= new Vector2(((float)h