예제 #1
0
        public MainGalaxyViewModel(IGalaxyPopulator initGalaxyCreator,
                                   IGalaxyViewModelFactory initGalaxyViewModelFactory,
                                   ISolarSystemViewModelFactory initSolarSystemViewModelFactory,
                                   IPlanetViewModelFactory initPlanetViewModelFactory,
                                   ITextOutputViewModel initTextOutputViewModel,
                                   ITickEngine initTickEngine)
        {
            _galaxyCreator = initGalaxyCreator;
            _tickEngine    = initTickEngine;

            _galaxyViewModelFactory      = initGalaxyViewModelFactory;
            _solarSystemViewModelFactory = initSolarSystemViewModelFactory;
            _planetViewModelFactory      = initPlanetViewModelFactory;

            TextOutput = initTextOutputViewModel;

            StarChart.InitialiseStarChart();
            ResourceTypes.InitialiseResourceTypes();
            BluePrints.InitialiseBluePrints();

            loadOrCreateGalaxy();
            initialiseEngine();

            saveGalaxy();
        }