コード例 #1
0
    void Start()
    {
        if (settlerName == null ||
            workplaceButton == null)
        {
            Debug.LogWarning("Component hasn't been fully initialized!");
        }
        if (s_instance != null)
        {
            Debug.LogWarning("Once instance is allowed!");
        }
        s_instance = this;

        devSettings.onClick.AddListener(() => { UI_DevSettler.SShowSettler(m_settler); });
    }
コード例 #2
0
ファイル: UI_ScreenBuilding.cs プロジェクト: Rivenort/Test
    /// <summary>[SetInInspector] On info button click event </summary>
    public void OnProductionInfoButtonClick()
    {
        if (!(m_currentBuilding is IBuildingProduction))
        {
            Debug.LogWarning("Building is not a production one.");
            return;
        }
        Guid settler = ((IBuildingProduction)m_currentBuilding).GetWorker();

        if (settler == Guid.Empty)
        {
            Debug.LogWarning("Production Building doesn't have a worker.");
            return;
        }
        UI_ScreenSettler.SShowSettler(settler);
    }
コード例 #3
0
 public void OnClickInfo()
 {
     UI_ScreenSettler.SShowSettler(m_settler);
 }
コード例 #4
0
ファイル: UI_ElemSettlerRemove.cs プロジェクト: Rivenort/Test
 public void OnClickInfo()
 {
     UI_ScreenSettler.SShowSettler(m_settler);
     M_ScreenManager.SChangeScreenPersistentBack(m_settlerScreen);
     UI_ScreenRemoveWorker.SSetIfInfoScreen(true);
 }