示例#1
0
 private void OnBuildingUnlockSelected(BuildingUnlockMessage value)
 {
     if (_building.Index == value.Index)
     {
         Outline.enabled = true;
     }
     else
     {
         Outline.enabled = false;
     }
 }
示例#2
0
    private void OnBuildingChange(BuildingUnlockMessage value)
    {
        _abilityMessage.Index = value.Index;
        HexModel hexModel = GameModel.Get <HexModel>();

        _abilityMessage.X = hexModel.X;
        _abilityMessage.Y = hexModel.Y;

        if (_life.BuildingsState[value.Index].State == BuildingState.LOCKED)
        {
            UnlockButton.interactable = true;
            BuildButton.interactable  = false;
        }
        else
        {
            UnlockButton.interactable = false;
            BuildButton.interactable  = true;
        }
    }