From 625698825a887c76868a18b9762ae8ecd5994f2e Mon Sep 17 00:00:00 2001
From: Hugo Jacob <hugojacob57@gmail.com>
Date: Tue, 23 Jul 2024 17:04:23 +0200
Subject: [PATCH] Fixing mistake in merge

---
 NPLib/Detectors/Exogam/TExogamPhysics.cxx | 17 +++--------------
 1 file changed, 3 insertions(+), 14 deletions(-)

diff --git a/NPLib/Detectors/Exogam/TExogamPhysics.cxx b/NPLib/Detectors/Exogam/TExogamPhysics.cxx
index b0a24af1f..7b757c3e0 100644
--- a/NPLib/Detectors/Exogam/TExogamPhysics.cxx
+++ b/NPLib/Detectors/Exogam/TExogamPhysics.cxx
@@ -200,20 +200,9 @@ void TExogamPhysics::BuildPhysicalEvent() {
     Outer_AB.push_back(GetMaxOuter(Id_Max));
 
     if(MaxOuterId > -1){
-      double Theta_seg;
-      double Phi_seg;
-      if(m_flange.size()>0){
-        unsigned int index = MapFlangeToCloverNumber[flange_nbr];
-        if(index>0){
-          Theta_seg = m_pos_segment[crystal_nbr][MaxOuterId].at(index-1).Theta();
-          Phi_seg = m_pos_segment[crystal_nbr][MaxOuterId].at(index-1).Phi();
-        }
-      }
-      else{
-        Exogam_struc = Ask_For_Angles(flange_nbr, ComputeMeanFreePath(E_AddBack));
-        Theta_seg = Exogam_struc.Theta_Crystal_Seg[crystal_nbr][MaxOuterId];
-        Phi_seg = Exogam_struc.Phi_Crystal_Seg[crystal_nbr][MaxOuterId];
-      }
+      Exogam_struc = Ask_For_Angles(flange_nbr, ComputeMeanFreePath(E_AddBack),147,0.0); //147 default value of Emmanuel's code
+      double Theta_seg = Exogam_struc.Theta_Crystal_Seg[crystal_nbr][MaxOuterId];
+      double Phi_seg = Exogam_struc.Phi_Crystal_Seg[crystal_nbr][MaxOuterId];
 
       Theta.push_back(Theta_seg);
       Phi.push_back(Phi_seg);
-- 
GitLab