WTF Is? A Pure Function

preview_player
Показать описание
What is a Pure Function in Unreal Engine 4 Blueprints?

Рекомендации по теме
Комментарии
Автор

I spent so long studying tutorials and the API trying to figure this out and got no where. Thank you so SO much for doing these tutorials. You have no idea how much you're helping. :)

NeonFraction
Автор

Finally a decent explanation.
So a pure function is called EVERY time a node it connects to is called.

KvaGram
Автор

Your videos are incredible, I was fighting with how to best organize the pipes of a function that i was constantly needing in different graphs and 68 seconds into your video I was done with this, thank you so much!!!

arielquinteros
Автор

How come the 'Find' node for Blueprint Maps is pure when it has two outputs? If I wanna check if something was successfully found, and then use the value found, that's two find calls! Seems so inefficient to calculate the find twice.

ReOp
Автор

Great video, please turn the treble down on your mic though. Sometimes it feels like someone is stabbing me in the ear with a knife.

unrealdevop
Автор

Great explanation - just a note- the Pure function should not have been marked as Pure, and this rule isn't enforced, but it's considered a bug to do as shown.

From the docs - "Pure Functions promise not to modify state or the members of the class in any way."

So changing the Input Variable as shown shouldn't be done in a Pure function, but beware, since it could be done.

Edit: Although there's a difference between Pure Const and just Pure - so if the variable modified was not a Class member, that is, just a local variable, then it may have been technically Pure, but I would still avoid doing this.

stephenmontague
Автор

If I understood correctly, you say pure functions does not have any inputs, right?

naghekyan