How do I fix a collision issue in 4direction movement?

0 favourites
  • 7 posts
From the Asset Store
Run and Jump in 3 Dimensions! Take your platformer to the next level!
  • Hello everyone,

    I have started recently to use Construct 2 and I' m trying to make a skating like movement but my object collision, with the 4direction behavior, stops randomly a few pixels before solid block. Sorry if I bother you with stupid questions (I'm trying to learn) and also sorry for my poor english.

    Here is the .capx[/code:39wkei88]
  • Have you checked your collision box in the sprites animation frames, maybe they need adjusting?

  • I'm not sure if the problem is only an adjusting.

    Theoretically, everything are ok. That should not be happening.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • How odd.

    Try using the bullet behavior instead and see if it happens.

    Have it change the angle of motion depending on which key you press, and stop moving once it hits a wall.

  • justifun, thanks for the advice.

    Now my problem is that my player remains stuck on solid blocks and I can't give directions anymore.

    I know that I have define to disable bullet behavior when playerBox is on collision with Block but I can't find a way to continue with code.

  • Is it possible to be a bug? The first one.

    Perhaps the right is to report it but I' m afraid if it is my fault.

  • I'm having the same problem as your original post.

    Sometimes the hero will stop right at the solid block, and other times he will stop 1-6(ish) pixels away and refuse to get any closer.

    I'm (kinda)trying custom movement right now, and collision detection is giving me a headache. I'd rather if I could just get the 4way direction movement to work properly for me. =(

    As for the bullet movement you are trying, I'm not sure if you need to check for collisions, but if you do, disabling the bullet is not what you want to do. That basically turns off the bullet behavior for that object. Instead try setting the speed to 0.

    Also, you might(maybe) need to use "Overlapping at offset" to check for collisions before they collide, but that could be totally wrong, I'm still very new to Construct 2.

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