Branch doesn't work; Blueprints

Hello Guys, I’m very confused using the Blueprints.
That you guys know what i want: The Player is walking through an component (weapon) and picks it up.
As u see, the Blueprint logic goes through an Branch and it detects the current Boolean as False (default), so it does the whole PickUp-Thing, sets the Boolean to True and prints something. To this point everything works great. The Character picks up the weapon and prints the string. But if i now move the character over another weapon, it still picks it up, but it shouldn’t. The Branch should detect that the condition is now true, and it does (i once let it print something from the true part, and it worked). But after that it still performs the false section, although it shouldn’t…
I hope you guys understood what i meant ^^ (I’m from germany and my english is quite terrible :/)

If i let the Blueprints show while playing, everything looks normal and it runs, as i want it to (just the Blueprints animating) but the game just performs as if the condition was FALSE, although it is showed as TRUE.

In my opinion, the Branch works in this case wrong… Or am i completely wrong with everything? ^^

It’s hard to explain though :X

Greetz ExR4y

S4me here!

In order to do what you want you should set/get that variable in your character BP so that every instance of that actor knows it’s value.

Like so:

Sorry, but how do i get the “Converter” between the “Cast to BP…” and the Branch?

Drag from the blue pin(As BP Player Pawn) and then type the name of your variable.

I just checked again, and my blue “Cast to” looks quite different from yours… how did you get this?

Right click on the cast node and Convert to Pure Cast.

Ok i got it, but i still cant get this node between the Cast to and the Condition… If i type in how my variable is called, it doesn’t find anything or (if i unselect this context sensitive) just the normal variable without this blue Target…

Can you post a screenshot please?

the variable is called is attached…

63953-fehler2.png

You are casting to wrong BP. You should cast to your character BP, not Anim.

63954-fehler3.png

But those are the only things we can choose, there is nothing for the character, right?

And sorry I ask so dumb ^^ I’m quite new to UE4 :smiley: And thanks for your help

Mixamo goblin’s character BP is called Mixamo_Goblin i think, so search for goblin instead of bp.

63957-fehler4.png

Hm, it doesn’t find just Mixamo_Goblin… And with this Master thing it doesn’t work…

Well then go to content browser and find out where the character BP is for the goblin and what it is named. I thought you already knew that since you were already using that character when you posted the question and (assuming) you already created a bool variable in it.