Successfully Using the Blueprint Interface with an Object Reference Variable

preview_player
Показать описание
Last tutorial we are doing on the Blueprint Interface. In this video, we show how it is possible to set the object reference variable and use that to make the call to the event on the receiving BP. We hope this saves you some time and frustration.
Рекомендации по теме
Комментарии
Автор

I am absolute babby when it comes to Unreal and NOT ONE other tutorial ONCE mentioned the Get Actor Of Class node. THANK YOU.

kylianthehylian
Автор

Thank god this video exists, 6 hours debugging why my i cant set my object reference until i realized because of this video that theres no "Object Reference" in the Editor since if you put two, the engine can't set one by default because it simply does not exist at this point. And even if at least one would exist, it would not work as soon as a 2nd is introduced.

DarkSession
Автор

I just could not think today. This saved me. Thank you!

cemeterygate
Автор

This wasn't quite the information I was looking for. However, there are many ways to get an object reference that doesn't require a hard reference, which will force load that object with your player character whether that blueprint is in a level or not. The hard reference will also run into problems--which class object do you want if there are multiple instantiations of the class? Get Actor of Class will return the first one it runs into, which will work if there's just one object of the class in the level, but not when there're multiple objects. You could use the Get All Actors of Class node, get all instances, find the one closest in the array, but there are implementations that can vastly simplify the same thing. For instance, consider using collision events (or something similar like a ray cast) instead, which has built into it a pin to return a specific object reference.

nexusg
Автор

omfg thank you so much that's litteraly what i was looking for, i couldn't set this fcking actor variable

qzerzae
Автор

I used the emission line in the character blueprint to trigger it, and then a problem that bothered me for a long time yesterday, I couldn’t pass the message anyway, about seven hours later, I found out that the model in the Actor did not collide, The reason why it cannot be detected. Brother your method is also very useful, thank you.🤣

MinecraftSioer
Автор

ROFL, the title of the series man :'D

Phoenix_VR
Автор

you legend, only thing that's worked for me

seantoal
Автор

Allright, so here is where am stuck at....I have a sphere collision...overlap all collision, when it overlap an actor, I need it to check if it has the interface? and if yes, does the text values match local values in my pawn? if yes, then get relative location of that matching actor, and if text change on that actor, to reset the target is, if I ran it on overlap, I get the location as a I need that location in realtime aka Event ideas?!

Phoenix_VR