Getting "Accessed None" error in Blueprints

Hi there, I’m trying to make a simple Breakout like game in UE4, but every time I try to launch the ball I keep getting an error message,

the error message is, “Blueprint Runtime Error: “Accessed None trying to read property Ball”. Blueprint: BP_PlayerPaddle Function: Execute Ubergraph BP Player Paddle Graph: EventGraph Node: Branch”

This is the blueprint in question, I don’t know what “Execute Ubergraph” is, it’s not a function I have anywhere in my blueprint.

I just don’t understand why it’s not working and it’s totally swamped me.

Any help would be greatly appreciated,
thank you.

Likely you never set the “Ball” variable before using the reference. Check out video #27 in the link below, I discuss the “accessed none error” and how to fix it.

When using the AND node it will try to read both variables so the IsValid node becomes redundant. Use the IsValid Macro instead ( the one with ? ). You can also right click “ball” and select “Validated Get”.

Two years late :

Blueprint is not like C++ in this regard : both inputs to your AND node will be computed regardless of the value of the first pin, so, in any case, the Active property from the Ball object will be read, even if Ball is null.

If you want to avoid this situation, use an IF VALID node and only read the Active property down the “Is Valid” exec pin.