Assets/Scripts/Game.cs(13,30): error CS1061: Type `UnityEngine.GameObject' does not contain a definition for `ActiveSelf' and no extension method `ActiveSelf' of type `UnityEngine.GameObject' could be found. Are you missing an assembly reference?
using UnityEngine.UI; using UnityEngine; public class Game : MonoBehaviour { public Text scoreText; public GameObject ShopPan; private int score; public void ShopPan_ShowAndHide() { ShopPan.SetActive(!ShopPan.ActiveSelf); } public void OnClick() { score++; scoreText.text = score + "$"; } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)