Whenever I crouch so does player 2.
The crouch is being activated by a boolean being set to true whenever ctrl is pressed then set to false whenever ctrl is released (this is being set in the third person character blueprint), then in the animation blueprint the third person character blueprint is being called and a branch is asking whether or not ctrl is being pressed if so set crouch to true.
All works fine for a single player game how would i go about making this available for a multiplayer game.
Post a screenshot of the BP. Hard to diagnose otherwise. Sounds odd… is the crouch called from the Player Controller? If not, are you somehow replicating or casting to all Third-Person BP?
Screenshots!
I have done nothing other than this
the first picture is in the Third-Person BP and the second is on the AnimBP
Unreal has a built-in crouching system. This is very easy to use after setting up an action input. Set this up in your project settings and add these nodes to your character blueprint and it should work correctly with all local players. You can adjust the crouch height of your players in the character movement component of your player blueprint.
This is the best method, I tried my own Blueprint crouch system and hit endless problems with collision, Guess it’s possible but the Built in crouch is flawless and has tonnes of different choices of customizing it.
Yeah i understand, but will this work with a third person game??
Honestly, in third person, wouldn’t this be more of an animation than a crouch system? You would have to play your crouch animation when your player hits the crouch button, thus allowing all of the other players in the game to see that the character is crouching. If it is a first person game and the other players are simply seeing you crouch from afar, use both the animation (for the other players in the game to see the crouch) and the very simple crouch blueprint (so the player who is doing the crouching can see that he is crouched).
I found out why I was casting to the player character instead of trying to get pawn owner.