public SceneEditorWindow(EcgRuntime.EcgRuntime ecgRuntime) { InitializeComponent(); _ecgRuntime = ecgRuntime; var task = Task.Delay(100).ContinueWith((task) => Dispatcher.Invoke(InitializeEngine)); }
public SceneEditorWindowViewModel(EcgRuntime.EcgRuntime ecgRuntime, IRegionManager regionManager) { _ecgRuntime = ecgRuntime; CreateSceneCommand = new DelegateCommand(() => { _ecgRuntime.CreateNewScene("ecgsave1.json"); }); RunGameCommand = new DelegateCommand(() => { _ecgRuntime.Run(); }); CreateAndRunCommand = new DelegateCommand(() => { CreateSceneCommand.Execute(); RunGameCommand.Execute(); }); ScopedRegionManager = regionManager.CreateRegionManager(); }