android-studio - 如何让我的 Game Maker Studio 2 项目在 Android 模拟器上正常运行?
问题描述
我一直在尝试在 android studio 的 android 模拟器上测试我的 gms2 项目。我首先设置了sdk,以这篇文章为指导 https://help.yoyogames.com/hc/en-us/articles/115001368727-Setting-Up-For-Android-or-Amazon-Fire 然后,我用本文: https ://help.yoyogames.com/hc/en-us/articles/115000270191-Android-Setting-Up-Virtual-Devices 设置虚拟安卓设备。这样做时我确实注意到的一件事是 HAXM 安装程序每次都失败,这就是我所看到的
For more details, please check the installation log: C:\Users\GRAHAM~1\AppData\Local\Temp\haxm_install-20210917_0928.log
Intel® HAXM installation failed. To install Intel® HAXM follow the instructions found at: https://github.com/intel/haxm/wiki/Installation-Instructions-on-Windows
Done
这可能是相关的,我不确定。但是后来,我进入 gms2 并按照文章中的所有内容进行操作,但是当我尝试运行该项目时,我得到了以下输出:
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
-----------------------------------------------------------------------------
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
-----------------------------------------------------------------------------
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
-----------------------------------------------------------------------------
EXCEPTION FILE - C:\Users\GRAHAMJT20\AppData\Local\Temp\a839beeab34845389c4d01131e83e7cd.yyg.saencryptedreport
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
EXCEPTION FILE - C:\Users\GRAHAMJT20\AppData\Local\Temp\02db8f82f77e49a5a8414617cce166e6.yyg.saencryptedreport
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
EXCEPTION FILE - C:\Users\GRAHAMJT20\AppData\Local\Temp\b040736233304be79cc6c2d2c53ad089.yyg.saencryptedreport
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
EXCEPTION FILE - C:\Users\GRAHAMJT20\AppData\Local\Temp\27f7125ae7a047debcc5b7463282ace9.yyg.saencryptedreport
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
EXCEPTION FILE - C:\Users\GRAHAMJT20\AppData\Local\Temp\ef897878cf614509afbba924f24b0806.yyg.saencryptedreport
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
EXCEPTION FILE - C:\Users\GRAHAMJT20\AppData\Local\Temp\bcd410e5ac854919bb7b9486c6f6866c.yyg.saencryptedreport
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
EXCEPTION FILE - C:\Users\GRAHAMJT20\AppData\Local\Temp\5f27bb810dc041b9b7b79c4c98eab7ed.yyg.saencryptedreport
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount)
at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount)
at System.Xml.XmlTextReaderImpl.ReadData()
at System.Xml.XmlTextReaderImpl.SwitchEncoding(Encoding newEncoding)
at System.Xml.XmlTextReaderImpl.ParseXmlDeclaration(Boolean isTextDecl)
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.Load(String filename)
at GMAssetCompiler.TexturePage.(String )
at GMAssetCompiler.TexturePage.(String , Boolean , Boolean , Boolean , Boolean , Int32 , String , String , String[] )
at GMAssetCompiler.WADSaver`1.<>c.(KeyValuePair`2 )
at GMAssetCompiler.Program..(Object )
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
老实说,这让我有点过头了。任何帮助使它工作将不胜感激。(如果需要,我可以提供更多错误输出,但放在这里太长了)
解决方案
推荐阅读
- php - 如何从 preg_match_all 获取密钥?
- git - 安装 git-recover 以从硬重置中恢复文件
- python - 如何将文本文件内容通过管道传输到另一个 python 程序的命令行参数
- java - 使用 ComponentResizer 时重叠组件
- amazon-web-services - ECS 集群未在两个 EC2 实例之间正确分配任务
- node.js - ExpressJS:如何有条件地开始会话?
- c - 需要帮助使用 -wall -pedantic -ansi 标志在 bash 终端上执行二进制文件
- excel - VBA检查包含特定文本的单元格的最短方法
- android - 为什么添加支持地图片段 xml 会减慢我的片段显示速度?
- javascript - 如何在 javaScript 中将 HTML 页面导出为 doc/docx 文件时将页面大小自定义为 A4 和行间距