Hello!
So, recently i started to implement a C++ Interface for damage dealing. i got the code finished and working however, no matter what i try i cant get my interface event to show up on a blueprint, it only shows (the interface ) as a function
This is my interface
#pragma once
#include "CoreMinimal.h"
#include "WBDamageInterface.generated.h"
class AActor;
class AController;
// This class does not need to be modified.
UINTERFACE(Blueprintable)
class UWBDamageInterface : public UInterface
{
GENERATED_BODY()
};
/**
*
*/
class WOODBOUND_API IWBDamageInterface
{
GENERATED_BODY()
// Add interface functions to this class. This is the class that will be inherited to implement this interface.
public:
UFUNCTION(BlueprintCallable, BlueprintNativeEvent, Category = "DamageInterface")
void WTakeDamage(float Damage, AActor* DamageInstigator, AController* InstigatedBy, FHitResult& HitInfo);
};
void IWBDamageInterface::WTakeDamage_Implementation(float Damage, AActor* DamageInstigator, AController* InstigatedBy, FHitResult& HitInfo)
{
}
And this is the Character Class im adding the interface to
#include "CoreMinimal.h"
#include "WBDamageInterface.h"
#include "GameFramework/Character.h"
#include "WBCharacter.generated.h"
UCLASS()
class WOODBOUND_API AWBCharacter : public ACharacter, public IWBDamageInterface
{
GENERATED_BODY()
public:
// Sets default values for this character's properties
AWBCharacter();
virtual void WTakeDamage_Implementation(float Damage, AActor* DamageInstigator, AController* InstigatedBy, FHitResult& HitInfo) override;
void AWBCharacter::WTakeDamage_Implementation(float Damage, AActor* DamageInstigator, AController* InstigatedBy, FHitResult& HitInfo)
{
}
All good right? However, once i fired up the editor, opened a blueprint thats a child of the WBCharacter class, the interface DOES show up but ONLY as a function, i cant implement an event for it. which is what i want to do so i can dictate how the character should react to the interface ( damage dealing)