]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STEER/AliLegoGenerator.cxx
Fix fixed-string length bug
[u/mrichter/AliRoot.git] / STEER / AliLegoGenerator.cxx
index 41e2d4ee717b1de086a0f8954a9aa80b68bcd0e8..e6ba5e14b94ad6abf2581e88c77c429d416ac09d 100644 (file)
  * provided "as is" without express or implied warranty.                  *
  **************************************************************************/
 
-/*
-$Log$
-Revision 1.5  2001/05/16 14:57:22  alibrary
-New files for folders and Stack
+/* $Id$ */
 
-Revision 1.4  2000/11/30 07:12:49  alibrary
-Introducing new Rndm and QA classes
-
-Revision 1.3  2000/10/26 14:15:54  morsch
-- Base class now
-- Change from theta, phi to general coordinates Coor1, Coor2
-- PropagateCylinder: bug in calculation of distance to limiting radius corrected.
-
-Revision 1.2  2000/07/13 16:19:09  fca
-Mainly coding conventions + some small bug fixes
-
-Revision 1.1  2000/07/12 08:56:25  fca
-Coding convention correction and warning removal
-
-Revision 1.16  2000/05/26 08:35:03  fca
-Move the check on z after z has been retrieved
-
-Revision 1.15  2000/05/16 13:10:40  fca
-New method IsNewTrack and fix for a problem in Father-Daughter relations
-
-Revision 1.14  2000/04/27 10:38:21  fca
-Correct termination of Lego Run and introduce Lego getter in AliRun
-
-Revision 1.13  2000/04/26 10:17:31  fca
-Changes in Lego for G4 compatibility
-
-Revision 1.12  2000/04/07 11:12:33  fca
-G4 compatibility changes
-
-Revision 1.11  2000/03/22 13:42:26  fca
-SetGenerator does not replace an existing generator, ResetGenerator does
-
-Revision 1.10  2000/02/23 16:25:22  fca
-AliVMC and AliGeant3 classes introduced
-ReadEuclid moved from AliRun to AliModule
-
-Revision 1.9  1999/12/03 10:54:01  fca
-Fix lego summary
-
-Revision 1.8  1999/10/01 09:54:33  fca
-Correct logics for Lego StepManager
-
-Revision 1.7  1999/09/29 09:24:29  fca
-Introduction of the Copyright and cvs Log
-*/
+//------------------------------------------------------------------------
+//        Generic Lego generator code
+//    Uses geantino rays to check the material distributions and detector's
+//    geometry
+//    Author: A.Morsch
+//------------------------------------------------------------------------
 
 #include "AliLegoGenerator.h"
 #include "AliRun.h"
+#include "AliMC.h"
+#include "AliLog.h"
 
 ClassImp(AliLegoGenerator)
 
@@ -135,11 +95,11 @@ void AliLegoGenerator::Generate()
    // Prepare for next step
    if(fCoor1Bin>=fNCoor1-1)
      if(fCoor2Bin>=fNCoor2-1) {
-       Warning("Generate","End of Lego Generation");
+       AliWarning("End of Lego Generation");
        return;
      } else { 
        fCoor2Bin++;
-       printf("Generating rays in phi bin:%d\n",fCoor2Bin);
+       AliDebug(1, Form("Generating rays in phi bin:%d",fCoor2Bin));
        fCoor1Bin=0;
      } else fCoor1Bin++;
 
@@ -167,7 +127,7 @@ void AliLegoGenerator::Generate()
    
    Float_t polar[3]={0.,0.,0.};
    Int_t ntr;
-   gAlice->SetTrack(1, -1, kMpart, pmom, orig, polar, 0, kPPrimary, ntr);
+   gAlice->GetMCApp()->PushTrack(1, -1, kMpart, pmom, orig, polar, 0, kPPrimary, ntr);
    
 }