; FEVF - FERROVIA ELETTRICA VALLE DI FIEMME
; by Roberto Benini - robertobenini@libero.it
; (C) 06/12/2005
; in caso di utilizzo citare fonte


; debiti: la struttura della carrozza e i carrelli  sono derivati dalla C53.CSV 
; di Luigi Cartello e Sergio Usai per la FGC
; la texture del tetto, con alcune modifiche, proviene da BKLB di Peter Shotz

; Rimorchiata C101-C102-C103
; anno costruzione: 1929
; lunghezza 15,1 m
; interperno carrelli 9,4 m
; passo carrelli 2,2 m
; posti a sedere 52
 
 ; - - - - - - tetto vagone
CreateMeshBuilder ;  parte centrale
AddVertex, -1.22  , 3.27 , 6.85
AddVertex, -1.22  , 3.27 ,-6.85
AddVertex, -1.15  , 3.40 , 6.85
AddVertex, -1.15  , 3.40 ,-6.85
AddVertex, -1.05  , 3.50 , 6.85
AddVertex, -1.05  , 3.50 ,-6.85
AddVertex, -0.60  , 3.57 , 6.85
AddVertex, -0.60  , 3.57 ,-6.85
AddVertex,  0.00  , 3.60 , 6.85
AddVertex,  0.00  , 3.60 ,-6.85
AddVertex,  0.60  , 3.57 , 6.85
AddVertex,  0.60  , 3.57 ,-6.85
AddVertex,  1.05  , 3.50 , 6.85
AddVertex,  1.05  , 3.50 ,-6.85
AddVertex,  1.15  , 3.40 , 6.85
AddVertex,  1.15  , 3.40 ,-6.85
AddVertex,  1.22  , 3.27 , 6.85
AddVertex,  1.22  , 3.27 ,-6.85
AddFace2, 2, 3, 1, 0
AddFace2, 4, 5, 3, 2
AddFace2, 6, 7, 5, 4
AddFace2, 8, 9, 7, 6
AddFace2,10,11, 9, 8
AddFace2,12,13,11,10
AddFace2,14,15,13,12
AddFace2,16,17,15,14
GenerateNormals
LoadTexture, tetto_chiaro.bmp
SetTextureCoordinates,0,0,0
SetTextureCoordinates,1,0 ,1
SetTextureCoordinates,2,0.0286,0.06
SetTextureCoordinates,3,0.0286,0.94
SetTextureCoordinates,4,0.0696,0.06
SetTextureCoordinates,5,0.0696,0.94
SetTextureCoordinates,6,0.2540,0.06
SetTextureCoordinates,7,0.2540,0.94
SetTextureCoordinates,8,0.50,0.06
SetTextureCoordinates,9,0.50,0.94
SetTextureCoordinates,10,0.746,0.06
SetTextureCoordinates,11,0.746,0.94
SetTextureCoordinates,12,0.9304,0.06
SetTextureCoordinates,13,0.9304,0.94
SetTextureCoordinates,14,0.9714,0.06
SetTextureCoordinates,15,0.9714,0.94
SetTextureCoordinates,16,1,0.06
SetTextureCoordinates,17,1,0.94
CreateMeshBuilder ;  parte anteriore
AddVertex, -1.22  , 3.27 ,-6.85
AddVertex, -1.12  , 3.27 ,-7.85
AddVertex, -1.15  , 3.40 ,-6.85
AddVertex, -1.12  , 3.28 ,-7.85
AddVertex, -1.05  , 3.50 ,-6.85
AddVertex, -1.05  , 3.38 ,-7.85
AddVertex, -0.60  , 3.57 ,-6.85
AddVertex, -0.60  , 3.50 ,-7.85
AddVertex,  0.00  , 3.60 ,-6.85
AddVertex,  0.00  , 3.53 ,-7.85
AddVertex,  0.60  , 3.57 ,-6.85
AddVertex,  0.60  , 3.50 ,-7.85
AddVertex,  1.05  , 3.50 ,-6.85
AddVertex,  1.05  , 3.38 ,-7.85
AddVertex,  1.15  , 3.40 ,-6.85
AddVertex,  1.12  , 3.28 ,-7.85
AddVertex,  1.22  , 3.27 ,-6.85
AddVertex,  1.12  , 3.27 ,-7.85
AddFace2, 2, 3, 1, 0
AddFace2, 4, 5, 3, 2
AddFace2, 6, 7, 5, 4
AddFace2, 8, 9, 7, 6
AddFace2,10,11, 9, 8
AddFace2,12,13,11,10
AddFace2,14,15,13,12
AddFace2,16,17,15,14
GenerateNormals
LoadTexture, tetto_chiaro.bmp
SetTextureCoordinates,0,0,0.94
SetTextureCoordinates,1,0 ,1
SetTextureCoordinates,2,0.0286,0.94
SetTextureCoordinates,3,0.0286,1
SetTextureCoordinates,4,0.0696,0.94
SetTextureCoordinates,5,0.0696,1
SetTextureCoordinates,6,0.2540,0.94
SetTextureCoordinates,7,0.2540,1
SetTextureCoordinates,8,0.50,0.94
SetTextureCoordinates,9,0.50,1
SetTextureCoordinates,10,0.746,0.94
SetTextureCoordinates,11,0.746,1
SetTextureCoordinates,12,0.9304,0.94
SetTextureCoordinates,13,0.9304,1
SetTextureCoordinates,14,0.9714,0.94
SetTextureCoordinates,15,0.9714,1
SetTextureCoordinates,16,1,0.94
SetTextureCoordinates,17,1,1
CreateMeshBuilder ;  parte posteriore
AddVertex, -1.12  , 3.27 , 7.85
AddVertex, -1.22  , 3.27 , 6.85
AddVertex, -1.12  , 3.28 , 7.85
AddVertex, -1.15  , 3.40 , 6.85
AddVertex, -1.05  , 3.38 , 7.85
AddVertex, -1.05  , 3.50 , 6.85
AddVertex, -0.60  , 3.50 , 7.85
AddVertex, -0.60  , 3.57 , 6.85
AddVertex,  0.00  , 3.53 , 7.85
AddVertex,  0.00  , 3.60 , 6.85
AddVertex,  0.60  , 3.50 , 7.85
AddVertex,  0.60  , 3.57 , 6.85
AddVertex,  1.05  , 3.38 , 7.85
AddVertex,  1.05  , 3.50 , 6.85
AddVertex,  1.12  , 3.28 , 7.85
AddVertex,  1.15  , 3.40 , 6.85
AddVertex,  1.12  , 3.27 , 7.85
AddVertex,  1.22  , 3.27 , 6.85
AddFace2, 2, 3, 1, 0
AddFace2, 4, 5, 3, 2
AddFace2, 6, 7, 5, 4
AddFace2, 8, 9, 7, 6
AddFace2,10,11, 9, 8
AddFace2,12,13,11,10
AddFace2,14,15,13,12
AddFace2,16,17,15,14
GenerateNormals
LoadTexture, tetto_chiaro.bmp
SetTextureCoordinates,0,0,0
SetTextureCoordinates,1,0 ,1
SetTextureCoordinates,2,0.0286,0
SetTextureCoordinates,3,0.0286,0.06
SetTextureCoordinates,4,0.0696,0
SetTextureCoordinates,5,0.0696,0.06
SetTextureCoordinates,6,0.2540,0
SetTextureCoordinates,7,0.2540,0.06
SetTextureCoordinates,8,0.50,0
SetTextureCoordinates,9,0.50,0.06
SetTextureCoordinates,10,0.746,0
SetTextureCoordinates,11,0.746,0.06
SetTextureCoordinates,12,0.9304,0
SetTextureCoordinates,13,0.9304,0.06
SetTextureCoordinates,14,0.9714,0
SetTextureCoordinates,15,0.9714,0.06
SetTextureCoordinates,16,1,0
SetTextureCoordinates,17,1,0.06



