output file

This commit is contained in:
Jan Kieseler
2023-10-13 09:09:02 +02:00
parent 69cc376c5f
commit 381aa6ea91
9 changed files with 42 additions and 9 deletions
+4 -1
View File
@@ -19,6 +19,7 @@ void G4System::init(GeometryDescriptor &CW){
assigned_cw->unAssign();
}
assigned_cw = &CW;
CW.setG4System(this);//link both ways
char* argv[]={(char*)"dummy"};
@@ -156,7 +157,8 @@ void G4System::run_gui(){
}
}
void G4System::run_batch(int nEvents,const std::string& partSpecies, double minEnergy, double maxEnergy){
void G4System::run_batch(int nEvents,const std::string& partSpecies, double minEnergy,
double maxEnergy, std::string filename){
check();
@@ -165,6 +167,7 @@ void G4System::run_batch(int nEvents,const std::string& partSpecies, double minE
UImanager->ApplyCommand("/run/initialize");
UImanager->ApplyCommand("/vis/disable");
actionInitialization->setGeneratorProperties(minEnergy, maxEnergy, partSpec);
actionInitialization->setFileName(filename);
runManager->BeamOn(nEvents);
}