Velocity stops after Collide

I have a character with the camera attached to them and a velocity behavior attached to them to get them to automatically progress forward (think a runner style game). My issue is if the character runs into a wall (or obstacle) and THEN jumps, even though they can clear the obstacle, they no longer progress forward automatically. Is the velocity action automatically removed?? I notice this doesn't happen if I use the acceleration behavior, but I want my character to move at a constant speed.

Thanks for any help!

Comments

  • FallacyStudiosFallacyStudios Member Posts: 970
    edited August 2013
    Another option instead of Velocity that you can try is to Change Attribute Actors Motion Linear Velocity X to a number. You will also have to set your jump to a number on Motion Linear Velocity Y so that your hero will jump and move at the same time.

    Keep in mind if you use this, you will need to set their Motion Linear Velocities to 0 when they aren't moving left or right or jumping/falling.
  • CatGoneCrazyCatGoneCrazy Member, PRO Posts: 90
    You could also set the hero's acceleration attribute to be extremely high, but limit it with the 'max speed' attribute within the actor. That way, it would go from stationary to moving pretty much instantly as soon as the obstacle is cleared.
  • CatGoneCrazyCatGoneCrazy Member, PRO Posts: 90
    That way, you could also raise the limit of the max speed threshold as the level progresses, making the game faster and faster.
  • mesaticusmesaticus Member Posts: 51
    @FallacyStudios. Awesome that did the trick. I ended up giving the character attributes to determine it's direction, then using the Motion Linear Velocity behaviors as suggested and checking against the direction I was able to achieve the control I wanted.

    @CatGoneCrazy. Oh I like that too. Being able to make the game more difficult as it goes along seems like a plus.

    So that's one bug down...time to figure out the others :) Thanks to you both for the help.
Sign In or Register to comment.