I am making a game similar to the “PlatformerGame” in the learn tab except I am doing it in 2D. My sliding action works great but I just can’t get the capsule half height to work properly without glitching into the ground. So after researching I took a look at the “UnrealStickFigure2D” example and tried to set the “Crouch maintains base Location” variable with the Half Height but it still keeps shrinking the capsule towards its centre and not towards its base.
What am I doing wrong?
I’ve been wondering about the same thing. It looks like the only work-around is to move the children of the collision capsule, which is very impractical once you have a certain number of child components.
I am using 4.14.1 right now, and the “Crouch maintains base location” node still does nothing. The option is disabled on the character movement details as well.
I am also having this issue. I can not figure out why the option is even greyed out in the character movement section. Even if I call and set the boolean in the event graph it still won’t work properly.
I am currently using 4.14.3
Hey, so I got it to work by just copying the nodes from the Paper2D project example and plugging it into my characters crouch event. Just needed to set the values relative to my project and voila!
Would you mind sharing a picture of it?
Sure man, the one picture is screenshot from the paper2D example content and the second one is my workaround. The other two show my event graph checking the crouch variable and then playing the timeline. The last image is the timeline, you ctreate a float track, (1)then set the time to the time that your crouch animation length is, (2) the first keyframe should be at 0 time and the height of the capsule, the second keyframe should be the time at the end of your anim and the desired capsule
height when crouched.
You can use timelines for plenty of things, you can now add a vector track and using the same principle move the capsule to the ground while changing its size.
Hope this helps.
PS. I also just copied the Paper2d project nodes to my project and the “Crouch maintains base Location” works now.alt text
Sure man, the one picture is screenshot from the paper2D example content and the second one is my workaround. The other two show my event graph checking the crouch variable and then playing the timeline. The last image is the timeline, you ctreate a float track, (1)then set the time to the time that your crouch animation length is, (2) the first keyframe should be at 0 time and the height of the capsule, the second keyframe should be the time at the end of your anim and the desired capsule
height when crouched.
You can use timelines for plenty of things, you can now add a vector track and using the same principle move the capsule to the ground while changing its size.
Hope this helps.
PS. I also just copied the Paper2d project nodes to my project and the “Crouch maintains base Location” works now.alt text
LOL i messed up the copy/paste there with the images displaying between the text, sorry for that. Let me know if you need anything else and if something is unclear