CreateMeshBuilder ; facciata alta anteriore
AddVertex, -1.10  , 3.20 ,-7.83
AddVertex, -1.10  , 3.27 ,-7.83
AddVertex, -1.10 , 3.20 ,-7.83
AddVertex, -1.05  , 3.37 ,-7.83
AddVertex, -1.05  , 3.20 ,-7.83
AddVertex, -0.60  , 3.49 ,-7.83
AddVertex, -0.60  , 3.20 ,-7.83
AddVertex,  0.00  , 3.52 ,-7.83
AddVertex,  0.00  , 3.20 ,-7.83
AddVertex,  0.60  , 3.49 ,-7.83
AddVertex,  0.60  , 3.20 ,-7.83
AddVertex,  1.05  , 3.37 ,-7.83
AddVertex,  1.05  , 3.20 ,-7.83
AddVertex,  1.10  , 3.27 ,-7.83
AddVertex,  1.10  , 3.20 ,-7.83
AddVertex,  1.10  , 3.20 ,-7.83
AddFace2, 0, 1, 2
AddFace2, 1,3,4,2
AddFace2, 3,5,6,4
AddFace2, 5,7,8,6
AddFace2, 7,9,10,8
AddFace2, 9,11,12,10
AddFace2,11,13,14,12
AddFace2,13,15,14
GenerateNormals
SetColor,230,228,204
CreateMeshBuilder ; facciata alta posteriore
AddVertex, -1.10  , 3.20 ,-7.83
AddVertex, -1.10  , 3.27 ,-7.83
AddVertex, -1.10  , 3.20 ,-7.83
AddVertex, -1.05  , 3.37 ,-7.83
AddVertex, -1.05  , 3.20 ,-7.83
AddVertex, -0.60  , 3.49 ,-7.83
AddVertex, -0.60  , 3.20 ,-7.83
AddVertex,  0.00  , 3.52 ,-7.83
AddVertex,  0.00  , 3.20 ,-7.83
AddVertex,  0.60  , 3.49 ,-7.83
AddVertex,  0.60  , 3.20 ,-7.83
AddVertex,  1.05  , 3.37 ,-7.83
AddVertex,  1.05  , 3.20 ,-7.83
AddVertex,  1.10  , 3.27 ,-7.83
AddVertex,  1.10  , 3.20 ,-7.83
AddVertex,  1.10  , 3.20 ,-7.83
AddFace2, 0, 1, 2
AddFace2, 1,3,4,2
AddFace2, 3,5,6,4
AddFace2, 5,7,8,6
AddFace2, 7,9,10,8
AddFace2, 9,11,12,10
AddFace2,11,13,14,12
AddFace2,13,15,14
GenerateNormals
SetColor,230,228,204
Rotate,0,1,0,180

