Class Board

    • Constructor Detail

      • Board

        public Board()
    • Method Detail

      • setController

        public static void setController​(MainController controller)
      • sendMessage

        public void sendMessage()
        Message to send
      • initialize

        public void initialize()
        Initialize the board
      • showWorker

        public void showWorker​(MouseEvent e)
        Show worker's preview on the board
        Parameters:
        e - mouse event
      • closeWorker

        public void closeWorker​(MouseEvent e)
        Close the showWorker() preview
        Parameters:
        e - mouse event
      • showConsequence

        public void showConsequence​(MouseEvent event)
        After choosing the block, it shows the preview of actions
        Parameters:
        event - mouse event
      • closeConsequence

        public void closeConsequence​(MouseEvent event)
        Close the preview of showConsequence()
        Parameters:
        event - mouse event
      • showGod

        public void showGod​(MouseEvent event)
        Show god power's image description
        Parameters:
        event - mouse event
      • closeGod

        public void closeGod​(MouseEvent event)
        Close showGod()
        Parameters:
        event - event
      • chooseColor

        public void chooseColor​(MouseEvent event)
        Set worker's color and send the choice to server
        Parameters:
        event - mouse event
      • chooseAction

        public void chooseAction​(MouseEvent event)
        Send player's actions to server
        Parameters:
        event - mouse event
      • chooseCell

        public void chooseCell​(MouseEvent event)
        After choosing the grid on board, shows all available actions for the chosen grid
        Parameters:
        event - mouse event
      • reSet

        public void reSet()
        Reload the board for all players
        Specified by:
        reSet in interface Controller
      • setDimension

        public void setDimension​(double width,
                                 double height)
        set view's dimension
        Specified by:
        setDimension in interface Controller
        Parameters:
        width - width
        height - height
      • changePage

        public void changePage​(Boolean status)
        Change view
        Specified by:
        changePage in interface Controller
        Parameters:
        status - if it's allowed to change view