]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - EVGEN/AliGenFLUKAsource.cxx
- LoadEvent with stack as argument.
[u/mrichter/AliRoot.git] / EVGEN / AliGenFLUKAsource.cxx
index 2e35f0bd8b87c5a5fe184be4bc2a11532b299e99..48de233cfd643dcb0357f886f72e4da2c9ee9e2f 100644 (file)
 // Files can be chained. 
 // Author: andreas.morsch@cern.ch
 
+#include <RVersion.h>
 #include "TPDGCode.h"
 #include "TDatabasePDG.h"
+#include <TVirtualMC.h>
 
 #include "AliGenFLUKAsource.h"
 #include "AliRun.h"
@@ -226,8 +228,11 @@ void AliGenFLUKAsource::Generate()
        part=kIfluge[int(ifip)-1];      
 //
 // Calculate momentum from kinetic energy and mass of the particle
+#if ROOT_VERSION_CODE > 197895
+        amass = gMC->ParticleMass(part);
+#else
        amass = (TDatabasePDG::Instance())->GetParticle(part)->Mass();
-
+#endif
        prwn=fEkin*sqrt(1. + 2.*amass/fEkin);
 
 
@@ -285,7 +290,7 @@ AliGenFLUKAsource& AliGenFLUKAsource::operator=(const  AliGenFLUKAsource& rhs)
 }
 
 
-void AliGenFLUKAsource::Copy(AliGenFLUKAsource &) const
+void AliGenFLUKAsource::Copy(TObject &) const
 {
     Fatal("Copy","Not implemented!\n");
 }