The key code is the GetTargetVolume
member function of the fpDetectorConstruction
class. It’s obviously returning nullptr
so that’s the thing to investigate. Please also review How to post code snippets as screenshots aren’t so good for discussing problems like this.