Dont know what im doing wrong. As simpe as that:
using UnityEngine;
using UnityEngine.UI;
public static class APPS {
public static bool Hola = true;
public static GameObject CREATE(string direction)
{
GameObject button = new GameObject();
button.AddComponent();
button.AddComponent();
var panel = GameObject.Find(“CommandPanel”);
button.transform.position = panel.transform.position;
button.GetComponent().SetParent(panel.transform);
button.GetComponent().SetInsetAndSizeFromParentEdge(RectTransform.Edge.Left,0,10);
button.SetActive(true);
button.layer = 5;
return button;
}
}
And from any other code or script its impossible to acces APPS.CREATE() or APPS.Hola.
What im doing worng?
Thank you