private void shoot() {
        boolean cur = GUI.whosTurn;
        if (this.p == GUI.getPlayer(cur)) {    //ei voi ampua omalle alueelle
            return;
        }
        int result;

        /*yritys optimoida allaolevaa metodin osiota. ei toimi vielä*/
//        result = GUI.getPlayer(cur).shoot(GUI.getPlayer(!cur), x, y);
//        if (GUI.getPlayer(!cur).getFleet().isEmpty()) {
//            result = -3;
//            GUI.win = true;
//            GUI.setWhosTurn();
//        } else if (result == -1) {
//            if (!GUI.pvp) {
//                GUI.setWhosTurn();
//            }
//        }
        if (GUI.whosTurn) {
            result = GUI.getPlayer1().shoot(GUI.getPlayer2(), x, y);
            if (GUI.getPlayer2().getFleet().isEmpty()) {
                result = -3;
                GUI.win = true;
                GUI.setWhosTurn();
            } else if (result == -1) {
                if (!GUI.pvp) {
                    GUI.setWhosTurn();
                }

            }
        } else {
            result = GUI.getPlayer2().shoot(GUI.getPlayer1(), x, y);
            if (GUI.getPlayer1().getFleet().isEmpty()) {
                result = -3;
                GUI.win = true;
                GUI.setWhosTurn();
            }
            if (result == -1) {
                if (!GUI.pvp) {
                    GUI.setWhosTurn();
                }
            }

        }
        GUI.infoState(result);
        updateColour(state);
        GUI.g1.updateAll();
        GUI.g2.updateAll();
    }