예제 #1
0
    protected override void Disable()
    {
        base.Disable();
        this.boardCreator.RemoveAllBlinks();
        selectedUnit.HideAbilities();

        if (this.hoveredTile)
        {
            this.hoveredTile.HighlightOff();
        }

        CursorController.SetDefault();

        Unibus.Unsubscribe <UnitDisplay>(BoardCreator.UNIT_CLICKED_ON_BOARD, OnUnitSelectedOnBoard);
        Unibus.Unsubscribe <Point>(BoardCreator.CLICKED_ON_VOID_TILE, OnClickedOnVoidTile);
        Unibus.Unsubscribe <UnitDisplay>(BoardCreator.UNIT_MOUSE_ENTER_ON_BOARD, OnUnitMouseEnterOnBoard);
        Unibus.Unsubscribe <UnitDisplay>(BoardCreator.UNIT_MOUSE_EXIT_ON_BOARD, OnUnitMouseExitOnBoard);
        Unibus.Unsubscribe <TileDisplay>(BoardCreator.TILE_WITHOUT_UNIT_MOUSE_ENTER_ON_BOARD, OnTileMouseEnterOnBoard);
        Unibus.Unsubscribe <TileDisplay>(BoardCreator.TILE_WITHOUT_UNIT_MOUSE_EXIT_ON_BOARD, OnTileMouseExitOnBoard);
        Unibus.Unsubscribe <AbilityActivated>(UnitDisplay.ABILITY_ACTIVATED, OnAbilityActivated);
        Unibus.Unsubscribe <CardDisplay>(CardDisplay.CARD_CLICKED, OnCardClicked);
        Unibus.Unsubscribe <CardDisplay>(CardManager.CARD_MOVED, OnCardMoved);
    }