; grondaia
CreateMeshBuilder ;  grondaia laterale centrale sx e dx
AddVertex, -1.22  , 3.27 , 6.85
AddVertex, -1.22  , 3.27 ,-6.85
AddVertex, -1.22  , 3.20 , -6.85
AddVertex, -1.22  , 3.20 ,6.85
AddVertex, 1.22  , 3.27 , 6.85
AddVertex, 1.22  , 3.27 ,-6.85
AddVertex, 1.22  , 3.20 , -6.85
AddVertex, 1.22  , 3.20 ,6.85
AddFace2, 0, 1, 2, 3
AddFace2, 4, 5, 6, 7
SetColor,130,6,10

CreateMeshBuilder ;  grondaia laterale anteriore sx e dx
AddVertex, -1.22  , 3.27 , -6.85
AddVertex, -1.12  , 3.27 ,-7.85
AddVertex, -1.12  , 3.20 , -7.85
AddVertex, -1.22  , 3.20 ,-6.85
AddVertex, 1.22  , 3.27 , -6.85
AddVertex, 1.12  , 3.27 ,-7.85
AddVertex, 1.12  , 3.20 , -7.85
AddVertex, 1.22  , 3.20 ,-6.85
AddFace2, 0, 1, 2, 3
AddFace2, 4, 5, 6, 7
SetColor,130,6,10

CreateMeshBuilder ;  grondaia laterale posteriore sx e dx
AddVertex, -1.12  , 3.27 , 7.85
AddVertex, -1.22  , 3.27 ,6.85
AddVertex, -1.22  , 3.20 , 6.85
AddVertex, -1.12  , 3.20 ,7.85
AddVertex, 1.12  , 3.27 , 7.85
AddVertex, 1.22  , 3.27 ,6.85
AddVertex, 1.22  , 3.20 , 6.85
AddVertex, 1.12 , 3.20 ,7.85
AddFace2, 0, 1, 2, 3
AddFace2, 4, 5, 6, 7
SetColor,130,6,10

CreateMeshBuilder ; grondaia anteriore
Addvertex, -1.12  , 3.13 ,-7.85;0 * 3.13
AddVertex, -1.12  , 3.20 ,-7.85;1
AddVertex, -1.12  , 3.28 ,-7.85;2
AddVertex, -1.12  , 3.20 ,-7.85;3 * 3.26
AddVertex, -1.05  , 3.38 ,-7.85;4 *
AddVertex, -1.04  , 3.31 ,-7.85;5 3.36 *
AddVertex, -0.60  , 3.50 ,-7.85;6
AddVertex, -0.60  , 3.43 ,-7.85;7
AddVertex,  0.00  , 3.53 ,-7.85;8
AddVertex,  0.00  , 3.46 ,-7.85;9
AddVertex,  0.60  , 3.50 ,-7.85;10
AddVertex,  0.60  , 3.43 ,-7.85;11
AddVertex,  1.05  , 3.38 ,-7.85;12 * 
AddVertex,  1.04  , 3.31 ,-7.85;13 *
AddVertex,  1.12  , 3.28 ,-7.85;14
AddVertex,  1.12  , 3.20 ,-7.85;15 * 3.26
AddVertex,  1.12  , 3.20 ,-7.85;16
AddVertex,  1.12  , 3.13 ,-7.85;17 * 3.13
AddFace2, 0, 1, 2, 3
AddFace2, 2,4,5,3
AddFace2, 4,6,7,5
AddFace2, 8,9,7,6
AddFace2, 8,10,11,9
AddFace2, 10,12,13,11
AddFace2,12,14,15,13
AddFace2,14,16,17,15
GenerateNormals
SetColor,130,6,10
CreateMeshBuilder ; grondaia posteriore
Addvertex, -1.12  , 3.13 ,7.85;0 * 3.13
AddVertex, -1.12  , 3.20 ,7.85;1
AddVertex, -1.12  , 3.28 ,7.85;2
AddVertex, -1.12  , 3.20 ,7.85;3 * 3.26
AddVertex, -1.05  , 3.38 ,7.85;4 *
AddVertex, -1.04  , 3.31 ,7.85;5 3.36 *
AddVertex, -0.60  , 3.50 ,7.85;6
AddVertex, -0.60  , 3.43 ,7.85;7
AddVertex,  0.00  , 3.53 ,7.85;8
AddVertex,  0.00  , 3.46 ,7.85;9
AddVertex,  0.60  , 3.50 ,7.85;10
AddVertex,  0.60  , 3.43 ,7.85;11
AddVertex,  1.05  , 3.38 ,7.85;12 * 
AddVertex,  1.04  , 3.31 ,7.85;13 *
AddVertex,  1.12  , 3.28 ,7.85;14
AddVertex,  1.12  , 3.20 ,7.85;15 * 3.26
AddVertex,  1.12  , 3.20 ,7.85;16
AddVertex,  1.12  , 3.13 ,7.85;17 * 3.13
AddFace2, 0, 1, 2, 3
AddFace2, 2,4,5,3
AddFace2, 4,6,7,5
AddFace2, 8,9,7,6
AddFace2, 8,10,11,9
AddFace2, 10,12,13,11
AddFace2,12,14,15,13
AddFace2,14,16,17,15
GenerateNormals
SetColor,130,6,10

CreateMeshBuilder ; frontale anteriore
AddVertex, -1.10  , 0.7  ,-7.8  ; 1
AddVertex, -1.10  , 3.27 ,-7.8  ; 0 
AddVertex,  1.10  , 3.27 ,-7.8  ; 2 
AddVertex,  1.10  , 0.7  ,-7.8  ; 3
AddFace2, 0, 1,2,3
GenerateNormals
LoadTexture,C101_testata_rossa.bmp
SetTextureCoordinates,0,0,1
SetTextureCoordinates,1,0,0
SetTextureCoordinates,2,1,0
SetTextureCoordinates,3,1,1
SetDecalTransparentColor,0,0,0

