Ejemplo n.º 1
0
    void Start()
    {
        pointLight = GetComponent<Light>();
        startColor = pointLight.color;

        anchorManager = ImportExportAnchorManager.Instance;
    }
Ejemplo n.º 2
0
    void Start()
    {
        pointLight = GetComponent <Light>();
        startColor = pointLight.color;

        anchorManager = ImportExportAnchorManager.Instance;
    }
Ejemplo n.º 3
0
    // Update is called once per frame
    void Update()
    {
        WorldAnchor anchor = null;
        ImportExportAnchorManager anchorMgr = null;

        if (manager != null)
        {
            anchor    = manager.GetComponent <WorldAnchor>();
            anchorMgr = manager.GetComponent <ImportExportAnchorManager>();
        }
        if (anchor == null)
        {
            anchorPos.text = "Anchor is null";
        }
        else if (!anchor.isLocated)
        {
            anchorPos.text = "Anchor is NOT located";
        }
        else
        {
            anchorPos.text = "AnchorPos : " + manager.transform.position;
        }

        anchorState.text = "State : " + anchorMgr.StateName;

        joinCount.text = "Joined Count : " + anchorMgr.join_count;

        //if (anchorMgr.StateName.Equals("Ready"))
        //gameObject.SetActive(false);
        //Health.text = "Health: " + Player.Instance.getHealth();
    }
Ejemplo n.º 4
0
    // Use this for initialization
    void Start()
    {
        color = Color.white;

        anchorManager = ImportExportAnchorManager.Instance;

        circles = new List <GameObject>();
        foreach (Transform child in transform)
        {
            circles.Add(child.gameObject);
            float   deg      = (float)(360 / 8 * circles.Count);
            float   rad      = Mathf.Deg2Rad * deg;
            Vector3 position = child.position;
            position.x     = Mathf.Sin(rad) * CIRCLE_SIZE;
            position.y     = Mathf.Cos(rad) * CIRCLE_SIZE;
            child.position = position;
            RawImage rawImage = child.Find("RawImage").GetComponent <RawImage>();
            Color    color    = rawImage.color;
            color.a        = DEFAULT_ALPHA;
            rawImage.color = color;
        }
    }