Exemple #1
0
    public void DisplayZoneStructureInfo(ZoneStructureSO data)
    {
        Show();
        HideElement(clientsTxt.gameObject);

        SetText(nameTxt, data.buildingName);
        SetText(incomeTxt, data.GetIncome() + "");
        SetText(upkeepTxt, data.upkeepCost + "");
        if (data.requirePower)
        {
            SetToggle(powerToggle, data.HasPower());
        }
        else
        {
            HideElement(powerToggle.gameObject);
        }
        if (data.requireWater)
        {
            SetToggle(waterToggle, data.HasWater());
        }
        else
        {
            HideElement(waterToggle.gameObject);
        }
        if (data.requireRoadAccess)
        {
            SetToggle(roadToggle, data.HasRoadAccess());
        }
        else
        {
            HideElement(roadToggle.gameObject);
        }
    }
Exemple #2
0
 public void DisplayZoneStructureInfo(ZoneStructureSO data)
 {
     Show();
     HideElement(clientText.gameObject);
     HideElement(upkeepText.gameObject);
     SetText(nameText, data.buildingName);
     SetText(incomeText, data.GetIncome() + "");
     CheckStructureToDisplayMaterialBuildTimeText(data);
     CheckStructureToDisplayUpgradeAmountText(data);
     CheckStructureToDisplayResidentsText(data);
     CheckStructureToDisplayPowerToggle(data);
     CheckStructureToDisplayRoadToggle(data);
     CheckStructureToDisplayWaterToggle(data);
     CheckStructureToDisplayUpgradeToggle(data);
     CheckStructureToDisplaySiloToggle(data);
     CheckStructureToDisplayLawEnforcementToggle(data);
     CheckStructureToDisplayFireProtectionToggle(data);
     CheckStructureToDisplayHealthcareToggle(data);
     CheckStructureToDisplayPostalServiceToggle(data);
     CheckStructureToDisplayBankingServiceToggle(data);
     CheckStructureToDisplayGarbageServiceToggle(data);
 }