Exemplo n.º 1
0
    void Update()
    {
        if (riddleEntered)
        {
            if (timeSinceEnter.Get() >= timeForHint)
            {
                if (!DialogMessage.AnyMessageShown())
                {
                    if (hintMessage != null)
                    {
                        hintMessage.Show();
                    }
                    else
                    {
                        Debug.LogError("No hint given!", this);
                    }

                    Destroy(this);
                }
                else
                {
                    Debug.Log("Showing other Message");
                }
            }
        }
    }