Пример #1
0
    void OnTriggerEnter(Collider other)
    {
        ProjectileHandler projHandler = other.transform.root.GetComponent <ProjectileHandler>();

        if (projHandler != null)
        {
            projHandler.GetComponent <SimpleMotor3D>().desiredDirec *= -1.0f;
            //Debug.Log(projHandler.GetComponent<SimpleMotor3D>().desiredDirec);
        }
    }