8-Direction Movement & Diagonal Collisions

0 favourites
  • 8 posts
From the Asset Store
Character Sprite Pack: Walk 4 Directions made in illustrator
  • Hi guys, I'm having a collision problem! My player sprite is moved with 8-Direction controls and I'd like my game to have a lot of diagonal walls (Solid behaviour). I'd like it if the player could 'slide along' the wall if you move up or down whilst pressing into it; it works fine to slide downwards along the wall, but if you attempt to slide UP the wall and press into it, the player collision object just stops dead. I realise this is a hard concept to describe, so I made a (very crap) illustration to help:

    And I have noooo idea how to get the upward diagonal motion I need. Does anybody have any ideas??

  • An exception was thrown rendering this comment. Engineers will fix this shortly!
  • Thanks for the link! However, I ran that capx three times and every time I managed to get the player sprite stuck in a wall almost immediately. It seems that it doesn't work very well?

  • Thanks for the link! However, I ran that capx three times and every time I managed to get the player sprite stuck in a wall almost immediately. It seems that it doesn't work very well? <img src="{SMILIES_PATH}/icon_e_sad.gif" alt=":(" title="Sad">

    sorry wrong capx... <img src="{SMILIES_PATH}/icon_redface.gif" alt=":oops:" title="Embarrassed">

    this

    https://drive.google.com/open?id=0BwNG7 ... 1dIcVRQNFE

  • An exception was thrown rendering this comment. Engineers will fix this shortly!
  • Hmm. On further testing it seems that I'm having a little problem with R0j0's collision system. For some reason it works perfectly well and smoothly when approaching diagonals from the side, but when colliding with something from above, my player sprite now judders uncontrollably. This doesn't happen to me in the original capx, just in my game. Any idea what might be causing this? Presumably it's something about my project that causes this, but I can't think what could possibly be a reason...?

  • An exception was thrown rendering this comment. Engineers will fix this shortly!
  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Im having the same problem in construct 3. the diagonal movements are stopping my character from moving. any fixes for construct 3?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)