MonoGame / MonoGame

One framework for creating powerful cross-platform games.
http://www.monogame.net
Other
11.32k stars 2.9k forks source link

Could not find ContentTypeReader Type. Please ensure the name of the Assembly that contains the Type matches the assembly in the full type name: #7534

Closed V8275 closed 9 months ago

V8275 commented 3 years ago

I don't understand why this error appears when i add a model .dae

Microsoft.Xna.Framework.Content.ContentLoadException: "Could not find ContentTypeReader Type. Please ensure the name of the Assembly that contains the Type matches the assembly in the full type name: Microsoft.Xna.Framework.Content.ReflectiveReader1[[Microsoft.Xna.Framework.Content.Pipeline.Graphics.MaterialContent, MonoGame.Framework.Content.Pipeline, Version=3.8.0.1641, Culture=neutral, PublicKeyToken=null]] (Microsoft.Xna.Framework.Content.ReflectiveReader1[[Microsoft.Xna.Framework.Content.Pipeline.Graphics.MaterialContent, MonoGame.Framework.Content.Pipeline]])"

What version of MonoGame does the bug occur on:

What operating system are you using:

What MonoGame platform are you using:

mrhelmut commented 3 years ago

Do you happen to have enabled .NET trimming?

V8275 commented 3 years ago

Do you happen to have enabled .NET trimming?

How can I check this?

akghasemi commented 1 year ago

I had the same issue with 3.8.1 , and I disabled .NET trimming and it worked, should it be disabled in monogame?

Ragath commented 1 year ago

I had the same issue with 3.8.1 , and I disabled .NET trimming and it worked, should it be disabled in monogame?

no you just need to tell it not to trim types you're actually using, like the readers. https://devblogs.microsoft.com/dotnet/customizing-trimming-in-net-core-5/

mrhelmut commented 9 months ago

Duplicate of #8104