I’ve been working quite a lot on this game of mine. I still do have the animation blueprint, in fact, I’ve expanded quite a bit on what I had before.
Here’s the logic on the player character.
And here’s that crouching logic. Basically, you need to set a boolean variable (Crouching) that replicates with RepNotify. You have to set it both in the owning client and in the server. Apart from this, you have to run the set relative location and set half height function in the owning client and the server as well. In the rep notify function, you have to do the same thing, that is, setting the relative location and the capsule half height again. In the animation blueprint, you just have to cast to the player character script and get the Crouching variable.