public void Render() { Gl.glClearColor(1, 1, 1, 0); Gl.glClear(Gl.GL_COLOR_BUFFER_BIT); Point mousePosition = _input.Mouse.Position; PrimitiveDrawer.DrawCrosshair(mousePosition.X, mousePosition.Y); _pathData.NavMesh.Render(); _nodeUI.ForEach(x => x.Render()); if (_start != null) { PrimitiveDrawer.DrawSquare(_start.Position.X, _start.Position.Y, 20, new Color(0, 0, 0, 1)); } if (_end != null) { PrimitiveDrawer.DrawSquare(_end.Position.X, _end.Position.Y, 20, new Color(0.1f, 0.1f, 0.1f, 1)); } if (_astar.Path.Count != 0) { DrawPath(_astar.Path); } Gl.glEnable(Gl.GL_TEXTURE_2D); Gl.glBlendFunc(Gl.GL_SRC_ALPHA, Gl.GL_ONE_MINUS_SRC_ALPHA); _renderer.Render(); Gl.glDisable(Gl.GL_TEXTURE_2D); _textBuffer.Clear(); }