JohnBaracuda / com.baracuda.runtime-monitoring

Runtime Monitoring is an easy way for you to monitor the value or state of custom C# members during runtime. Just add the 'Monitor' attribute to a field, property, event, method or even class and get its value or state displayed automatically in a customizable and extendable debug UI.
MIT License
408 stars 22 forks source link

Batchmode builds need better support #31

Open mwalk-dev opened 1 month ago

mwalk-dev commented 1 month ago

When doing a batchmode build I was getting tons of NREs from IL2CPPBuildPreprocessor line 29 because Monitor.Settings was null. I believe this is because in-editor, Monitor.Construct runs as a delayCall callback but the editor doesn't fire those callbacks in batchmode.

The workaround I'm using for now is to call Construct via reflection in my batchmode build script, but I think it should be a public method or the Monitor ctor should have an alternative approach for batchmode.