Accessed None Error from reference node

Here is the full error message:

Error Blueprint Runtime Error: Accessed None trying to read property RefNode2 from function: 'ExecuteUbergraph_BP_TeleportNode_1' from node: Move Node 2 in graph: EventGraph in object: BP_TeleportNode_1 with description: Accessed None trying to read property RefNode2

Here is the section of BP_TeleportNode_1:

And here is the blueprint and event that are being referenced:

I have gotten this to work previously, and now I can’t get it to work, despite everything being set up the same. I’ve looked at other recent threads around this issue and haven’t found any solutions that I think would apply.

Did you set up a RefNode2 after spawning this actor?

Dunno exactly what this RefNode2 is, but I assume that it is a reference to scene actor.

  1. If you are placing this actor on scene by drag-and-drop from content box, then select placed object, find default properties and then select object for RefNode2

  2. If you are spawning it via SpawnActorFromClass node, then you need to use function SetRefNode2 and pass the reference to RefNode2 actor that is alreade on scene

Are you asking about when I created the blueprint,or it’s actual spawning in the game?

I did set up RefNode2 after creating BP_TeleportNode_2, but as far as during gameplay, I believe they are all created at the start of the level.

Perhaps you should set a value to your variable RefNode2 ?

Unfortunately I don’t have my work in front of me at the moment, but are you saying that I should set RefNode2 inside BP_TeleportNode_1 prior to getting the variable? (sorry if that’s obvious, I’m still learning)

Yes that is exactly what I am saying ;D
Right now it doesn’t have any value and you got the error “Accessed None trying to read property RefNode2” i.e. you’re basically trying to read an empty property. Or at least that’s my guess.

Don’t worry, I did the same mistake before, I had forgotten to set my variable with datatype pawn class to my pawn… Took me hours to realise it lol ;D

Okay, I think I understand. I’ll give it a try when I can, thanks!

Yes you are correct, the actor being referenced in RefNode2 is already in the scene and is not being spawned via SpawnActorFromClass

Although I didn’t find the solution to the problem I posted, I realized that what I really wanted to do was spawn the blueprint. I was able to get the spawning to work just fine. So thank you for your comment!

did you solve it? Cause i have similar problem and i tried to fill data into this reference variable, but it says that “Editing this value in a Class Default Object is not allowed”

thats a real shame cause there are lot of people saying that we have to set this reference and fill variable, but i dont understand how can i set it if i cant use reference, etc. anyway, good luck with your project and im going to continue my search…

Sorry I did not, I found a kind of work around that was specific to my project. When I did try this, I got the same error you referenced.