using UnityEngine;
using System.Collections;
using Framework.Entities;
using Framework.InteractionSystem;

public class PapaLogic : CoreBehaviour
{
    protected override void InnerAwake()
    {
        AddGlobalActionHandler<DayDirector.NewDayAction>(this, NewDay);
    }

    protected override void InnerUpdate()
    {

    }

    void OnDestroy()
    {
        ActionMediatorLocator.Get().Unsubscribe<DayDirector.NewDayAction>(this);
    }

    private void NewDay(DayDirector.NewDayAction action)
    {
        if (GameObject.Find("Ivy") == null)
        {
            GetComponent<PersonResponsive>().dialogFile = "PapaNoIvyDialogs";
        }
    }
}