CreateMeshBuilder; VETRI
AddVertex, -1.05  , 3.2, -7.7
AddVertex, 1.05 , 3.2,-7.7
AddVertex, 1.05 , 1.3,-7.7
AddVertex, -1.05  , 1.3,-7.7
AddFace,0,1,2,3
GenerateNormals
SetColor,50,50,50,130
CreateMeshBuilder; Parete divisoria
AddVertex, -1.05  , 3.2, -6.9
AddVertex, 1.05 , 3.2,-6.9
AddVertex, 1.05 , 1.0,-6.9
AddVertex, -1.05  , 1.0,-6.9
AddFace2,0,1,2,3
GenerateNormals
LoadTexture, parete_divisoria.bmp
SetTextureCoordinates,0,0,0.10
SetTextureCoordinates,1,1,0.10
SetTextureCoordinates,2,1,1
SetTextureCoordinates,3,0,1
SetDecalTransparentColor,0,0,0


CreateMeshBuilder ; frontale anteriore
AddVertex, -1.10  , 0.7  ,-7.8  ; 1
AddVertex, -1.10  , 3.27 ,-7.8  ; 0 
AddVertex,  1.10  , 3.27 ,-7.8  ; 2 
AddVertex,  1.10  , 0.7  ,-7.8  ; 3
AddFace2, 0, 1,2,3
GenerateNormals
LoadTexture,C101_testata_rossa.bmp
SetTextureCoordinates,0,0,1
SetTextureCoordinates,1,0,0
SetTextureCoordinates,2,1,0
SetTextureCoordinates,3,1,1
Rotate,0,1,0,180
SetDecalTransparentColor,0,0,0

CreateMeshBuilder; VETRI
AddVertex, -1.05  , 3.2, 7.7
AddVertex, 1.05 , 3.2,7.7
AddVertex, 1.05 , 1.3,7.7
AddVertex, -1.05  , 1.3,7.7
AddFace,3,2,1,0
GenerateNormals
SetColor,50,50,50,130
CreateMeshBuilder; Parete divisoria
AddVertex, -1.05  , 3.2, 6.9
AddVertex, 1.05 , 3.2,6.9
AddVertex, 1.05 , 1.0,6.9
AddVertex, -1.05  , 1.0,6.9
AddFace2,0,1,2,3
GenerateNormals
LoadTexture, parete_divisoria.bmp
SetTextureCoordinates,0,0,0.10
SetTextureCoordinates,1,1,0.10
SetTextureCoordinates,2,1,1
SetTextureCoordinates,3,0,1
SetDecalTransparentColor,0,0,0


; ------------ Fiancata sinistra  ----------------
CreateMeshBuilder
AddVertex, -1.10  , 0 , 7.8,		; 0
AddVertex, -1.10  , 3.3 , 7.8,	; 1
AddVertex, -1.10  , 3.3 , 6.84,	; 2
AddVertex, -1.10  , 0 , 6.84,		; 3	

AddVertex, -0.90  , 3.3 , 6.84,	; 4
AddVertex, -0.90  , 0 , 6.84,		; 5	

AddVertex, -0.90  , 3.3 , 5.99,	; 6
AddVertex, -0.90  , 0 , 5.99,		; 7

AddVertex, -1.2  , 3.3 , 5.99,	; 8 
AddVertex, -1.2  , 0 , 5.99,		; 9	

AddVertex, -1.2  , 3.3 , -6.10,	; 10
AddVertex, -1.2  , 0 , -6.10,		; 11

AddVertex, -0.90  , 3.3 , -6.10,	; 12
AddVertex, -0.90  , 0 , -6.10,	; 13

AddVertex, -0.90  , 3.3 , -6.86,	; 14
AddVertex, -0.90  , 0 , -6.86,	; 15

AddVertex, -1.1  , 3.3 , -6.86,	; 16
AddVertex, -1.1  , 0 , -6.86,		; 17

AddVertex, -1.10  , 3.3 , -7.80,	; 18
AddVertex, -1.10  , 0 , -7.80,	; 19

AddFace2,0,1,2,3
AddFace2,2,4,5,3
AddFace2,4,6,7,5
AddFace2,6,8,9,7
AddFace2,8,10,11,9
AddFace2,10,12,13,11
AddFace2,12,14,15,13
AddFace2,14,16,17,15
AddFace2,16,18,19,17


GenerateNormals
LoadTexture, C101_fiancata_rossa.bmp
SetTextureCoordinates,0,0,1
SetTextureCoordinates,1,0,0
SetTextureCoordinates,2,0.064,0
SetTextureCoordinates,3,0.064,1
SetTextureCoordinates,4,0.074,0
SetTextureCoordinates,5,0.074,1
SetTextureCoordinates,6,0.1205,0,; 0.121
SetTextureCoordinates,7,0.1205,1
SetTextureCoordinates,8,0.1205,0,; 0.122
SetTextureCoordinates,9,0.1205,1
SetTextureCoordinates,10,0.886,0,; 0.886
SetTextureCoordinates,11,0.886,1
SetTextureCoordinates,12,0.887,0,; 0.887
SetTextureCoordinates,13,0.887,1
SetTextureCoordinates,14,0.933,0,;0.937
SetTextureCoordinates,15,0.933,1
SetTextureCoordinates,16,0.938,0
SetTextureCoordinates,17,0.938,1
SetTextureCoordinates,18,1,0
SetTextureCoordinates,19,1,1
SetDecalTransparentColor,0,0,0

