Пример #1
0
    // turn things on after 3 seconds
    public void PowerOn()
    {
        if (!working)
        {
            if (flashlight.GetStatus() == "Off")
            {
                StartCoroutine(Work());
                flashlight.WarmingUp();
            }

            if (tracker.GetStatus() == "Off")
            {
                StartCoroutine(Work());
                tracker.EnablingTracker();
            }

            if (radio.GetStatus() == "Off")
            {
                StartCoroutine(Work());
                radio.OpenConnection();
            }
        }
    }