Profile image

(Tutorial) The Basics Of Creating Digital Flight Displays Using Text Labels:

27.3k TheFlightGuySP  1.9 years ago

Text Data Values:
<size=number%> (The size of the text as a percentage.)
<align="text"> (The alignment of the text on the label. I only know of 3 inputs for this: center, left, and right.)
<pos=number%> (The horizontal position of the text as a percentage. If alignment is center, then 0% for this value is the center of the label.)
<alpha=#number or FF> (The opacity of the text as a number, or FF for 100% opacity.)
<width=number%> (The width of the text as a percentage.)
This is not the complete list of values.

How To Use:
To put in variable data, your data values need to be surrounded by {} brackets. For example: {VTOL}. You can also put in expressions, such as: {round(VTOL)}.
If you want some non-variable text before the variable text (perhaps for an airspeed indicator), just leave some text outside the brackets. TAS: {round(TAS)}m/s will show the text TAS: and then a space after it, then display your true airspeed (rounded to the nearest integer) in meters per second, followed by m/s just so the pilot knows what units they are looking at. Additionally, putting ;#0.0 after a data value such as AngleOfAttack will show the data in a number-decimal-number format. This can also be done with ;#0.00 or however many zeros you need.

But what if you need to change the position or size of a text? All you need to do is use the text values listed above, and place them outside the data brackets. For example: "<size=75%><pos=10%>TAS: {round(TAS)}m/s".
You can change the opacity of the text by placing an alpha value like the one listed above. If you want alpha at its maximum, put FF instead of a number.

Do some experimentation with this information, mess around with the values, and figure out what works. There are many more possibilities than what is shown here.

Thoughts or suggestions? Let me know!

  • Log in to leave a comment
  • Profile image
    4,336 Stanmich

    FOR THOSE WHO NEED IT AND DON'T WANT ANOTHER CHROME TAB:
    █ full block
    ▄ bottom half
    ▀ top half

    If there's any that should be here too, tell me!!!

    7 months ago
  • Profile image
    2 Jandy

    @SemedianIndustries hope its not too late but if its in a label and not a variable you can do an if-then and just have the valueiftrue or valueiffalse as: ""

    9 months ago
  • Profile image

    @Jusevs Firstly, no, you don't put {} brackets around a value if the whole expression is already stored in {} brackets. The entire expression needs to be stored within a single pair of brackets, otherwise it's going to display parts of the expression as non-variable text.

    Secondly, after doing some testing, I found that the label input was trying to convert a string-type value into a single-type value, displayed as Cannot convert type System.String to System.Single in the developer console. I did some more testing with variables and expressions but continued encountering errors.

    I know a decent bit about Funky Trees but not much about VR interactable parts. I'd recommend asking someone who has more experience with VR parts than I do. I'm sure they would have some helpful advice.

    One more thing: when in doubt, check the developer console. It can help a lot for debugging.

    10 months ago
  • Profile image
    195 Polarity

    @TheFlightGuySP I tried it on a new aircraft just to make sure, but it just shows nothing even with dev console showing RCMFD was 1 it was just blank. The data value needs to be in brackets and so does RCMFD making it inevitable for it to be repeated
    I have it here

    10 months ago
  • Profile image

    @Jusevs {RCMFD>=1 ? Trim : " "}
    Copy and paste this into the text label.
    The code brackets shouldn't be repeated. If you want to put more complex expressions in the text field you can put () brackets instead of {} brackets.

    10 months ago
  • Profile image
    195 Polarity

    @TheFlightGuySP Like this?
    {RCMFD >=1 ? {Trim} : ""}
    it shows the trim but the switch doesn't work. the label just shows:
    {RCMFD >= 1 ? 0 : " "}
    And cant be turned off by the switch.

    10 months ago
  • Profile image

    @Jusevs Remove the quote marks around the code brackets.

    10 months ago
  • Profile image
    195 Polarity

    Is there a way to make a switch show a data value when activated? I tried:

    {RCMFD >=1 ? "{Trim}" : ""}

    You cant do it because you need brackets for data values and also need them to end it so i dont know what to do. Tried with () and [] but with no success. Please help me

    10 months ago
  • Profile image
    77.6k KSB24

    @TheFlightGuySP Thanks a lot. It worked. These would be very helpful to making car interiors.

    10 months ago
  • Profile image

    @KSB24 Sorry for the late response. Been occupied with other things.
    So if I understood that correctly, then the expression should look like this:

    {Activate8=1 ? round(GS*3.6)+"Km/H" : " "}

    I tested this and it seems to work fine. It won't display anything when Activate8 is disabled, but if you want to fix this you can fill that blank space between the second set of quotes with whatever you'd like.

    +1 10 months ago
  • Profile image
    77.6k KSB24

    Everything is easy to understand. But this is what i'm trying to make (using the single part label display the number of GS*3.6 and the letter "Km/h" letter at when Activate8 is 1) is very difficult to find the way how. can you please tell me how?

    11 months ago
  • Profile image
    14.7k ChamDel78

    @TheFlightGuySP Thx

    11 months ago
  • Profile image

    @ChamDel78 If you want TAS or GS then you can substitute those values in as well.

    11 months ago
  • Profile image

    @ChamDel78 IAS: {round(IAS*2.2369362921)}mph
    See if this works.

    11 months ago
  • Profile image
    14.7k ChamDel78

    How to make is show mph?

    11 months ago
  • Profile image

    @Miata https://snowflake0s.github.io/funkyguide/ has a full list of XML values and explanations for each.

    one year ago
  • Profile image

    @Miata Fuel: {round(Fuel)*100}% should work (it shows the fuel as a percentage, not as a unit value).

    one year ago
  • Profile image
    1,180 Miata

    @TheFlightGuySP what about showing the amount of fuel?

    one year ago
  • Profile image

    @Miata Multiply the speed value by 3.6 for kp/m and 2.2369362921 for mi/h.

    one year ago
  • Profile image
    1,180 Miata

    Is there a way to show the speed in kmh or mph?

    one year ago
  • Profile image

    @Narona can you shut up and stop "Oooh i recommend this stuff and this stuff this helps me alot, gO vIsIt ScAm.CoM"

    one year ago
  • Profile image

    nvm sorry guys i found IF statements exist

    one year ago
  • Profile image

    can someone explain how to make a text disappear with a switch
    like when i click a switch the text disappears and then i click the switch again and the text reappears

    +1 one year ago
  • Profile image

    @TheFlightGuySP Because ternary functions don't accept integers and characters as outputs simultaneously

    1.3 years ago
  • Profile image

    @SemedianIndustries Hmm... I'm not quite sure. I haven't messed with digital flight displays recently.

    1.3 years ago
  • Log in to see more comments