CreateMeshBuilder
AddVertex, -0.85  , 3.2 , 7.7
AddVertex, -0.85 , 3.2 ,-7.7
AddVertex, -0.85 , 1.3 ,-7.7
AddVertex, -0.85  , 1.3 , 7.7
AddFace2,0,1,2,3
GenerateNormals
SetColor,50,50,50,130



; ------------ Fiancata destra  ----------------
CreateMeshBuilder
AddVertex, -1.10  , 0 , 7.8,		; 0
AddVertex, -1.10  , 3.3 , 7.8,	; 1
AddVertex, -1.10  , 3.3 , 6.84,	; 2
AddVertex, -1.10  , 0 , 6.84,		; 3	

AddVertex, -0.90  , 3.3 , 6.84,	; 4
AddVertex, -0.90  , 0 , 6.84,		; 5	

AddVertex, -0.90  , 3.3 , 5.99,	; 6
AddVertex, -0.90  , 0 , 5.99,		; 7

AddVertex, -1.2  , 3.3 , 5.99,	; 8 
AddVertex, -1.2  , 0 , 5.99,		; 9	

AddVertex, -1.2  , 3.3 , -6.10,	; 10
AddVertex, -1.2  , 0 , -6.10,		; 11

AddVertex, -0.90  , 3.3 , -6.10,	; 12
AddVertex, -0.90  , 0 , -6.10,	; 13

AddVertex, -0.90  , 3.3 , -6.86,	; 14
AddVertex, -0.90  , 0 , -6.86,	; 15

AddVertex, -1.10  , 3.3 , -6.86,	; 16
AddVertex, -1.10  , 0 , -6.86,		; 17

AddVertex, -1.10  , 3.3 , -7.80,	; 18
AddVertex, -1.10  , 0 , -7.80,	; 19

AddFace2,0,1,2,3
AddFace2,2,4,5,3
AddFace2,4,6,7,5
AddFace2,6,8,9,7
AddFace2,8,10,11,9
AddFace2,10,12,13,11
AddFace2,12,14,15,13
AddFace2,14,16,17,15
AddFace2,16,18,19,17


GenerateNormals
LoadTexture, C101_fiancata_rossa.bmp
SetTextureCoordinates,0,0,1
SetTextureCoordinates,1,0,0
SetTextureCoordinates,2,0.064,0
SetTextureCoordinates,3,0.064,1
SetTextureCoordinates,4,0.074,0
SetTextureCoordinates,5,0.074,1
SetTextureCoordinates,6,0.1205,0,; 0.121
SetTextureCoordinates,7,0.1205,1
SetTextureCoordinates,8,0.1205,0,; 0.122
SetTextureCoordinates,9,0.1205,1
SetTextureCoordinates,10,0.886,0,; 0.886
SetTextureCoordinates,11,0.886,1
SetTextureCoordinates,12,0.887,0,; 0.887
SetTextureCoordinates,13,0.887,1
SetTextureCoordinates,14,0.933,0,;0.937
SetTextureCoordinates,15,0.933,1
SetTextureCoordinates,16,0.938,0
SetTextureCoordinates,17,0.938,1
SetTextureCoordinates,18,1,0
SetTextureCoordinates,19,1,1
SetDecalTransparentColor,0,0,0
Rotate,0,1,0,180

CreateMeshBuilder
AddVertex, -0.85  , 3.2 , 7.7
AddVertex, -0.85 , 3.2 ,-7.7
AddVertex, -0.85 , 1.3 ,-7.7
AddVertex, -0.85  , 1.3 , 7.7
AddFace2,0,1,2,3
GenerateNormals
SetColor,50,50,50,130
Rotate,0,1,0,180



; ------------ Pavimento ----------------
CreateMeshBuilder ; pavimento del salone 2.2 x 7.8 - ad altezza 1.2
AddVertex, -0.890  , 0.86, 7.7
AddVertex,  0.890  , 0.86, 7.7
AddVertex,  0.890  , 0.86,-7.7
AddVertex, -0.89  , 0.86,-7.7
AddFace2,0,1,2,3
GenerateNormals
SetColor,54,48,22

; - - - - - -  Carrelli 
CreateMeshBuilder
AddVertex, 0, 0.8 , 1.6
AddVertex, 0, 0.8 ,-1.6
AddVertex, 0,-0.1 ,-1.6
AddVertex, 0,-0.1 , 1.6
AddFace2,0,1,2,3
GenerateNormals
LoadTexture, bogie.bmp
SetTextureCoordinates,0,1,0
SetTextureCoordinates,1,0,0
SetTextureCoordinates,2,0,1
SetTextureCoordinates,3,1,1
SetDecalTransparentColor,0,0,255
Translate,0.7,0.12,-4.95

CreateMeshBuilder
AddVertex, 0, 0.8 , 1.6
AddVertex, 0, 0.8 ,-1.6
AddVertex, 0,-0.1 ,-1.6
AddVertex, 0,-0.1 , 1.6
AddFace2,0,1,2,3
GenerateNormals
LoadTexture, bogie.bmp
SetTextureCoordinates,0,1,0
SetTextureCoordinates,1,0,0
SetTextureCoordinates,2,0,1
SetTextureCoordinates,3,1,1
SetDecalTransparentColor,0,0,255
Translate,-0.7,0.12,-4.95

