예제 #1
0
    public void OpenDoor()
    {
        if (IsLocked)
        {
            if (condition == Conditions.DemonSouls)
            {
                if (GameManager.Instance.DemonSoulsHarvested < amount)
                {
                    interactiveText.text = "You need " + amount + " Demon Souls to enter this door. You have " + GameManager.Instance.DemonSoulsHarvested + " currently.";
                    return;
                }
            }
        }
        GetComponent <BoxCollider>().enabled = false;

        LeftDoor.StartTween();
        RightDoor.StartTween();
        audioObject.PlaySoundEffect(doorOpeningSound);
    }