UnityにアセットStandard Assetsを追加したら以下のエラーが出るようになりました。
Assets\Standard Assets\Utility\EventSystemChecker.cs(18,30): error CS0246: The type or namespace name 'StandaloneInputModule' could not be found (are you missing a using directive or an assembly reference?)
ネットで調べると、error CS0246は名前空間の定義忘れとのことですが、具体的にどうすればこのエラーを解決することができるのかが解りません。
ちなみにEventSystemChecker.csの内容は以下の通りです。
using System;
using System.Collections;
using UnityEngine;
using UnityEngine.EventSystems;
public class EventSystemChecker : MonoBehaviour
{
//public GameObject eventSystem;
// Use this for initialization void Awake () { if(!FindObjectOfType<EventSystem>()) { //Instantiate(eventSystem); GameObject obj = new GameObject("EventSystem"); obj.AddComponent<EventSystem>(); obj.AddComponent<StandaloneInputModule>().forceModuleActive = true; } }
}
解決策が解る方、どうかよろしくお願いします。(_ _)
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2019/08/15 16:44
2019/08/15 17:20
2019/08/15 17:58
2019/08/15 18:23