using UnityEngine;
using System.Collections;

public class MenuScript : MonoBehaviour {

    [SerializeField]
    GameObject game;

    [SerializeField]
    GameObject part;

    [SerializeField]
    GameObject dialogue;

    [SerializeField]
    GameObject[] speech;

    [SerializeField]
    GameObject texti;

    [SerializeField]
    Combat combat;

    [SerializeField]
    Sotry story;

    [SerializeField]
    GameObject[] text;


    int plis = 0;

    void Start()
    {
        plis = 0;
        SoundManager.Instance.PlaySound(0);
    }

    public void PressStart()
    {
        gameObject.SetActive(false);
        dialogue.SetActive(true);
        SoundManager.Instance.PlaySound(5);
    }


    public void PressNext()
    {
        if (plis == 0)
        {
            text[0].SetActive(false);
            text[1].SetActive(true);
        }
        else if (plis == 1)
        {
            text[1].SetActive(false);
            text[2].SetActive(true);
        }
        else if (plis == 2)
        {
            story.Prorgress();
            dialogue.SetActive(false);
            game.SetActive(true);
            part.SetActive(false);
        }

        plis++;
    }

    public void JiaAkka()
    {
        speech[0].SetActive(false);
        texti.SetActive(false);
        combat.CombatStart();
    }

    public void Kappa()
    {
        speech[1].SetActive(false);
        texti.SetActive(false);
        combat.CombatStart();
    }

    public void KillItWithFire()
    {
        speech[2].SetActive(false);
        texti.SetActive(false);
        combat.CombatStart();
    }

    public void Left()
    {
        combat.Left();
    }

    public void Right()
    {
        combat.Right();
    }
}
