【问题标题】:Unity VRTK asset errorUnity VRTK资产错误
【发布时间】:2018-07-04 07:04:48
【问题描述】:

我刚刚统一下载了VRTK v3.20 资产,但导入后我遇到了一些错误。网上好像没找到解决办法。

Unity版本:2018.1.6f1个人64位。

错误:

1.VRTK/Scripts/Interactions/Highlighters/VRTK_MaterialColorSwapHighlighte.cs(146,66):错误 CS1540:无法通过 UnityEngine.Texture 类型的限定符访问受保护的成员 UnityEngine.Texture.Texture()'。限定符必须是 `VRTK.Highlighters.VRTK_MaterialColorSwapHighlighter' 类型或派生自它

2.VRTK/Scripts/Interactions/Highlighters/VRTK_MaterialColorSwapHighlighte.cs(146,66): 错误 CS0122: `UnityEngine.Texture.Texture()' 由于其保护级别而无法访问

这是有错误的行:

renderer.material.SetTexture("_MainTex", new Texture());

【问题讨论】:

    标签: unity3d error-handling textures vrtk


    【解决方案1】:

    资产商店中的 VRTK 3.2.0 不支持 Unity 2018.1。您需要从 Github 页面获取 VRTK 3.3.0,使用 master 分支:

    https://github.com/thestonefox/VRTK

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2017-06-09
      • 1970-01-01
      • 1970-01-01
      • 2016-07-31
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多