Пример #1
0
    void Start()
    {
        timeIndex = 0;

        pos   = Camera.main.WorldToScreenPoint(transform.position);
        pos.x = pos.x / Screen.width;
        pos.y = (pos.y / Screen.height) + 0.010f;


        gt1 = GUIText.Instantiate(gt0, pos, Quaternion.identity) as GUIText;

        stringToEdit = arrTime [timeIndex];
        Debug.Log("|-o-| " + gameObject.name + "pos " + pos + " tf: " + transform.position);
    }
Пример #2
0
    // Use this for initialization
    void Start()
    {
        pauseState = 0;

        quit       = (GUIText.Instantiate(quitPrefab) as GUIText);
        background = (GUITexture.Instantiate(backgroundPrefab) as GUITexture);

        quit.GetComponent <Collider>().enabled = false;


        quitColor = quit.color;
        bgColor   = background.color;

        quitColor.a      = 0;
        bgColor.a        = 0;
        quit.color       = quitColor;
        background.color = bgColor;
    }