private void RenderDisplayAnimation_OnInitialize(object sender, EventArgs e) { EngineCore.Initialize("Content", GraphicsDevice, RenderDisplayAnimation.Services); mSpriteBatch = new SpriteBatch(GraphicsDevice); mLineTexture = DrawHelper.Rect2Texture(1, 1, 0, Color.White); mSpriteFont = EngineCore.ContentLoader.Load <SpriteFont>(@"Fonts\Arial"); }
protected override void Initialize() { EngineCore.Initialize(@"Content\", GraphicsDevice, Services); EngineCore.InitComponents(this); Components.Add(ScreenManager); Components.Add(new CompFpsDisplay(this)); // Initialize & LoadContent for Compontents base.Initialize(); //ScreenManager.AddScreen(new ScreenLogin()); ScreenManager.Add(new ScreenTestInhouse()); }
/// <summary> /// Initializes a new instance of <see cref="ProcessEntryPoint"/>. /// </summary> /// <remarks> /// This call should only focus on initializing the variables and connecting to the host application. /// All business logic should be invoked in the <see cref="Run"/> method. /// Unhandled exception are redirected to the host application automatically. /// </remarks> /// <param name="inContext">Information about the environment in which the library main method has been invoked.</param> /// <param name="inChannelName">The name of the inter-process communication channel to connect to.</param> public ProcessEntryPoint(RemoteHooking.IContext inContext, string inChannelName) { // Name the current thread. if (Thread.CurrentThread.Name == null) { Thread.CurrentThread.Name = "Initializer"; } // Connect to server. IProcessSynchronizer sync = RemoteHooking.IpcConnectClient <ProcessSynchronizerInterface>(inChannelName).ProcessSynchronizer; // Initialize the guest's core. EngineCore.Initialize(sync); // Validate connection. if (!EngineCore.Connected) { throw new EngineException("Failed to validate the inter-process connection while initializing the guest's virtual environment."); } }
public static void Initialize() { Global.Config.NoRendering = true; SavedWorkingDirectory = Global.Config.WorkingDirectory; Global.Config.WorkingDirectory = "Content/"; Engine = new EngineCore(); Engine.Initialize("Ryne"); Editor = new SceneEditor(Engine.StateManager); var unitTestSceneFile = "Scenes/UnitTestScene/UnitTestScene.fls"; var unitTestDirectory = new FileInfo(Global.Config.WorkingDirectory + unitTestSceneFile).DirectoryName; if (Directory.Exists(unitTestDirectory)) { Directory.Delete(unitTestDirectory, true); } Editor.NewScene("UnitTestScene"); Engine.StateManager.Add(Editor); Engine.Update(0.0f); }