littleqi 发表于 2016-3-2 21:20

在unity文件夹下放入DLL文件会导致无法运行

问题描述:我在网上下载了一个类似于跑酷的游戏进行学习,我在他的scripts下创建一个plugins包 放入一些我所需要的DLL文件的时候,开始运行游戏会报错:
Unhandled Exception: System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.

at (wrapper managed-to-native) System.Reflection.Assembly:GetTypes (bool)

at System.Reflection.Assembly.GetTypes () in <filename unknown>:0

at Mono.CSharp.RootNamespace.ComputeNamespaces (System.Reflection.Assembly assembly, System.Type extensionType) in <filename unknown>:0

at Mono.CSharp.RootNamespace.ComputeNamespace (Mono.CSharp.CompilerContext ctx, System.Type extensionType) in <filename unknown>:0

at Mono.CSharp.GlobalRootNamespace.ComputeNamespaces (Mono.CSharp.CompilerContext ctx) in <filename unknown>:0

at Mono.CSharp.Driver.LoadReferences () in <filename unknown>:0

at Mono.CSharp.Driver.Compile () in <filename unknown>:0

at Mono.CSharp.Driver.Main (System.String[] args) in <filename unknown>:0

Missing method .ctor in assembly E:\uintyProject\running game\Assets\CaveRun3D Assets\Scripts\Microsoft.Kinect.dll, type System.Runtime.Versioning.TargetFrameworkAttribute
The class System.Runtime.Versioning.TargetFrameworkAttribute could not be loaded, used in Microsoft.Kinect
Can't find custom attr constructor image: E:\uintyProject\running game\Assets\CaveRun3D Assets\Scripts\Microsoft.Kinect.dll mtoken: 0x0a00017d

另外我删除了这些文件,和本身plugins这个文件夹,并且将这些DLL文件放在各种位置,还是依旧会收到这些错误提示,我该怎么办?

monery2 发表于 2016-3-2 21:28

不导入包会吗

littleqi 发表于 2016-3-4 14:11

monery2 发表于 2016-3-2 21:28 static/image/common/back.gif
不导入包会吗

没导入包之前不会,整个工程都是别人网上写好的可以运行的,下载下来也可以运行,我只是往里面放包就会报错

yaotaiye 发表于 2017-2-15 12:53

顶顶多好

me10001 发表于 2017-2-15 13:21

难得一见的好帖

juncolor 发表于 2017-2-15 12:57

很好哦

gaojinjin 发表于 2017-2-15 12:53

不错不错

hujie 发表于 2017-2-15 13:19

LZ真是人才

EIBEN 发表于 2017-2-18 14:23

好帖就是要顶

EIBEN 发表于 2017-2-18 14:11

真心顶
页: [1]
查看完整版本: 在unity文件夹下放入DLL文件会导致无法运行