fixed an issue where types would not correctly be loaded from referenced assemblies

This commit is contained in:
Ell 2020-10-07 04:01:10 +02:00
parent a7d5a12df1
commit a5ba3de533
5 changed files with 22 additions and 3 deletions

View file

@ -2,7 +2,7 @@
<package> <package>
<metadata> <metadata>
<id>Contentless</id> <id>Contentless</id>
<version>3.0.0</version> <version>3.0.1</version>
<authors>Ellpeck</authors> <authors>Ellpeck</authors>
<description>A tool for MonoGame that automatically handles adding assets to the Content Pipeline project</description> <description>A tool for MonoGame that automatically handles adding assets to the Content Pipeline project</description>
<tags>monogame mono xna content pipeline mgcb builder tool library</tags> <tags>monogame mono xna content pipeline mgcb builder tool library</tags>

View file

@ -12,5 +12,9 @@ namespace Contentless {
this.Type = type; this.Type = type;
} }
public override string ToString() {
return this.Type.Name;
}
} }
} }

View file

@ -149,7 +149,7 @@ namespace Contentless {
var processors = new List<string>(); var processors = new List<string>();
foreach (var assembly in AppDomain.CurrentDomain.GetAssemblies()) { foreach (var assembly in AppDomain.CurrentDomain.GetAssemblies()) {
try { try {
foreach (var type in assembly.GetExportedTypes()) { foreach (var type in assembly.GetTypes()) {
var importer = (ContentImporterAttribute) type.GetCustomAttribute(typeof(ContentImporterAttribute), true); var importer = (ContentImporterAttribute) type.GetCustomAttribute(typeof(ContentImporterAttribute), true);
if (importer != null) if (importer != null)
importers.Add(new ImporterInfo(importer, type)); importers.Add(new ImporterInfo(importer, type));

@ -1 +1 @@
Subproject commit 97708388e9adf6cb2ff66171ed0be5d4183e6b63 Subproject commit 133ef7c79d1e13152c543986e4335b6e01740ec4

View file

@ -45,3 +45,18 @@
/processor:TextureProcessor /processor:TextureProcessor
/build:Textures/Exclude.png /build:Textures/Exclude.png
#begin Json/Test.json
/importer:TexturePackerJsonImporter
/processor:TexturePackerProcessor
/build:Json/Test.json
#begin Tiled/Map.tmx
/importer:TiledMapImporter
/processor:TiledMapProcessor
/build:Tiled/Map.tmx
#begin Tiled/Tileset.tsx
/importer:TiledMapTilesetImporter
/processor:TiledMapTilesetProcessor
/build:Tiled/Tileset.tsx