using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Extensions.Logging;
using ReallifeGamemode.Database.Models;
using ReallifeGamemode.Server.Core.API;
using ReallifeGamemode.Server.Log;

namespace ReallifeGamemode.Server.Core
{
  internal abstract class Script
  {
    protected IAPI Api => Main.API;

    protected ILogger Log { get; }

    protected Events.EventHandler EventHandler => Main.EventHandler;

    public Script()
    {
      Log = LogManager.GetLogger(GetType());
    }

    protected DatabaseContext GetDbContext() => Main.GetDbContext();
  }
}
