Profile image

How to detect if a plane is moving backward?

7,446 FeiWu  4.2 years ago

The funky trees variables still return a positive value if a plane is moving backward. So is there a way to detect if a plane is moving backward?

  • Log in to leave a comment
  • Profile image
    6,867 Diver

    @FeiWu ohhhhhhh..... Thanks!!!!

    4.2 years ago
  • Profile image
    7,446 FeiWu

    @Kreep2knight in the JointRotator menu, add damperMultiplier and set it accordingly. Keep increasing until it does not wobble.

    4.2 years ago
  • Profile image
    162k spefyjerbf

    Ah. Snowflake beat me to it haha

    +1 4.2 years ago
  • Profile image
    6,867 Diver

    @SnoWFLakE0s thanks, err do you know how to prevent rotators from wobbling during high g and heavy weighing connections?

    4.2 years ago
  • Profile image

    @Starbound XD, but i manage to fly a lot of my planes backward, and both jets and propellers!

    4.2 years ago
  • Profile image
    12.1k Starbound

    If the pointy end is not facing the wind it's usually a bad thing

    +1 4.2 years ago
  • Profile image
    67.1k SnoWFLakE0s

    @Kreep2knight
    .
    Actually, I was horrible at programming and anything CS before FT! Wrap your head around it once and you never forget. If you really need one I can explain things to you.

    4.2 years ago
  • Profile image
    6,867 Diver

    @SnoWFLakE0s I can't wrap my head around FT. I read your webpage. I know algebra obviously but I don't know booleans or almost everything else and I have no idea how to use them. But I do XML quite a lot, but I just ask around when I need help for XML.

    4.2 years ago
  • Profile image
    7,446 FeiWu

    @47parzival41 I’m in algebra 1 a year early right now XD

    4.2 years ago
  • Profile image
    67.1k SnoWFLakE0s

    @47parzival41
    .

    Are these boolean operators? As in if I put VTOL>0.5 I will get a "1" when over 0.5 and a "-1" when under 0.5?

    .
    TL;DR: Yes and yes. Your logic is spot-on.
    .
    The comparison operators are as math works anywhere else. Specifically, the non-inclusive comparison operators- < and > - mean that if the value is equal, it is still untrue because it is non-inclusive. There's also the inclusive operators- <= and >= - which will behave the same as the non-inclusive operators but when compared values are the same, the operator will return true because it is inclusive.
    .

    Will it round up like with the round(x) function?

    .
    Comparison has nothing to do with rounding. It will behave as outlined above.
    .
    These are great questions, hope I helped.

    4.2 years ago
  • Profile image
    7,446 FeiWu

    @SnoWFLakE0s nice

    4.2 years ago
  • Profile image
    67.1k SnoWFLakE0s

    @FeiWu
    .
    You can start with sign(AngleOfAttack) < 0. I'll get to you if you need something more sophisticated.

    4.2 years ago
  • Profile image
    7,446 FeiWu

    @SnoWFLakE0s More specifically I want to turn on a light when a car is reversing. Is there a way for that?

    4.2 years ago
  • Profile image
    67.1k SnoWFLakE0s

    @47parzival41
    .
    Depends completely on the context. I have special code that calculates the tank turret orientation and checks which direction the tank is moving in. If that's what's being wanted here, I definitely can help.

    But fundamentally, you're going to have to use the variable AngleOfAttack in order to determine your movement direction.

    4.2 years ago
  • Profile image
    69.4k Chancey21

    Answer: Multiply it by the AngleOfSlip values

    4.2 years ago
  • Profile image

    I am pretty sure that in really old versions of SimplePlanes, if you went backwards I would read -mph

    +1 4.2 years ago