public MapRepository(IMapContext context) { this.context = context; using (var mysqlContext = new MapMSSQLContext()) { // Creates the database if not exists mysqlContext.Database.EnsureCreated(); mysqlContext.SaveChanges(); } }
public SingleplayerController() { IMapContext context = new MapMSSQLContext(); mapRepository = new MapRepository(context); }
public MapCreatorController() { IMapContext context = new MapMSSQLContext(); mapRepository = new MapRepository(context); }