Bugfix in AliPoints2Memory
[u/mrichter/AliRoot.git] / GEANT321 / ggeom / gsipar.F
1 *
2 * $Id$
3 *
4 * $Log$
5 * Revision 1.1.1.1  1999/05/18 15:55:17  fca
6 * AliRoot sources
7 *
8 * Revision 1.1.1.1  1995/10/24 10:20:56  cernlib
9 * Geant
10 *
11 *
12 #include "geant321/pilot.h"
13 *CMZ :  3.21/02 29/03/94  15.41.30  by  S.Giani
14 *-- Author :
15       SUBROUTINE GSIPAR(JVO,JIN,NPAR,NATT,PAR,ATT)
16 C.
17 C.    ******************************************************************
18 C.    *                                                                *
19 C.    *    ROUTINE TO SET INTERNAL PARAMETERS AND ATTRIBUTES.          *
20 C.    *                                                                *
21 C.    *    ==>Called by : GSDVN,GSDVN2,GSDVT,GSDVT2,GSVOLU             *
22 C.    *         Author  A.McPherson  *********                         *
23 C.    *                                                                *
24 C.    ******************************************************************
25 C.
26 #include "geant321/gcbank.inc"
27 #include "geant321/gcunit.inc"
28       DIMENSION PAR(100),ATT(20)
29 C.
30 C.              --------------------------------------------
31 C.
32       IF(NPAR.LT.0.OR.NPAR.GT.100) GO TO 900
33       IF(NATT.LE.0.OR.NATT.GT.20) GO TO 900
34 C
35       IF(JVO.LE.0) GO TO 910
36       IF(JIN.GT.0) GO TO 10
37 C
38       Q(JVO+5)=NPAR
39       Q(JVO+6)=NATT
40       JPAR=JVO+7
41       JATT=JVO+7+NPAR
42 C
43       GO TO 20
44    10 CONTINUE
45 C
46       JPAR=JIN+9
47       Q(JPAR)=NPAR
48       Q(JVO+5)=0
49       Q(JVO+6)=NATT
50       JPAR=JPAR+1
51       JATT=JVO+7
52 C
53    20 CONTINUE
54 C
55       CALL UCOPY(PAR,Q(JPAR),NPAR)
56       CALL UCOPY(ATT,Q(JATT),NATT)
57 C
58       GO TO 999
59   900 CONTINUE
60 C
61       WRITE(CHMAIL,1000) NPAR,NATT
62       CALL GMAIL(0,0)
63  1000 FORMAT(' **** ERROR IN GSIPAR - NPAR =',I12,' OR NATT =',I12,
64      +' OUT OF RANGE ****')
65 C
66       GO TO 999
67   910 CONTINUE
68 C
69       WRITE(CHMAIL,1010) JVO
70       CALL GMAIL(0,0)
71  1010 FORMAT(' **** ERROR IN GSIPAR - JVO =',I12,
72      +' LE 0. ****')
73 C
74   999 END