Actor Fire Projectile ONLY WHILE in mid air

How to I make my player Actor fire a projectile only while he is not touching the ground?

Thank you!

Comments

  • Thunder_ChildThunder_Child Member Posts: 2,343

    Maybe when you "jump"...make a Boolean that becomes true...then make a rule in your fire button to include an attribute that when "jump" is true plus what ever ither attributes are true like when "fire" is also true to allow a bullet to launch

    Rule
    When "all"

    Jump is true
    Fire is true

    Spawn bullet

  • twozeroeighttwozeroeight Member Posts: 3

    I did that, but now it fires as soon as I make the next jump. Im trying to make it so the game only has one button, which both allows the player to jump, or fire their projectile. Press the button, and the player will jump. But if you press the same button while in the air, the player will fire the projectile.

    How can I make this possible

  • Thunder_ChildThunder_Child Member Posts: 2,343

    Ok. So then add a ruke inside the main rule...like

    When
    Jump is true

    Insert rule that says if button is pressed while jump is true to fire button...I think that would do the trick

    Make sure when when in collision with "ground" to turn jump to false.

  • twozeroeighttwozeroeight Member Posts: 3

    It still wants to fire as soon as I jump :(

Sign In or Register to comment.