【发布时间】:2013-10-17 05:57:20
【问题描述】:
当我将 Demo.cs 放在标准资产文件夹中时,我收到此错误:
Assets/Standard Assets/Demo.cs(130,17): error CS0246: The type or namespace name 'UILabel' could not be found. Are you missing a using directive or an assembly reference?
当我将 Demo.cs 资产文件夹放在上面时,错误得到解决 但我不能从我的另一个 Demo1.js 调用任何 Demo.cs 方法
给出错误:Assets/Scripts/Demo1.js(81,20): BCE0018: The name 'Demo' does not denote a valid type ('not found').
有什么办法吗?
【问题讨论】:
-
我认为 UILabel 是 NGUI 框架的一部分。如果您使用的是 NGUI,您应该将其文件移到标准资源中,或者将 Demo.cs 从标准资源中移出。
-
已解决复制标准资产中的所有 NGUI 内容,除了我保留在资产中的一个文件夹“编辑器”
标签: c# unity3d unityscript ngui