CreateMeshBuilder
AddVertex, 0, 0.8 , 1.6
AddVertex, 0, 0.8 ,-1.6
AddVertex, 0,-0.1 ,-1.6
AddVertex, 0,-0.1 , 1.6
AddFace2,0,1,2,3
GenerateNormals
LoadTexture, bogie.bmp
SetTextureCoordinates,0,1,0
SetTextureCoordinates,1,0,0
SetTextureCoordinates,2,0,1
SetTextureCoordinates,3,1,1
SetDecalTransparentColor,0,0,255
Translate,0.7,0.12,4.95

CreateMeshBuilder
AddVertex, 0, 0.8 , 1.6
AddVertex, 0, 0.8 ,-1.6
AddVertex, 0,-0.1 ,-1.6
AddVertex, 0,-0.1 , 1.6
AddFace2,0,1,2,3
GenerateNormals
LoadTexture, bogie.bmp
SetTextureCoordinates,0,1,0
SetTextureCoordinates,1,0,0
SetTextureCoordinates,2,0,1
SetTextureCoordinates,3,1,1
SetDecalTransparentColor,0,0,255
Translate,-0.7,0.12,4.95

; Ruote carrello anteriore
; ------------------
CreateMeshBuilder ; Ruota ant sin (3.25 + 0.75 = +4)
cylinder,10, 0.35, 0.38,0.1 
SetColor,24,24,24
rotate,0,0,1,90
translate,-0.55, 0.36, 5.90
CreateMeshBuilder ; Assale ant
cylinder,3, 0.08, 0.08 ,1.1 
SetColor,24,24,24
rotate,0,0,1,-90
translate, 0, 0.36, 5.90

CreateMeshBuilder ; Ruota ant des (3.25 + 0.75 = +4)
cylinder,10, 0.35, 0.38,0.1 
SetColor,24,24,24
rotate,0,0,1,-90
translate, 0.55, 0.36, 5.90

CreateMeshBuilder ; Ruota post sin (3.25 - 0.75 = +2.5)
cylinder,10, 0.35, 0.38,0.1 
SetColor,24,24,24
rotate,0,0,1,90
translate,-0.55, 0.36, 3.90

CreateMeshBuilder ; Assale post
cylinder,3, 0.08, 0.08 ,1.1 
SetColor,24,24,24
rotate,0,0,1,-90
translate, 0, 0.36, 3.90

CreateMeshBuilder ; Ruota post des (3.25 - 0.75 = +2.5)
cylinder,10, 0.35, 0.38,0.1 
SetColor,24,24,24
rotate,0,0,1,-90
translate, 0.55, 0.36, 3.90


; Ruote carrello posteriore
; ------------------
CreateMeshBuilder ; Ruota ant sin (-3.25 + 0.75 = -2.5)
cylinder,10, 0.35, 0.38,0.1 
SetColor,24,24,24
rotate,0,0,1,90
translate,-0.55, 0.36, -3.90

CreateMeshBuilder ; Assale ant
cylinder,3, 0.08, 0.08 ,1.1 
SetColor,24,24,24
rotate,0,0,1,-90
translate, 0, 0.36, -3.90

CreateMeshBuilder ; Ruota ant des (-3.25 + 0.75 = -2.5)
cylinder,10, 0.35, 0.38,0.1 
SetColor,24,24,24
rotate,0,0,1,-90
translate, 0.55, 0.36, -3.9

CreateMeshBuilder ; Ruota post sin (-3.25 - 0.75 = -4)
cylinder,10, 0.35, 0.38,0.1 
SetColor,24,24,24
rotate,0,0,1,90
translate,-0.55, 0.36, -5.90

CreateMeshBuilder ; Assale post
cylinder,3, 0.08, 0.08 ,1.1 
SetColor,24,24,24
rotate,0,0,1,-90
translate, 0, 0.36, -5.90

CreateMeshBuilder ; Ruota post des (-3.25 - 0.75 = -4)
cylinder,10, 0.35, 0.38,0.1 
SetColor,24,24,24
rotate,0,0,1,-90
translate, 0.55, 0.36, -5.90

CreateMeshBuilder ; Respingenti
cylinder,4, 0.12, 0.08 ,0.4 
SetColor,24,24,24
rotate,1,0,0,-90
translate, 0, 0.8, 7.95

CreateMeshBuilder
Cube,0.3,0.15,0.02
SetColor,24,24,24
translate, 0, 0.8, 8.15

CreateMeshBuilder ; Respingenti
cylinder,4, 0.08, 0.12 ,0.4 
SetColor,24,24,24
rotate,1,0,0,-90
translate, 0, 0.8, -7.95

CreateMeshBuilder
Cube,0.3,0.15,0.02
SetColor,24,24,24
translate, 0, 0.8, -8.15



; FEVF - FERROVIA ELETTRICA VALLE DI FIEMME
; by Roberto Benini - robertobenini@libero.it


; - - - - - struttura portante 
CreateMeshBuilder; longitudinale dx
Cube,0.05,0.15,7.65
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, 0.50, 0.67, 0
CreateMeshBuilder;longitudinale sx
Cube,0.05,0.15,7.65
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, -0.50, 0.67, 0
CreateMeshBuilder;trasversale anteriore
Cube,0.05,0.175,.65
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
Rotate,0,1,0,90
translate, 0, 0.67, 7.65
CreateMeshBuilder;trasversale posteriore
Cube,0.05,0.175,.65
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
Rotate,0,1,0,90
translate, 0, 0.67, -7.65

