private void Start()
    {
        meshRender       = GetComponent <MeshRenderer>();
        originalMaterial = meshRender.material;

        holoTable = GetComponentInParent <HoloTable>();
    }
Example #2
0
    public void OnInteraction(GameObject other)
    {
        if (holoTable == null)
        {
            holoTable = GetComponentInParent <HoloTable>();
        }

        holoTable.SelectAttachPoint(this);
    }
Example #3
0
    public void OnInteraction(GameObject other)
    {
        if (!enabled)
        {
            return;
        }

        if (parentPoint != null)
        {
            parentPoint.gameObject.SetActive(true);
            HoloTable ht = GetComponentInParent <HoloTable>();
            ht.PartRemoved(this);
        }
        Destroy(gameObject);
    }