彻底修好了
This commit is contained in:
@@ -14,6 +14,7 @@ namespace Continentis.MainGame.UI
|
||||
public bool isTeam;
|
||||
public Button button;
|
||||
public TMP_Text buttonText;
|
||||
public TMP_Text teamPileText;
|
||||
private void Awake()
|
||||
{
|
||||
isTeam = false;
|
||||
@@ -25,11 +26,13 @@ namespace Continentis.MainGame.UI
|
||||
{
|
||||
SwitchToTeam();
|
||||
buttonText.text = "Team";
|
||||
teamPileText.gameObject.SetActive(true);
|
||||
}
|
||||
else
|
||||
{
|
||||
SwitchToCurrentCharacter();
|
||||
buttonText.text = "Hero";
|
||||
teamPileText.gameObject.SetActive(false);
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -74,5 +77,12 @@ namespace Continentis.MainGame.UI
|
||||
throw new Exception("当前角色不是玩家角色,无法显示卡牌。");
|
||||
}
|
||||
}
|
||||
|
||||
public void UpdateTeamPileText(CombatTeam team)
|
||||
{
|
||||
int currentCardCount = team.deckSubmodule.HandPile.Count;
|
||||
teamPileText.text = $"{currentCardCount}/10";
|
||||
Debug.Log($"Updated team pile text: {teamPileText.text}");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user