; ganci
CreateMeshBuilder ; anteriore 
AddVertex, 0  , 0.70 ,-0.15
AddVertex, 0  , 0.70, 0.15
AddVertex, 0  , 0.10 ,0.15
AddVertex, 0  , 0.10 ,-0.15
AddFace2,0,1,2,3
GenerateNormals
LoadTexture, gancio.bmp
SetTextureCoordinates,0,0,0
SetTextureCoordinates,1,1,0
SetTextureCoordinates,2,1,1
SetTextureCoordinates,3,0,1
SetDecalTransparentColor,0,0,0
Translate,0,0.00,7.8

CreateMeshBuilder ; posteriore 
AddVertex, 0  , 0.70 ,-0.15
AddVertex, 0  , 0.70, 0.15
AddVertex, 0  , 0.10 ,0.15
AddVertex, 0  , 0.10 ,-0.15
AddFace2,0,1,2,3
GenerateNormals
LoadTexture, gancio.bmp
SetTextureCoordinates,0,0,0
SetTextureCoordinates,1,1,0
SetTextureCoordinates,2,1,1
SetTextureCoordinates,3,0,1
SetDecalTransparentColor,0,0,0
Rotate,0,1,0,180
Translate,0,0.00,-7.8

; - - - - - -  meccanismi sottopianale
CreateMeshBuilder; cassa dx
Cube,0.50,0.15,0.55
SetColor,120,120,120
translate, 0.64, 0.45, -.30

CreateMeshBuilder; cassa sx
Cube,0.50,0.15,0.55
SetColor,120,120,120
translate, -0.64, 0.45, 0.30

CreateMeshBuilder ; serbatoio dx
cylinder,10, 0.20, 0.20 ,1 
SetColor,120,120,120
rotate,1,0,0,90
translate, 0.9, 0.55, 1.80

CreateMeshBuilder ; serbatoio sx
cylinder,10, 0.20, 0.20 ,1 
SetColor,120,120,120
rotate,1,0,0,90
translate, -0.9, 0.55, -1.80


; - - - - - - struttura laterale dx
CreateMeshBuilder; anteriore
Cube,0.02,0.02,1.27
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, -1.15, 0.08, 2.5
Rotate,1,0,0,-10
CreateMeshBuilder; centrale
Cube,0.02,0.02,1.25
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, -1.15, 0.30, 0
CreateMeshBuilder; posteriore
Cube,0.02,0.02,1.25
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, -1.15, 0.08, -2.5
Rotate,1,0,0,10
CreateMeshBuilder; verticale
Cube,0.02,0.25,.02
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, -1.15, 0.57, 1.27
CreateMeshBuilder; verticale
Cube,0.02,0.25,.02
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, -1.15, 0.57, -1.25


; - - - - - - struttura laterale sx
CreateMeshBuilder; anteriore
Cube,0.02,0.02,1.27
SetColor,41,66,57,
translate, 1.15, 0.08, 2.5
Rotate,1,0,0,-10
CreateMeshBuilder; centrale
Cube,0.02,0.02,1.25
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, 1.15, 0.30, 0
CreateMeshBuilder; posteriore
Cube,0.02,0.02,1.25
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, 1.15, 0.08, -2.5
Rotate,1,0,0,10
CreateMeshBuilder; verticale
Cube,0.02,0.25,.02
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, 1.15, 0.57, 1.27
CreateMeshBuilder; verticale
Cube,0.02,0.25,.02
SetColor,41,66,57,;236,228,191,;230,228,213,; 215,234,238
translate, 1.15, 0.57, -1.25

; FEVF - FERROVIA ELETTRICA VALLE DI FIEMME
; by Roberto Benini - robertobenini@libero.it
; (C) 06/12/2005
; in caso di utilizzo citare fonte

; - - - - - -  MANCORRENTI ANTERIORI

; DX 
CreateMeshBuilder ; orizzontale 
cylinder,5, 0.015, 0.015 ,0.500 
SetColor,111,109,84
rotate,1,0,0,90
translate, 0.4, 1.92, 7.75
CreateMeshBuilder ; diagonale 
cylinder,5, 0.015, 0.015 ,0.6200 
SetColor,111,109,84
rotate,1,0,0,45
translate, 0.4, 1.65, 7.805; delta z rispetto a cilinder 0.055
CreateMeshBuilder ; curva 1
cylinder,5, 0.015, 0.015 ,0.045 
SetColor,111,109,84
rotate,1,0,0,-45
translate, 0.40, 1.91, 8.01; delta z rispetto a cilinder 0.26
CreateMeshBuilder ; curva 2
cylinder,5, 0.015, 0.015 ,0.04 
SetColor,111,109,84
translate, 0.40, 1.88, 8.02,; delta z rispetto a cilinder 0.27
; SX 
CreateMeshBuilder ; orizzontale 
cylinder,5, 0.015, 0.015 ,0.500 
SetColor,111,109,84
rotate,1,0,0,90
translate, -0.4, 1.92, 7.75
CreateMeshBuilder ; diagonale 
cylinder,5, 0.015, 0.015 ,0.6200 
SetColor,111,109,84
rotate,1,0,0,45
translate, -0.4, 1.65, 7.805
CreateMeshBuilder ; curva 1
cylinder,5, 0.015, 0.015 ,0.045 
SetColor,111,109,84
rotate,1,0,0,-45
translate, -0.40, 1.91, 8.01
CreateMeshBuilder ; curva 2
cylinder,5, 0.015, 0.015 ,0.04 
SetColor,111,109,84
translate, -0.40, 1.88,8.02

