Jumping Collision issue

shebhntshebhnt Member Posts: 74
edited July 2012 in Working with GS (Mac)
I do have a weird issue, to move my guy around I have it so that it changes the linear velocity of x to a certain number depending on left or right movement. It works great but I noticed that if my character is up against a wall and I am holding one of my directional buttons and jump, he has no forward movement once he is above the wall. I would expect that once he has nothing in front of him that he is colliding with the linear velocity would kick in and he would move forward but it doesn't seem to happen.

Also if he jumps and hits a wall, it's like it instantly turns his linear velocity to 0, any ideas on how to fix this?

Best Answer

  • CluvCluv Posts: 229
    Accepted Answer
    What rule are you using for collision, and what code is in your keyboard press and are you using constrain attribute by any chance? I just went ahead and changed that in the template, and it caused the problem you are talking about.

Answers

  • CluvCluv Member Posts: 229
    Does it happen when you are colliding with the wall, but not moving forward?
  • shebhntshebhnt Member Posts: 74
    @Cluv Yes, basically if I had my player come up against a small wall (one he could jump over) and he was close enough to touch it, then even if the player held down a movement key while pressing the jump button, they would only move up and down even after clearing the wall. Also if there is a ledge and the player is trying to jump up to it and hits the side, they immediately lose all forward motion and fall straight down.
  • shebhntshebhnt Member Posts: 74
    I was using "change attribute" to change the linear velocity of x to whatever I want but it seems that by changing it to "constrain attribute" it actually fixed it for me.

    @Cluv Thanks for the help!
  • CluvCluv Member Posts: 229
    Cool, sounds good.
Sign In or Register to comment.