static void Main() { //Application.EnableVisualStyles(); //Application.SetCompatibleTextRenderingDefault(false); //Application.Run(new Form1()); string path = Application.ExecutablePath; EndogineHub endogine = new EndogineHub(path); string[] aAvailableStrategies = StageBase.GetAvailableRenderers(); //Endogine.MdiParent mdiParent = new MdiParent(); //SetupWindow wndSetup = new SetupWindow(aAvailableStrategies, mdiParent); SetupWindow wndSetup = new SetupWindow(aAvailableStrategies, null); wndSetup.ShowDialog(); Main main = new Main(); main.Show(); endogine.Init(main, null, null); main.EndogineInitDone(); MusicGame.Midi.Main game = new MusicGame.Midi.Main(); while (endogine.MainLoop()) Application.DoEvents(); }
public void NoReceiveEndogineKeys() { if (m_endogine != null) { m_endogine.KeyEvent -= new KeyEventHandler(m_endogine_KeyEvent); } m_endogine = null; }
public CastLib(EndogineHub a_endogine) { m_endogine = a_endogine; //this.Animations = new Animations(); this.FrameSets = new FrameSets(); //this.Pictures = new PicRefs(); }
private void rb_CheckedChanged(object sender, EventArgs e) { RadioButton rb = (RadioButton)sender; if (rb.Checked) { EndogineHub endo = EndogineHub.Instance; endo.PreSetRenderStrategy(rb.Text); } }
public MainBase() { m_endogine = EndogineHub.Instance; InitializeComponent(); if (m_endogine != null) { this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.UserPaint | ControlStyles.Opaque, true); // if (m_endogine.CurrentRenderStrategy == EndogineHub.RenderStrategy.GDI) // this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.UserPaint | ControlStyles.Opaque, true); // else // this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.Opaque, true); } }
public MainBase() { m_endogine = EndogineHub.Instance; InitializeComponent(); if (m_endogine!=null) { this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.UserPaint | ControlStyles.Opaque, true); // if (m_endogine.CurrentRenderStrategy == EndogineHub.RenderStrategy.GDI) // this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.UserPaint | ControlStyles.Opaque, true); // else // this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.Opaque, true); } }
static void Main(string[] args) { EndogineHub endogine = new EndogineHub(Application.ExecutablePath); Main main = new Main(); main.Show(); endogine.Init(main, null, null); main.EndogineInitDone(); Driver.Game game = new Driver.Game(); while (endogine.MainLoop()) Application.DoEvents(); }
public void ReceiveEndogineKeys(EndogineHub a_endogine) { if (m_endogine != null) { m_endogine.KeyEvent -= new KeyEventHandler(m_endogine_KeyEvent); } if (a_endogine == null) { a_endogine = EH.Instance; } m_endogine = a_endogine; m_endogine.KeyEvent += new KeyEventHandler(m_endogine_KeyEvent); }
private void checkBox1_CheckedChanged(object sender, System.EventArgs e) { EndogineHub endo = EndogineHub.Instance; bool bFull = ((CheckBox)sender).Checked; endo.PreSetFullscreen(bFull); if (bFull) { cbMDI.Checked = false; cbMDI.Enabled = false; } else { cbMDI.Enabled = true; } }
private Form _startupForm; //TODO: shouldn't have such a thing, console startup rather... public EndogineHub(string a_sApplicationPath) { m_sApplicationPath = a_sApplicationPath; m_pntMouseLoc = new EPoint(); m_endogine = this; AppSettings app = new AppSettings(); string s = AppSettings.Instance.GetNodeText("DisplayMode.Fullscreen"); if (s != null) { m_bFullscreen = Convert.ToBoolean(s); } s = AppSettings.Instance.GetNodeText("DisplayMode.Renderer"); if (s != null) { this._renderStrategy = s; } }
public Sprite(EndogineHub a_endogine) { m_endogine = a_endogine; Init(true); }
public Sprite(bool bAutoSetParent) { m_endogine = EndogineHub.Instance; Init(bAutoSetParent); }
public Sprite() { m_endogine = EndogineHub.Instance; Init(true); }
public void SetEndogine(EndogineHub a_endogine) { m_endogine = a_endogine; }
public void NoReceiveEndogineKeys() { if (m_endogine != null) m_endogine.KeyEvent -= new KeyEventHandler(m_endogine_KeyEvent); m_endogine = null; }
public SpriteOneFrame(EndogineHub a_endogine) : base(a_endogine) { }
//protected Control target = null; public StageGDI(Control RenderControl, EndogineHub a_endogine) : base(RenderControl, a_endogine) { }
public TestLine(EndogineHub a_endogine) : base(a_endogine) { }
public static void Put(string s) { EndogineHub.Put(s); }
public Stage3D(Control RenderControl, EndogineHub a_endogine) : base(RenderControl, a_endogine) { }
private void Form1_Load(object sender, System.EventArgs e) { m_endogine = new EndogineHub(Application.ExecutablePath); string[] aAvailableStrategies = StageBase.GetAvailableRenderers(null); // string[] aAvailableStrategies = new string[]{Enum.GetName(typeof(EndogineHub.RenderStrategy), 0), Enum.GetName(typeof(EndogineHub.RenderStrategy), 1)}; if (Endogine.AppSettings.Instance.GetNodeText("MDI") != "false") this.IsMdiContainer = true; if (Endogine.AppSettings.Instance.GetNodeText("SetupDialog") != "false") { SetupWindow wndSetup = new SetupWindow(aAvailableStrategies, this); wndSetup.ShowDialog(); } m_formStage = new Main(); Form formMdiParent = (Form)null; if (this.IsMdiContainer) { this.Width = 800; this.Height = 600; this.WindowState = FormWindowState.Maximized; formMdiParent = this; m_formStage.MdiParent = this; } else { this.Visible = false; //TODO: this doesn't work this.Text = "Should be invisible!"; } //TODO: anyhow, it's strange to use a Form to start from, the project should probably be a console application. m_formStage.Show(); m_endogine.Init(m_formStage, formMdiParent, this); m_formStage.EndogineInitDone(); }
public void ReceiveEndogineKeys(EndogineHub a_endogine) { if (m_endogine != null) m_endogine.KeyEvent -= new KeyEventHandler(m_endogine_KeyEvent); if (a_endogine == null) a_endogine = EH.Instance; m_endogine = a_endogine; m_endogine.KeyEvent+=new KeyEventHandler(m_endogine_KeyEvent); }
private Form _startupForm; //TODO: shouldn't have such a thing, console startup rather... #endregion Fields #region Constructors public EndogineHub(string a_sApplicationPath) { m_sApplicationPath = a_sApplicationPath; m_pntMouseLoc = new EPoint(); m_endogine = this; AppSettings app = new AppSettings(); string s = AppSettings.Instance.GetNodeText("DisplayMode.Fullscreen"); if (s != null) m_bFullscreen = Convert.ToBoolean(s); s = AppSettings.Instance.GetNodeText("DisplayMode.Renderer"); if (s != null) this._renderStrategy = s; }