Goal Description
Add the Attacker interface to events or change Player to Target.
Since there's no interface, I can't subscribe to multiple events with the same method.
For some reason, events with both Attacker and Player only have the IPlayer interface.
For example: DeathEventArgs, TeleportedEventArgs, and etc.
Example:
//PlayerEvents.DeathEventArgs and Scp106Events.TeleportedEventArgs
private void HealScpOnAttck<T>(T ev) where T : IAttackerEvent
{
if (ev.Attacker != null && Plugin.ScpHeal.TryGetValue(ev.Attacker.Role, out ushort heal))
ev.Attacker.Heal(heal);
}
Notes
No response