I made point collision instead box and works even better. You can see the points I used in the green box. Two yellow pixels for foot, four red pixels for the sides (2 left and 2 right) and two lime pixels for read. The green box is just a placeholder sprite sprite not a collision box
the advantage of this method is because is:
- easier to detect collision direction
- easier to implement coyote jump
- easier to implement trick to avoid hit the head against corners when try to jump
- easier to say when is touching ground or wall or ceiling