... prevent to get stuck (Runner) [Solved]

Discussion in 'How Can I...?' started by tweettopix, Dec 30, 2015.

Tags:
  1. tweettopix

    tweettopix Boxer

    Joined:
    Sep 30, 2015
    Messages:
    23
    Likes Received:
    8
    Hello dear BB-ers,

    I am working on an endless runner with game play settings "Runner". For some reason my player gets stuck once in a while; it stops moving. I have to press the "jump" key to continue running. I checked the collision boxes of my character and the platforms in debug mode, but I see no problem there. I tried to play with the settings but still the player gets stuck now and than. Is this a glitch? Is it better to use a circle collision box instead of a rectangle collision box in BB? I prefer a rectangle.

    Thanks in advance.
     
  2. Taimoor Javaid

    Taimoor Javaid Avid Boxer

    Joined:
    Oct 5, 2015
    Messages:
    274
    Likes Received:
    211
    Well a screenshot would be better to understand anyway in my case it's mostly due to collision shape.
     
  3. sysads

    sysads Serious Boxer

    Joined:
    Oct 8, 2015
    Messages:
    885
    Likes Received:
    353
    Funny enough, I am finishing a new game I started last week and I end up with the same issue where it gets stuck on the platform. Mine is also a square and as @taimoorjavaid45 said, its a collision issue mostly where the platforms from each scene joins.

    For me since I did not want to use circle, so the only hack I did was slight raise the character from the ground by a very very tiny inch, so a closer look it appears to be floating but during game play, it appears perfect.

    Well no one will spend time trying to see if the character is touching the ground, because the game would have been over before they know it :D
     
  4. todro

    todro Avid Boxer

    Joined:
    Sep 25, 2015
    Messages:
    151
    Likes Received:
    69
    Interestingly Trey mentioned in the Line Zen "Making Of" video that the squares and and their shadows were a performance killer and that was the reason why they switched to circles. Seems as squares dramatically increase the calculation complexity in certain scenarios
     
  5. sysads

    sysads Serious Boxer

    Joined:
    Oct 8, 2015
    Messages:
    885
    Likes Received:
    353
    Yea raise above the ground and test and see if it gets stuck. Yours might be something else if it happens again.

    Funny enough, I don't know if gravity will force it to touch the ground during game play :oops:
    Also good to check the height position of the ground between scenes. They must be the same value throughout. Not 100.00 in one and 100.00001 in another

    upload_2015-12-31_10-4-41.png
     
    Last edited: Dec 31, 2015
  6. Taimoor Javaid

    Taimoor Javaid Avid Boxer

    Joined:
    Oct 5, 2015
    Messages:
    274
    Likes Received:
    211
    @tweettopix screenshot of point where character stuck, everything looks fine here.
     
  7. sysads

    sysads Serious Boxer

    Joined:
    Oct 8, 2015
    Messages:
    885
    Likes Received:
    353
    I don't think this is screenshot during game. @tweettopix send screenshot when this gets stuck while enabling debug.
     
  8. Kevin W

    Kevin W Avid Boxer

    Joined:
    Sep 25, 2015
    Messages:
    368
    Likes Received:
    487
    Try adjusting your collision to this, that should do it :)
     

    Attached Files:

    playsgames6666 likes this.
  9. Taimoor Javaid

    Taimoor Javaid Avid Boxer

    Joined:
    Oct 5, 2015
    Messages:
    274
    Likes Received:
    211
  10. tarasgasparin

    tarasgasparin Boxer

    Joined:
    Sep 25, 2015
    Messages:
    46
    Likes Received:
    19

Share This Page