using eagle;
using Net.Eagle0.Eagle.Api;
using TMPro;
using UnityEngine;

public class WaitingGameItem : MonoBehaviour {
    public GameObject item;
    public TextMeshProUGUI gameIdField;
    public TextMeshProUGUI leaderField;
    public TextMeshProUGUI playerCountField;

    // Use this for initialization
    void Start() {}

    public void SetWaitingGame(long gameId, string playersString, AvailableLeader leader) {
        gameIdField.text = string.Format("{0:X}", gameId);
        playerCountField.text = playersString;

        leaderField.text = string.Format(
                "{0} ({1})",
                ClientTextProvider.Provider.GetTextEntry(leader.NameTextId).Text,
                DisplayNames.ProfessionNames[leader.Profession]);
    }
}
