How do I add slide along solids for top down movement?

0 favourites
  • 2 posts
From the Asset Store
3 different games for kids, easy to edit, mobile ready
  • Hi there,

    I'm trying to make an object slide along solids in a top down RPG style game.

    Using the 8-Directional movement behavior, the player stops on an angled solid and does not move.

    I'm looking to have it 'slide' along in the same way Godot's 'move_and_slide' function works, or similarly to the 'car' behavior (though I find that one is particularly glitchy around sharp corners)

    I found a few posts discussing this topic, most useful one being this one here:

    construct.net/en/forum/construct-2/how-do-i-18/8-direction-behavior-slide-95148

    But I find this is far too complex for a top down RPG where I just need a simple 45-degree ramp.

    I also found the following suggestion:

    construct3.ideas.aha.io/ideas/C3-I-1403

    One of the comments states to combine the platform behavior - I tried this with the 8-directional but the platform movement does not take over for sliding, and the platform behavior does not work with steep slopes.

    Is there a simple solution here that someone can recommend?

    Any advise is much appreciated!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • For anyone that may come across this topic in the future -

    This can be solved by implement a physics based movement system. Use nothing but the physics behavior on your player character (no platform/8-way, etc.) and implement custom movement

    I'm directly setting the velocity but you can probably do this with impulses and forces depending on the game feel you're going for

    Colliding game objects / walls will then need to also have the physics behavior but be immovable. This is probably a non-insignificant performance hit so develop accordingly..

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