0
\$\begingroup\$

Whenever I finish running the project, this error message appears:

enter image description here

Blueprint Runtime Error: "Accessed None trying to read property jogador". Blueprint: Jogador_BP_Anim Function: Execute Ubergraph Jogador BP Anim Graph: Transition Node: Result

By clicking to know where the error is coming from, the program tells me this code:

enter image description here

This is the code I made to get the player reference (jogador/player Animation Blueprint):

enter image description here

This is basically for the transition code between animations, to receive information whether or not the player is jumping (jogador/player Blueprint):

enter image description here

Animations perform normally, so the error doesn't seem to compromise project execution, but why does it occur?

I looked at some links, but I don't know how to remove it.

https://forums.unrealengine.com/development-discussion/blueprint-visual-scripting/86607-accessed-none-trying-to-read-property

\$\endgroup\$
1
\$\begingroup\$

Do not ever dereference anything from any other classes In animation’s state machine. (You can dereference only in eventGraph).

First the reference may not be there yet when the animBP is running. Second, animBP state machine is designed to be multithreaded, but dereferencing any other class in BP is not thread safe.

TL DR: Do not use any bool variables from any other classes, all the state changing booleans should be within the animation blueprint itself.

Then set the booleans in anim’s BP EventGraph from any other class.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.