Esempio n. 1
0
#pragma warning  restore 0649

    void Start()
    {
        hook = GetComponent <TugbotHookComponent>();
        foreach (var sc in sideCams)
        {
            sc.enabled = true;
        }
    }
    private void OnTriggerStay(Collider other)
    {
        if (other.transform.root.tag == "Player")
        {
            tugbotHookC = other.transform.root.GetComponent <TugbotHookComponent>();

            if (tugbotHookC != null && tugbotHookC.IsHooked)
            {
                GetComponentInParent <PaletteComponent>().AttachToTugBot(transform.localPosition, other.transform.root.GetComponent <Rigidbody>());
            }
        }
    }
Esempio n. 3
0
 void Start()
 {
     hook = GetComponent <TugbotHookComponent>();
     initialMainTransformPos = transform.position;
     initialMainTransformRot = transform.rotation;
 }