Profile image

XML coding

604 poophead5  3.2 years ago
19 downloads

i have been trying to do simple code on funky trees but there just arent enough tutorials on internet if you dont know sht about at least simple programing....so im asking if some can give me some examples or something, lest say i want my rotor to activate automaticly if i fly under 300kph or if im at a certain alltitude my hinge or rotor activates, or when im locked my flares fire or auto missle fire...

General Characteristics

  • Created On Android
  • Wingspan 1.9ft (0.6m)
  • Length 31.2ft (9.5m)
  • Height 4.5ft (1.4m)
  • Empty Weight 782lbs (354kg)
  • Loaded Weight 782lbs (354kg)

Performance

  • Wing Loading 439,839.3lbs/ft2 (2,147,483.6kg/m2)
  • Wing Area 0.0ft2 (0.0m2)
  • Drag Points 385

Parts

  • Number of Parts 4
  • Control Surfaces 0
  • Performance Cost 17
  • Log in to leave a comment
  • Profile image
    604 poophead5

    @Pajamas720 oh okay i got it now thx, i just didnt convert it from kph to ms and thats why it didnt work

    3.2 years ago
  • Profile image
    1,565 Pajamas720

    for the first example, you can use an if statement to check speed and turn it into an input:
    GS <= 84 ? 1 : 0
    GS refers to ground speed but IAS or TAS also can be applied. 84 is the target speed in meters per second (if youre using MPH or KPH it must be converted to M/S)
    <= means less than or equal to
    1 is the out put if the previous statement is true, otherwise 0 is outputted. thse two outputs are separated by ":" and the outputs are separated by the inputs using "?". think of ? as "then" and : as "else"
    so in the statement, if GS is no more than 84 then 1 is outputted, the rotor is activated. if not, 0 is outputted, the rotor is deactivated.

    unfortunately theres not a variable for Lock Status yet, and i think weapon fire input is locked exclusively to the FireGuns/ FireWeapons inputs.

    if you need more help i would search and consult the forums as well as take a look here: https://snowflake0s.github.io/funkyguide.html

    +1 3.2 years ago