@ -1,5 +1,26 @@
package BattleShip;
public class BSButton {
import javax.swing.*;
public class BSButton extends JButton {
int gridLocation;
Ship cellContents = null;
public void setGridLocation(int l) {
gridLocation = l;
}
public int getGridLocation() {
return gridLocation;
public void setCellContents(Ship s) {
cellContents = s;
public Ship getCellContents() {
return cellContents;
@ -1,6 +1,6 @@
public class Direction {
class Direction {
int countHits, cellLocation;