using UnityEngine;
using System.Collections;
using UnityEngine.UI;
public class Memes : MonoBehaviour {
public int Meme = 0;
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
GetComponent<Text> ().text = "Memes: "+Meme.ToString ();
}
}
Any Help?
using UnityEngine;
using System.Collections;
using UnityEngine.UI;
public class MPS : MonoBehaviour {
public int MemesPS = 0;
public Memes Meme;
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
GetComponent<Text> ().text = "MPS: "+MemesPS.ToString ();
MemesPS + Memes.Meme
}
}
Just restart unity, the problem will get resolved, Because when u import package some of the things require restart or it could be something like to rearrange the initialization.
Just solved by restarting unity…:))
Actually in my case it occurred because of changing color of button through color picker, and got this 2 annoying errors …