- Home /
character controller sinks into platform while using raycast to detect collision
hey , I am making a 2d character controller without a rigidbody2d (metroidvania style) , I am using ray cast to detect my collisions .
the character sinks into the ground most of the times , I initially thought that this has to do something with raycasting in the update function , i tried to search if raycasting in fixed update will improve the situation comapred to update function , but that didnt solve my problem.
Then I tried to change the timestep value to help the situation it still sinks into the platform .
I then tried to follow a tutorial and do it ( sebastian lauge 2d platformer tutorial) , but that still resulted in the same situation , the character is sinking into the platformer .
I am trying to search a fix that would help , the only fix i found is changing the penetration penalty value but that would cause jittering , which not really ideal situation considering the problem i currently have ,would be counter productive to add more problems on existing problems.
what are my options , is there any other solution , am i doing something wrong , should i stick with rigidbody and the end the pain of breaking my head to get the collisions working
Your answer
Follow this Question
Related Questions
Platformer movement using Unity physics 1 Answer
2D movement that allows 2 or more forces.,2D movement that allows to have 2 different forces. 0 Answers
2D 360 degress platformer example needed 0 Answers
Enemy shakes on Y-axis when is moving straight on the X-axis 0 Answers
Which is best for optimization 1 Answer