Download

Interface Example is errornous

This Doc Page is errornous:

https://docs.unrealengine.com/en-us/…nce/Interfaces

Under** Interface Declaration**, the second code sample is like this:



     /** React to a trigger volume activating this object. Return true if the reaction succeeds. */    
UFUNCTION(BlueprintCallable, BlueprintImplementableEvent, Category="Trigger Reaction")    
virtual bool ReactToTrigger() const; 

this is wrong. The compiler will throw an error that "BlueprintImplementableEvent"s should not be virtual

@Raildex_ Thanks for reporting this issue! I will pass this along to the appropriate contact here at Epic Games.

Meanwhile… How do I declare an Interface Function that is callable and implementable in Blueprints?

Hi Raildex_,

My colleague has updated the docs - it looks like the use of BlueprintImplementableEvent was incorrect.



     /** React to a trigger volume activating this object. Return true if the reaction succeeds. */    
     UFUNCTION(BlueprintCallable, Category="Trigger Reaction")    
     virtual bool ReactToTrigger();


https://docs.unrealengine.com/en-us/…nce/Interfaces