; - - - - - -  MANCORRENTI posteriori

; DX 
CreateMeshBuilder ; orizzontale 
cylinder,5, 0.015, 0.015 ,0.500 
SetColor,111,109,84
rotate,1,0,0,90
translate, 0.4, 1.92, 7.75
rotate,0,1,0,180

CreateMeshBuilder ; diagonale 
cylinder,5, 0.015, 0.015 ,0.6200 
SetColor,111,109,84
rotate,1,0,0,45
translate, 0.4, 1.65, 7.805; delta z rispetto a cilinder 0.055
rotate,0,1,0,180

CreateMeshBuilder ; curva 1
cylinder,5, 0.015, 0.015 ,0.045 
SetColor,111,109,84
rotate,1,0,0,-45
translate, 0.40, 1.91, 8.01; delta z rispetto a cilinder 0.26
rotate,0,1,0,180

CreateMeshBuilder ; curva 2
cylinder,5, 0.015, 0.015 ,0.04 
SetColor,111,109,84
translate, 0.40, 1.88, 8.02,; delta z rispetto a cilinder 0.27
rotate,0,1,0,180

; SX 
CreateMeshBuilder ; orizzontale 
cylinder,5, 0.015, 0.015 ,0.500 
SetColor,111,109,84
rotate,1,0,0,90
translate, -0.4, 1.92, 7.75
rotate,0,1,0,180


CreateMeshBuilder ; diagonale 
cylinder,5, 0.015, 0.015 ,0.6200 
SetColor,111,109,84
rotate,1,0,0,45
translate, -0.4, 1.65, 7.805
rotate,0,1,0,180

CreateMeshBuilder ; curva 1
cylinder,5, 0.015, 0.015 ,0.045 
SetColor,111,109,84
rotate,1,0,0,-45
translate, -0.40, 1.91, 8.01
rotate,0,1,0,180

CreateMeshBuilder ; curva 2
cylinder,5, 0.015, 0.015 ,0.04 
SetColor,111,109,84
translate, -0.40, 1.88,8.02
rotate,0,1,0,180







; FEVF - FERROVIA ELETTRICA VALLE DI FIEMME
; by Roberto Benini - robertobenini@libero.it
; (C) 06/12/2005
; in caso di utilizzo citare fonte

; - - - - - -  MANICOTTO ANTERIORE 


CreateMeshBuilder ; tubo verticale
cylinder,8, 0.03, 0.03 ,1 
SetColor,40,40,40
translate, 0.5, 1.37,7.85

; 5 PEZZI DA 20x6 cm
CreateMeshBuilder ; 1 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,30
translate, 0.485, 1.08,7.90

CreateMeshBuilder ; 2 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,22.5
translate, 0.485, 1.255,7.99

CreateMeshBuilder ; 3 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,0
translate, 0.485, 1.43,8.025

CreateMeshBuilder ; 4 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,-22.5
translate, 0.485, 1.605,7.99

CreateMeshBuilder ; 5 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,-30
translate, 0.485, 1.775,7.90

; - - - - - -  MANICOTTO posteriore 


CreateMeshBuilder ; tubo verticale
cylinder,8, 0.03, 0.03 ,1 
SetColor,40,40,40
translate, 0.5, 1.37,7.85
rotate,0,1,0,180
; 5 PEZZI DA 20x6 cm
CreateMeshBuilder ; 1 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,30
translate, 0.485, 1.08,7.90
rotate,0,1,0,180

CreateMeshBuilder ; 2 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,22.5
translate, 0.485, 1.255,7.99
rotate,0,1,0,180

CreateMeshBuilder ; 3 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,0
translate, 0.485, 1.43,8.025
rotate,0,1,0,180

CreateMeshBuilder ; 4 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,-22.5
translate, 0.485, 1.605,7.99
rotate,0,1,0,180

CreateMeshBuilder ; 5 
cylinder,8, 0.03, 0.03 ,0.20 
SetColor,40,40,40
rotate,1,0,0,-30
translate, 0.485, 1.775,7.90
rotate,0,1,0,180
; - - - - - - SCALINI
; anteriore dx
CreateMeshBuilder
Cube,0.10,0.0125,0.378
SetColor,54,48,22
translate, 0.95, 0.54, 6.48
CreateMeshBuilder
Cube,0.15,0.0125,0.378
SetColor,54,48,22
translate, 1.05, 0.25, 6.48

; anteriore sx
CreateMeshBuilder
Cube,0.10,0.0125,0.378
SetColor,54,48,22
translate, 0.95, 0.54, 6.48
rotate,0,1,0,180
CreateMeshBuilder
Cube,0.15,0.0125,0.378
SetColor,54,48,22
translate, 1.05, 0.25, 6.48
rotate,0,1,0,180

; posteriore dx
CreateMeshBuilder
Cube,0.10,0.0125,0.42
SetColor,54,48,22
translate, 0.95, 0.54, -6.415
CreateMeshBuilder
Cube,0.15,0.0125,0.42
SetColor,54,48,22
translate, 1.05, 0.25, -6.415

; posteriore SX
CreateMeshBuilder
Cube,0.10,0.0125,0.42
SetColor,54,48,22
translate, 0.95, 0.54, -6.415
rotate,0,1,0,180
CreateMeshBuilder
Cube,0.15,0.0125,0.42
SetColor,54,48,22
translate, 1.05, 0.25, -6.415
rotate,0,1,0,180
