diff --git a/src/MapsCollection.java b/src/MapsCollection.java index 3bdccf0..b8e1783 100644 --- a/src/MapsCollection.java +++ b/src/MapsCollection.java @@ -150,11 +150,11 @@ public class MapsCollection { case "SecondMap" -> new MapWithSetWarshipsGeneric<>(_pictureWidth, _pictureHeight, new SecondMap()); default -> null; }; + _mapStorages.put(mapName, map); } while ((currentLine = reader.readLine()) != null) { map._setWarship.Insert((DrawingObjectWarship) DrawingObjectWarship.Create(currentLine)); } - _mapStorages.put(mapName, map); } return true; }