playMaker

Author Topic: Jump (fall down speed) [Solved]  (Read 677 times)

LuminRabbit

  • Full Member
  • ***
  • Posts: 161
  • Lumin Rabbit
Jump (fall down speed) [Solved]
« on: January 17, 2021, 08:06:34 PM »
I have a 2d sprite when I click the left mouse button it jumps. Im trying to get it to have a faster fall down (return to ground) speed than the default.

So far I've figured out:
1) jump
2) how to know when it gets to its max height (float compare) it will go to "State 1" in the attached image.
3) I NEED YOUR HELP and I've pasted code below that should make this possible (Im having difficulty converting it into usable playmaker states, though Im open to other solutions as well)

Code: [Select]
rb.velocity += Vector2.up * Physics2D.gravity.y * (fallMultiplier - 1) * Time.deltaTime;I've tried many different approaches with no success...
 
« Last Edit: January 18, 2021, 08:10:30 AM by LuminRabbit »
Have I said how much I love playmaker!!! This is one amazing tool

LuminRabbit

  • Full Member
  • ***
  • Posts: 161
  • Lumin Rabbit
Re: Jump (fall down speed)
« Reply #1 on: January 18, 2021, 08:10:13 AM »
Solved, I just set the velocity to a negative number and it seems to work :) instead of all that crazy math (that I don't understand :))
Have I said how much I love playmaker!!! This is one amazing tool