static void Initialize() { m_GameWindow = new GameWindow(); m_GameWindow.ClientSize = m_Resolution; InitializeGraphics(); InitializeInput(); InitializeSound(); m_GameWindow.Show(); }
public virtual void Dispose() { foreach(Engine_Picture picture in m_Pictures) picture.Dispose(); m_Pictures.Clear(); foreach(Engine_Font font in m_Fonts) font.Dispose(); m_Fonts.Clear(); foreach(Engine_Sound sound in m_Sounds) sound.Dispose(); m_Sounds.Clear(); foreach (Engine_Music music in m_Music) music.Dispose(); m_Music.Clear(); dIDevice.Dispose(); dIDevice = null; // Kommenter ut disse 2 linjer under "dsDevice..." om du ikke har lydkort dsDevice.Dispose(); dsDevice = null; DXSprite.Dispose(); DXSprite = null; dGDevice.Dispose(); dGDevice = null; m_GameWindow.Dispose(); m_GameWindow = null; m_Disposed = true; }