Collision Issue while moving on a Tilemap

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By alphaa
:warning: Old Version Published before Godot 3 was released.

So, I made a tileset following the docs’ tutorial on that closely and used it in a tilemap node. The issue is that my player (a rigidbody in character mode (though the issue is the same in rigid mode) with a rectangle collisionshape) gets stuck while moving along a surface of that tilemap. This happens seemingly randomly as its not in the same spots all the time but rather everywhere and then again sometimes doesn’t happen at all. Is this something I can fix or do I have to use a workaround?

Things I’ve tried so far:
-Double, triple and quadruple checked the original scene that was converted to a tilemap. Yes i used snap, and yes everything is aligned properly (as I googled this issue some had it too but it was fixed when they fixed their tileset or the used a workaround). Btw the tileset scene uses staticbadies and rectangle collisionshapes (same as my player but static).
-Using Cillision polygons instead of shapes but the issue persists much the same.
-I also tried to extend the x portion of the collisionshapes for the tiles by a pixel so they would clip into each other when being next to each other, didnt help either.

Workarounds that I found while browsing this issue but can’t use for in the following explained reasons:
-Instead of a rectangle let the player have a rayshape as collision shape. It works but I can’t use that for my game, because the playier is a spinning Square and therefore would need rayshapes in all 8 directions to cover all possibilities. This results in the same issue named above.
-Round up the edges of the collision rectangle of the player. This just shifts the problem as in the player doesn’t get stuck anymore but now randomly makes jumps while moving along the surface.
-Remove the collision shapes of the tiles and make collsision with large “whole” collission shapes afterwards. As this would probably be the least problematic workaround it would still cause a lot of unnecessary work and would make revisiting and tweaking levels a real pain in the ass. Additionally friends of mine who are not into godot could easily create levels with a set up tilemap couldn’t without me always doing collisions for them. Which still leaves the pain-in-the-ass tweaking problem.

I would be really grateful if someone could help me here. Sorry for so much text and sorry for the fact that I am basically reasking a question.

Edit: Just if it is relevant: I’m on Godot 2.1.3
Edit2: a mini project which recreates the issue
https://cdn.discordapp.com/attachments/212250894228652034/353510877355573252/The_TileMap_Issue.zip

how do you move the rigidbody? i amassuming this is in 2D
if you are just using move() it will stop coz the contact of the floor or a wall will register as
a collision assuming its moving flat in the ground.

you might want to check this out
Kinematic character (2D) — Godot Engine (stable) documentation in English

but if you are moving like a square wheel on the floor and you are using the
translate rotation and nor the physics rotation, the square object will rotate first before it can detect a collision making the square stuck between tilemaps.

hope you find whats causing your problem. im also curious on whats happening. good luck

LainVohnDyrec | 2017-09-10 18:46

thank you for your answer, ive moved (no pun intended) to a kinematic character which doesnt have those issues

alphaa | 2017-10-01 12:05