2015-03-25 27 views
1

我在Unity上使用vuforia SDK。當添加VirtualButton時,我看到了這個問題。爲什麼在unity/vuforia上找不到'IVirtualButtonEventHandle'?

Assets/VirtualButtonEventHandle.cs(4,56): error CS0246: The type or namespace name 'IVirtualButtonEventHandle' could not be found. Are you missing a using directive or an assembly reference?

VirtualButtonEventHandle.cs:

------------------ 
using UnityEngine; 
using System.Collections; 

public class VirtualButtonEventHandle : MonoBehaviour **IVirtualButtonEventHandle**{ 
--------------- 
+0

如果您通過單擊格式勾號標記發現它很有用,請標記答案。它將幫助其他人導航到相同的位置。謝謝。 – 2015-03-31 09:31:58

回答

0

那是因爲你在這個目錄中遺漏:

using System.Collections.Generic; 

我抓傷我的頭一個星期試圖找到相同。希望這可以幫助。 :)

+0

thanx爲您的答案。我不需要.generic目錄,因爲當我添加公共類VirtualButtonEventHandle時:MonoBehaviour,Vuforia.IVirtualButtonEventHandler {}它工作。 - 埃爾坎Semerci 50分鐘前 – 2015-03-26 08:25:47

+0

好吧,通用通常工作,所以如果你可以標記這個答案,它可能會幫助很多其他人。 – 2015-03-26 08:55:24

3

使用Vuforia; 解決了我的問題!