Welcome, Guest. Please Login or Register
YaBB - Yet another Bulletin Board
  Signup for free on our forum and benefit from new features!

FFDS Home | TIPS Section | Tutorials Section | Resources Section | Utilities Section

Military | FSDS | Jetliners | Real Planes Section | Gmax | Rotorcraft | Business | Civilian

  HomeHelpSearchLoginRegister  
 
 
Page Index Toggle Pages: 1
Send Topic Print
xml help needed (Read 1418 times)
13th Jun, 2013 at 7:17pm

NCGent   Offline
Point Pusher
I love YaBB 1G - SP1!

Posts: 31
*
 
I am attempting to make some code for a fan and switch to make it run. It's just a simple little house type fan that will going in the bridge of a ship I have built. I have tried to writ the code myself but have had no luck so far so I was wondering if there is someone that can take an fsc file that has the fan and a simple switch in it and write the code for me. If you can help me you can reach me at
chrisherring43@msn.com

Thanks

Chris
 
IP Logged
 
Reply #1 - 14th Jun, 2013 at 3:21pm

Tom/FFDS   Offline
YaBB Administrator
Jets are for kids!

Posts: 1584
*****
 
FSX or FS9?
 

Tom Gibson

California Classic Propliners: Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register

AlcoHauler Locomotive Page: Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register

San Diego Model RR Museum: Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
IP Logged
 
Reply #2 - 17th Jun, 2013 at 5:38pm

NCGent   Offline
Point Pusher
I love YaBB 1G - SP1!

Posts: 31
*
 
Its fs9 but also will work in fsx
 
IP Logged
 
Reply #3 - 18th Jun, 2013 at 5:49pm

Tom/FFDS   Offline
YaBB Administrator
Jets are for kids!

Posts: 1584
*****
 
Hi,

Here is one way, I assume there are others that may be better?

Name the fan part you want to animate as Tick_18_fan (for example).  Animate it with the number of keyframes needed to get the proper fan speed.

Then name a parent part (a small cube, for example) with a visibility condition so a custom L: variable must equal 1 for the moving fan to be visible.  Link the fan to this part.  The code for this small cube:

Code:
<part>
     <name>visible_fan</name> <!-- visible when fan is turned on-->
                 <visible_in_range>
                      <parameter>
                           <code>(L:Fan_Control, bool) </code>
                       </parameter>
                       <minvalue>1</minvalue>
                 </visible_in_range>
</part> 



Then create an identical fan with the part name static_fan, and code that part as:

Code:
<part>
     <name>static_fan</name> <!-- invisible when fan is turned on-->
                 <visible_in_range>
                      <parameter>
                           <code>(L:Fan_Control, bool) ! </code>
                       </parameter>
                       <minvalue>1</minvalue>
                 </visible_in_range>
</part> 



For the switch, use the L: variable above to control the visibility:

(L:Fan_Control, bool) ! (>L:Fan_Control, bool)

Hope this helps,
 

Tom Gibson

California Classic Propliners: Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register

AlcoHauler Locomotive Page: Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register

San Diego Model RR Museum: Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
IP Logged
 
Reply #4 - 22nd Jun, 2013 at 6:19pm

NCGent   Offline
Point Pusher
I love YaBB 1G - SP1!

Posts: 31
*
 
That is just what I needed, thanks a million.
 
IP Logged
 
Page Index Toggle Pages: 1
Send Topic Print