0 Favourites

How do I Get total/resultant velocity?

  • The Physics behavior has these expressions: "VelocityX" and "VelocityY", and it has a condition for "Compare (total) velocity". However, I can't see a way to get the value for "total velocity" itself .

    I've looked up the formula online but can't wrap my head around it. They seem to be teaching how to get Vx and Vy, given the total/resultant velocity and angle while in C2, it's the other way around, i.e. the Vx and Vy are known and the total/resultant velocity (while seemingly known since there's a condition for it) is not accessible to the user.

    I need to know how to get total/resultant velocity given Vx and Vy. Thanks in advance!

  • High school math class: the hypotenuse is equal to the square root of the sum of the squares of the two opposite sides. Speed being a direct derivative of distance, we can surmise that the same is true for speed also. Therefore:

    Speed = sqrt( ( VelocityX^2 ) + ( VelocityY^2 ) )

    [ Edit: in honesty I had to Google this, but did so by Googling 'converting two vectors to velocity' - which is as embarrassing for me as it should be for you ]

  • Construct 3

    Buy Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Buy Now Construct 3 users don't see these ads
  • High school math class: the hypotenuse is equal to the square root of the sum of the squares of the two opposite sides. Speed being a direct derivative of distance, we can surmise that the same is true for speed also. Therefore:

    Speed = sqrt( ( VelocityX^2 ) + ( VelocityY^2 ) )

    [ Edit: in honesty I had to Google this, but did so by Googling 'converting two vectors to velocity' - which is as embarrassing for me as it should be for you ]

    Yeah I am glad you added that edit as I knew there was a formula I learned in engineering but no way I could pull that out and drop it without looking it up first lol!

  • You can also use the distance expression, after all it's the same equation.

    distance(0,0,velocityX,velocityY)

  • Thanks! Yes, it's embarrasing The distance thing is very helpful as well!

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)