Simple problem with timeline tracks

I can do a simple linear smooth crouch using the timeline but It’s kinda hard for me to do the way that I imagined, cause I wanted to start slow then It would speed up a bit and the ending would be slow too, so it could be really smooth, but I can’t find the right placing for the keys in the curve, cause right now It only starts slow but It doesn’t end fast.

Hey there @kHynnS!

Do you think you could give us some visuals? Throw us some screenshots of your timeline?

Is this a sequence or is this a timeline Bluprint node you’re using?

Get back to us soon! :slight_smile:

Key 1 (Time: 0.0, Value: 0.0)
Key 2 (Time: 1.0, Value: 1.0)
Length: (time in seconds for the full transition)

Select Both Curve Keys, Right click on one of them select Auto. This will curve both ends. Adjust the curves as needed.

Here’s the blueprint.

And the curve.

The problem is in the image above. The crouch is working as it should be in the start and middle, but isn’t slowing down in the end. I’ve tried everything but still no solution.

It didn’t work… at least not in the end.

@kHynnS Try extending the timeline out to about 5 seconds for testing purposes so you can see what’s happening more clearly. All I’m seeing is it’s adjusting the half height of the collision capsule, is that what you’re meaning to do?

Also the capsule needs to have somewhat of a height, so you might want to change your lerp to A96, B48

2 Likes

Lerp B value can’t be 0.0 for CMC capsule. Half Height value cannot be any less than radius.

Also, Are you replicating this logic on the server? If, not you should be.

Regardless I’m positive the Timeline itself works. Test it on a mesh… scale it up/down.

1 Like

Yes, that’s what i’m trying to do. Like you you told me to do, the lerp B value being less than 70,0 was causing this problem and I don’t know why, probably cause i’m new with blueprints. But now it looks like my character is crouching less than before, is there any way to change how much the character crouches?

Yes, the timeline was right I tested it on an elevator and worked fine. Like I said, I’m new so what would be replicate the logic on server?

@kHynnS Just in case Rev doesn’t get back soon, Replication is online-play stuff, if you’re making an online game that will matter, if not then don’t worry about it.

So what you’re doing is shrinking the collision of your character here, you aren’t making them crouch, or play an animation, or anything like that. If you have your character visibly crouch, that’s going to be in your Animation Blueprint, not here. Maybe the issue is that you’re looking in the wrong place and it isn’t this code here at all?

I get it, but If I wanna crouch I need to make my character’s collision smaller in order to get through spaces that wouldn’t be possible If the capsule wasn’t smaller right? And the timeline wasn’t afecting the unreal’s crouch, so that was the way that I found.

If you are using CMC why aren’t you using the built in crouch/uncrouch functions?

I tried that using the timeline, but he wasn’t crouching smoothly.

The crouch functions already scale the capsule along with a lot of other checks, plus it replicates to other clients.

You should adjust your animation for crouching.

1 Like

I’m gonna try that, but not 100% sure how.