比如我进游戏后设置里开上了DP,然后点开始游戏,选择190剧本,然后选择势力,然后点踏上征途,最后进游戏时就会崩溃,黑屏左上角写着“不好意思XXXX”。我搜了一下说是要先进设置开DP,然后退出游戏,然后再进就行了,可是再进游戏后打开设置一看又变回原版了,还有屏幕分辨率、语言等设置也是,退出游戏后再进游戏设置根本没有保存。
这是什么原因造成的呀,我打开看了一下crashLog里面好像没说啥有用的,Object reference not set to an instance of an object.
=================== StackTrace ==================
at GameObjects.GameScenario.SaveGameScenario(String LoadedFileName, Boolean saveMap, Boolean saveCommonData, Boolean saveSettings, Boolean disposeMemory, Boolean fullPathProvided, Boolean editing)
at WorldOfTheThreeKingdoms.GameScreens.MainGameScreen.SaveGameToDisk(String LoadedFileName)
at WorldOfTheThreeKingdoms.MainGame.Update(GameTime gameTime)
at Microsoft.Xna.Framework.Game.DoUpdate(GameTime gameTime)
at Microsoft.Xna.Framework.Game.Tick()
at MonoGame.Framework.WinFormsGameWindow.TickOnIdle(Object sender, EventArgs e)
at System.Windows.Forms.Application.ThreadContext.System.Windows.Forms.UnsafeNativeMethods.IMsoComponent.FDoIdle(Int32 grfidlef)
at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
at MonoGame.Framework.WinFormsGameWindow.RunLoop()
at Microsoft.Xna.Framework.Game.Run(GameRunBehavior runBehavior)
at WorldOfTheThreeKingdoms.Program.Main()
这是什么原因造成的呀,我打开看了一下crashLog里面好像没说啥有用的,Object reference not set to an instance of an object.
=================== StackTrace ==================
at GameObjects.GameScenario.SaveGameScenario(String LoadedFileName, Boolean saveMap, Boolean saveCommonData, Boolean saveSettings, Boolean disposeMemory, Boolean fullPathProvided, Boolean editing)
at WorldOfTheThreeKingdoms.GameScreens.MainGameScreen.SaveGameToDisk(String LoadedFileName)
at WorldOfTheThreeKingdoms.MainGame.Update(GameTime gameTime)
at Microsoft.Xna.Framework.Game.DoUpdate(GameTime gameTime)
at Microsoft.Xna.Framework.Game.Tick()
at MonoGame.Framework.WinFormsGameWindow.TickOnIdle(Object sender, EventArgs e)
at System.Windows.Forms.Application.ThreadContext.System.Windows.Forms.UnsafeNativeMethods.IMsoComponent.FDoIdle(Int32 grfidlef)
at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
at MonoGame.Framework.WinFormsGameWindow.RunLoop()
at Microsoft.Xna.Framework.Game.Run(GameRunBehavior runBehavior)
at WorldOfTheThreeKingdoms.Program.Main()