using System;
using System.Collections.Generic;
using System.Text;
using ReallifeGamemode.Server.Core.API;

namespace ReallifeGamemode.Server.Core.RageMP
{
  public class RageColShape : RageEntity, IColShape
  {
    private GTANetworkAPI.ColShape colShape;

    public RageColShape(GTANetworkAPI.ColShape colShape) : base(colShape)
    {
      this.colShape = colShape;

      this.colShape.OnEntityEnterColShape += (c, p) => OnEntityEnter?.Invoke(this, new RagePlayer(p));
      this.colShape.OnEntityExitColShape += (c, p) => OnEntityExit?.Invoke(this, new RagePlayer(p));
    }

    public event IColShape.ColShapeEvent OnEntityEnter;
    public event IColShape.ColShapeEvent OnEntityExit;
  }
}
