@throbax wrote:
Hi!
I just noticed the other day, that when installing the latest dev-build (3.7.0.1232) you get a crash when deploying to the Android-emulator IF and only if you're using a game-asset of some kind (texture and spriteFont tested).
For details see below.History...
From gitter
Heya all! I just tried an Android project and everything works fine (VS2017, MG develop build from yesterday), except when I want to load an asset (SpriteFont in my case). The asset is not found on the emulator (and I get poor debugger support, but that was to be expected ).
I put the asset file in the content folder, added it to the pipeline-file using the GUI and built the game.
Did I miss something?OK. Trying with a texture...
Nope. Same problem with a texture. Program on emulator just stops.Stacktrace: 01-27 21:46:15.475 E/mono-rt ( 1432): 01-27 21:46:15.475 E/mono-rt ( 1432): at <unknown> <0xffffffff> 01-27 21:46:15.475 E/mono-rt ( 1432): at (wrapper managed-to-native) object.wrapper_native_0xb71ade40 (MonoGame.OpenGL.TextureTarget,int) <0x00012> 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Graphics.Texture2D.GenerateGLTextureIfRequired () [0x0005b] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Graphics.Texture2D/<>c__DisplayClass1.<PlatformConstruct>b__0 () [0x00006] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Threading.BlockOnUIThread (System.Action) [0x0002d] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Graphics.Texture2D.PlatformConstruct (int,int,bool,Microsoft.Xna.Framework.Graphics.SurfaceFormat,Microsoft.Xna.Framework.Graphics.Texture2D/SurfaceType,bool) [0x00064] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Graphics.Texture2D..ctor (Microsoft.Xna.Framework.Graphics.GraphicsDevice,int,int,bool,Microsoft.Xna.Framework.Graphics.SurfaceFormat,Microsoft.Xna.Framework.Graphics.Texture2D/SurfaceType,bool,int) [0x000ca] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Graphics.Texture2D..ctor (Microsoft.Xna.Framework.Graphics.GraphicsDevice,int,int,bool,Microsoft.Xna.Framework.Graphics.SurfaceFormat) [0x0000b] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Content.Texture2DReader.Read (Microsoft.Xna.Framework.Content.ContentReader,Microsoft.Xna.Framework.Graphics.Texture2D) [0x001a6] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Content.ContentTypeReader`1<T_REF>.Read (Microsoft.Xna.Framework.Content.ContentReader,object) [0x0000e] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Content.ContentReader.InnerReadObject<T_REF> (T_REF) [0x00035] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Content.ContentReader.ReadObject<T_REF> () [0x0000a] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Content.ContentReader.ReadAsset<T_REF> () [0x00007] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Content.ContentManager.ReadAsset<T_REF> (string,System.Action`1<System.IDisposable>) [0x00082] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at Microsoft.Xna.Framework.Content.ContentManager.Load<T_REF> (string) [0x0005d] in <c10a9ffa751749f5868c676ed8ffd98d>:0 01-27 21:46:15.475 E/mono-rt ( 1432): at TestAndroid.Game1.LoadContent () [0x00012] in C:\Source\InputStateManager\TestAndroid\Game1.cs:41
Seems like the texture couldn't be allocated?!?
OK. Just re-installed MG 3.6 (as just posted) and re-created an Android project. Works now. Texture is exported & shown. No problem now.
Re-installing MG 3.7 and re-trying...Re-installed MG 3.7.0.1232 (always + templates for VS), created new Android project. Added Spritefont and loaded it -> same crash as before.
Running old (MG 3.6 - created) project now that MG 3.7 is installed. Still works. Seems to be something in the templates.
No. It's not. The pipeline wasn't triggered after installing MG 3.7 because no asset changed.It's about the pipeline alright. Triggered a rebuild by deleting the bin and object folder and it doesn't work.
Project created with 3.6 template, built with 3.7 pipeline.
Posts: 4
Participants: 1