private void Form1_Load(object sender, EventArgs e) { // load skin file string[] datapaths = new[] { Path.Combine(Path.Combine(Path.Combine("..", ".."), ".."), "data"), "data" }; getfile = new GetFileStream(datapaths); richTextBox1.Text = new StreamReader(getfile.GetFile("player.txt")).ReadToEnd(); // init UI RichTextBoxContextMenu(richTextBox1); RichTextBoxContextMenu(richTextBox2); UpdateLabels(); // init 3D rendering the3d = new ManicDigger.TextureLoader() { d_Config3d = config3d }; glControl1.Paint += new PaintEventHandler(glControl1_Paint); glControl1.MouseWheel += new System.Windows.Forms.MouseEventHandler(glControl1_MouseWheel); loaded = true; GL.ClearColor(Color.SkyBlue); overheadcameraK.SetDistance(4); overheadcameraK.SetT((float)Math.PI); SetupViewport(); Application.Idle += new EventHandler(Application_Idle); sw.Start(); }
private void Form1_Load(object sender, EventArgs e) { string[] datapaths = new[] { Path.Combine(Path.Combine(Path.Combine("..", ".."), ".."), "data"), "data" }; getfile = new GetFileStream(datapaths); richTextBox1.Text = new StreamReader(getfile.GetFile("player.txt")).ReadToEnd(); RichTextBoxContextMenu(richTextBox1); RichTextBoxContextMenu(richTextBox2); UpdateLabels(); the3d = new ManicDigger.TextureLoader() { d_Config3d = config3d }; glControl1.Paint += new PaintEventHandler(glControl1_Paint); glControl1.MouseWheel += new System.Windows.Forms.MouseEventHandler(glControl1_MouseWheel); loaded = true; GL.ClearColor(Color.SkyBlue); overheadcameraK.SetDistance(3); overheadcameraK.SetT((float)Math.PI); SetupViewport(); Application.Idle += new EventHandler(Application_Idle); sw.Start(); }