0 Favourites

[Custom Mvmnt] Ground collision help

This forum is currently in read-only mode.
  • I'm making a Mario game with custom movement, and I've run into an issue with landing. This is a small problem, but a bothersome one: I have it so that when he overlaps the ground at an offset of one pixel above, it sets his vertical speed to zero, but he almost always ends up one or two pixels into the ground.

    It's never constant, though, so I can't just fudge the collision offset until it works. Obviously, I need a better way of telling when he lands and how to keep him even with the ground, but how?

    .cap: http://dl.dropbox.com/u/19702035/mariosonic4.cap

    EDIT: New question from a few posts down: is there any problem with using a combination of Platform behavior and Custom movement? All this jumping and landing stuff would be taken care of by the Platform behavior, but I'd make everything else -- speed/acceleration and whatnot -- custom. Would that work out if I did it right?

  • Couldn't get the event sheet to load for some reason. Crashed every time.

    So without actually looking at it I suggest updating the collision mask, and suggest that its a frame rate issue.

  • Construct 3

    Buy Construct 3

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

    Buy Now Construct 3 users don't see these ads
  • Really? Weird, that's the only thing that HASN'T been giving me problems. Try it again, I uploaded a slightly newer version(same URL).

    Now I've figured out a way that makes sure he always lands evenly with the ground, but it only works for the ground, not platforms -- there's no mystery why, but I can't come up with anything else.

  • Oh, and I just thought of a somewhat related question that I might as well ask here: is there any problem with using a combination of Platform behavior and Custom movement? All this jumping and landing stuff would be taken care of by the Platform behavior, but I'd make everything else -- speed/acceleration and whatnot -- custom. Would that work out if I did it right?

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