BUG解决Button类不能从UnityEngine.UI中引用

'Button' does not contain a definition for 'onClick' and no accessible extension method 'onClick' accepting a first argument of type 'Button' could be found (are you missing a using directive or an assembly reference?)

 

一个非常奇葩的问题;突然!!!!!

using UnityEngine.UI;引用不了,灰色提示!

BUG解决Button类不能从UnityEngine.UI中引用_第1张图片

BUG解决Button类不能从UnityEngine.UI中引用_第2张图片

 

然后 Button类不管怎么都不能从UnityEngine.UI中引用,气炸!!!

人家的Button类都是继承自UnityEngine.UI

BUG解决Button类不能从UnityEngine.UI中引用_第3张图片

 

仔细对工程包含的所有插件排查了一遍!!都没有问题!

网上查了各种教程,什么修改 .Net框架。。。。。

 

最终原因&#

你可能感兴趣的:(Unity3D,BUG解决,bug,unity)