// 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"
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);