C#C
C#4mo ago
Olsson

Module initializer only running for one assembly

Hi,

I have source generator to generate compiled meta data about classes, to register these for a scripting layer in C++. These are stored as a module initializer, but the module initializer won't run when I load assembly

    [System.Runtime.CompilerServices.ModuleInitializer]
    public static void Register() => StartUpJobManager.RegisterStartUpJob(typeof(ManagedCropoutSampleProject.Interactable.FResourceInfo).Assembly.GetName().Name!, Initialize);
Was this page helpful?