using System;
using StardewModdingAPI.Framework;
namespace StardewModdingAPI.Events
{
/// Events raised when something happens in the mines.
public static class MineEvents
{
/*********
** Events
*********/
/// Raised after the player warps to a new level of the mine.
public static event EventHandler MineLevelChanged;
/*********
** Internal methods
*********/
/// Raise a event.
/// Encapsulates monitoring and logging.
/// The previous mine level.
/// The current mine level.
internal static void InvokeMineLevelChanged(IMonitor monitor, int previousMineLevel, int currentMineLevel)
{
monitor.SafelyRaiseGenericEvent($"{nameof(MineEvents)}.{nameof(MineEvents.MineLevelChanged)}", MineEvents.MineLevelChanged?.GetInvocationList(), null, new EventArgsMineLevelChanged(previousMineLevel, currentMineLevel));
}
}
}