Ejemplo n.º 1
0
    public void ThatFillInData(assemblyCsharp.Province province)
    {
        this.Name.text = province.getProvName();
        string resource = province.getResource().ToString();

        Sprite newResourceSprite = Resources.Load("Resource/" + resource, typeof(Sprite)) as Sprite;

        this.Resource.sprite         = newResourceSprite;
        this.Resource.preserveAspect = true;
        Debug.Log("You f****r...." + province.getProduction().ToString());
        this.Produces.text      = "Produces " + province.getProduction().ToString("0.0") + " " + resource + " /turn";
        this.RailroadLevel.text = province.getInfrastructure().ToString();
        this.FortLevel.text     = province.getFortLevel().ToString();
        this.Culture.text       = "Culture: " + province.culture;
        // this.resourceText.text = "Province produces " + resource;
        string nation = province.getOwner().ToString();

        Debug.Log("Owner: " + nation);
        this.DevelopmentLevel.text = province.getDevelopmentLevel().ToString();
        this.NationName.text       = nation;
        //text.text = "Province produces " + Resource;
        this.Flag.sprite = Resources.Load("Flags/" + province.getOwner().ToString(), typeof(Sprite)) as Sprite;
        pickProductionPicture(province);
        // Text flagText = FlagTip.GetComponentInChildren<Text>();
        // Debug.Log("Flag text: " + flagText.text);
        // flagText.text = Owner;
        //flagTip.GetComponent<Text>().text = nation;
    }
Ejemplo n.º 2
0
    public void ThatFillInData(assemblyCsharp.Province province)
    {
        this.Name.text = province.getProvName();
        string resource = province.getResource().ToString();

        Sprite newResourceSprite = Resources.Load("Resource/" + resource, typeof(Sprite)) as Sprite;

        this.Resource.sprite    = newResourceSprite;
        this.Produces.text      = "Produces " + Produces.ToString() + " " + resource + " /turn";
        this.RailroadLevel.text = province.getInfrastructure().ToString();
        this.FortLevel.text     = province.getFortLevel().ToString();
        this.Culture.text       = "Culture: " + province.culture;
        this.resourceText.text  = "Province produces " + resource;
        string nation = province.getOwner().ToString();

        this.NationName.text = nation;
        //text.text = "Province produces " + Resource;
        this.Flag.sprite = Resources.Load("Flags/" + province.getOwner().ToString(), typeof(Sprite)) as Sprite;
        // Text flagText = FlagTip.GetComponentInChildren<Text>();
        // Debug.Log("Flag text: " + flagText.text);
        // flagText.text = Owner;
    }