public static void RaiseEvent(this EventMarshalDel @event, IMyEventActions sender, MyEventArgs e) { if (@event != null) { @event(sender, e); } }