How do I stop clipping through the floor

0 favourites
  • 7 posts
  • My player model and the enemy I made using the tutorial both have problems with clipping in the floor/getting stuck on it, and the enemy just falls through the floor entirely (Not to mention ignores the blocks I placed for him around his spawn point, oddly enough). I noticed this problem is especially bad when I stretch a tile to be larger than it originally was (going from 16x16 to 64x32, for example)

    I didnt give them hitboxes, because I wanted the entire sprites to also serve as the hitboxes

    Would this entire problem be averted by using boxes? I would much prefer to not use them. There is a link to what I've done so far, since I assume that directly looking at my work should make troubleshooting easier. (Also warning: I did get sound working, so there is a song in there. Its not too bad, just a heads up)

  • Oh, nevermind about the link to my file. Looks like I cant post those since I'm new x.x

    *Update* I found that if I use a lot of smaller blocks, opposed to fewer, larger ones, then I dont have this problem. But it annoying to have to use lots of tiny blocks.

  • You should check the collision-polygon of your sprites.

    Probably they change during animation so there somtimes are overlaps which cause the getting stuck.

    Using a "hitbox" can delete this problem.

    If you need the sprites to be the "hitboxes" just make sure all events other than the movement relate to the sprite.

    otherwise make sure the collision-polygon stays relatively the same during the animation so unexpected overlaps are avoided.

  • Huh, I didn't even know about the "collision polygon" settings, I might be able to fiddle around with them and make everything work properly. I'll definitely come back and say if it worked

  • Yes, that totally fixed it. Turns out, the problem was: When I stretched a block to make it large enough to easily land on it while moving, the collision polygons on the block got borked. As soon as I fixed the collision polygons, everything works fine

  • Ok.. cool!

    Good luck with the rest of your game!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Learn more with demos:

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