diff --git a/src/ffi_ZDC.cpp b/src/ffi_ZDC.cpp index 82ce4481a769f88cc761b0f6efbc1d1fa997b5cb..1c20198ad6c344567da9817d21e0cb7bb61c418f 100644 --- a/src/ffi_ZDC.cpp +++ b/src/ffi_ZDC.cpp @@ -24,6 +24,8 @@ static Ref_t createDetector(Detector& desc, xml_h e, SensitiveDetector sens) // Create Global Volume Box ffi_ZDC_GVol_Solid(Width * 0.5, Width * 0.5, Thickness * 0.5); Volume detVol("ffi_ZDC_GVol_Logic", ffi_ZDC_GVol_Solid, Vacuum); + detVol.setSensitiveDetector(sens); + sens.setType("calorimeter"); detVol.setVisAttributes(desc.visAttributes(x_det.visStr())); @@ -31,6 +33,7 @@ static Ref_t createDetector(Detector& desc, xml_h e, SensitiveDetector sens) Volume motherVol = desc.pickMotherVolume(det); Transform3D tr(RotationZYX(rot.z(), rot.y(), rot.x()), Position(pos.x(), pos.y(), pos.z())); PlacedVolume detPV = motherVol.placeVolume(detVol, tr); + detPV.addPhysVolID("system", detID).addPhysVolID("module",0); det.setPlacement(detPV); return det; }