Hi!
I wanted to make a hangar with doors that open depending from distance.
Now my doors only work partially. They are displayed open and half open but not closed. here is the code:
;-> Animations
; ----------
;
;
IfVarRange( :Anim000 033b 0 49 )
:Anim000
IfVarRange( :Anim001 033b 50 99 ) TransformCall( art002 -15 0 -14 0 0 0 0 0 0 ) ;Wall 3
TransformCall( art002 15 0 -14 0 0 0 0 0 0 ) ;Wall 3_02
:Anim001
IfVarRange( :Anim002 033b 100 500 ) TransformCall( art001 0 0 -14 0 0 0 0 0 0 ) ;Wall 2
:Anim002
Return
;-------
art000
; cube - Cube 1
Points( 0
-20 0 -14 ; 0
20 0 -14 ; 1
20 0 14 ; 2
-20 0 14 ; 3
-20 20 -14 ; 4
20 20 -14 ; 5
20 20 14 ; 6
-20 20 14 ; 7
)
RGBSColor( EF 0 0 0 )
Poly( 0 0 -32767 -14 3 7 6 2 ) ;Inside back
Poly( 32767 0 0 -20 0 4 7 3 ) ;Inside left
Poly( -32767 0 0 -20 2 6 5 1 ) ;Inside right
Poly( 0 -32767 0 -20 5 6 7 4 ) ;Inside top
Poly( 0 32767 0 0 0 3 2 1 ) ;Inside bottom
Poly( 0 0 32767 14 2 6 7 3 ) ;Back
Poly( -32767 0 0 20 3 7 4 0 ) ;Left
Poly( 32767 0 0 20 1 5 6 2 ) ;Right
Poly( 0 32767 0 20 4 7 6 5 ) ;Top
Poly( 0 -32767 0 0 1 2 3 0 ) ;Bottom
Return
;-------
art001
; wall - Wall 2
Points( 8
-20 0 0 ; 0
-20 20 0 ; 1
20 20 0 ; 2
20 0 0 ; 3
)
RGBSColor( EF 253 46 47 )
Poly( 0 0 -32767 0 8 9 10 11 ) ;Front
Poly( 0 0 32767 0 11 10 9 8 ) ;Back
Return
;-------
art002
; wall - Wall 3
Points( 12
-5 0 0 ; 0
-5 20 0 ; 1
5 20 0 ; 2
5 0 0 ; 3
)
RGBSColor( EF 253 46 46 )
Poly( 0 0 -32767 0 12 13 14 15 ) ;Front
Poly( 0 0 32767 0 15 14 13 12 ) ;Back
Return
EndA
Do you know the problem?
Thanks in advance
Hekto
I wanted to make a hangar with doors that open depending from distance.
Now my doors only work partially. They are displayed open and half open but not closed. here is the code:
;-> Animations
; ----------
;
;
IfVarRange( :Anim000 033b 0 49 )
:Anim000
IfVarRange( :Anim001 033b 50 99 ) TransformCall( art002 -15 0 -14 0 0 0 0 0 0 ) ;Wall 3
TransformCall( art002 15 0 -14 0 0 0 0 0 0 ) ;Wall 3_02
:Anim001
IfVarRange( :Anim002 033b 100 500 ) TransformCall( art001 0 0 -14 0 0 0 0 0 0 ) ;Wall 2
:Anim002
Return
;-------
art000
; cube - Cube 1
Points( 0
-20 0 -14 ; 0
20 0 -14 ; 1
20 0 14 ; 2
-20 0 14 ; 3
-20 20 -14 ; 4
20 20 -14 ; 5
20 20 14 ; 6
-20 20 14 ; 7
)
RGBSColor( EF 0 0 0 )
Poly( 0 0 -32767 -14 3 7 6 2 ) ;Inside back
Poly( 32767 0 0 -20 0 4 7 3 ) ;Inside left
Poly( -32767 0 0 -20 2 6 5 1 ) ;Inside right
Poly( 0 -32767 0 -20 5 6 7 4 ) ;Inside top
Poly( 0 32767 0 0 0 3 2 1 ) ;Inside bottom
Poly( 0 0 32767 14 2 6 7 3 ) ;Back
Poly( -32767 0 0 20 3 7 4 0 ) ;Left
Poly( 32767 0 0 20 1 5 6 2 ) ;Right
Poly( 0 32767 0 20 4 7 6 5 ) ;Top
Poly( 0 -32767 0 0 1 2 3 0 ) ;Bottom
Return
;-------
art001
; wall - Wall 2
Points( 8
-20 0 0 ; 0
-20 20 0 ; 1
20 20 0 ; 2
20 0 0 ; 3
)
RGBSColor( EF 253 46 47 )
Poly( 0 0 -32767 0 8 9 10 11 ) ;Front
Poly( 0 0 32767 0 11 10 9 8 ) ;Back
Return
;-------
art002
; wall - Wall 3
Points( 12
-5 0 0 ; 0
-5 20 0 ; 1
5 20 0 ; 2
5 0 0 ; 3
)
RGBSColor( EF 253 46 46 )
Poly( 0 0 -32767 0 12 13 14 15 ) ;Front
Poly( 0 0 32767 0 15 14 13 12 ) ;Back
Return
EndA
Do you know the problem?
Thanks in advance
Hekto
Last edited: