Battleship in AngularJS