public override void Render() { // These 3 render calls are a hack to get the console data generated and display a message to the user // Should add in async calls that let us generate these in the background... That would be cool. if (!initialized) { base.Render(); } else if (!initializedStep2) { initializedStep2 = true; base.Render(); messageData.Render(); } else if (!initializedStep3) { base.Render(); // Generate the content //mainData = new CellSurface(2000, 2000); // Clear message data and make it transparent so that it acts as a layer messageData.Fill(Color.White, Color.Transparent, 0, null); generator = new SadConsole.Game.WorldGeneration.WrappingWorldGenerator <SadConsole.Game.WorldGeneration.TextSurfaceMap, TextSurface>(); generator.Start(512, 256); textSurface = generator.BiomeMapRenderer; messageData.Print(0, 0, $"[SPACE] Change Map Info [ENTER] New Map -- Biome ", Color.White, Color.Black); textSurface.Font = Engine.Fonts[Engine.DefaultFont.Name].GetFont(SadConsole.Font.FontSizes.Half); initializedStep3 = true; } else { // Set message data information about where the viewport is located //messageData.CellData.Print(0, 0, $"{ViewArea.X} , {ViewArea.Y} ", Color.White, Color.Black); // Create a faux layering system. base.Render(); if (IsVisible) { messageData.Render(); } } }
public override void Render() { base.Render(); ActorLayer.Render(); GuiLayer.Render(); }