The game engine of the battleships game