Sprite Overlap

Hello guy,

Im trying to Delegate my ovelaping function but i dont know why i cant,

.h

UFUNCTION()
	void HitOverlap(class AActor* OtherActor, class UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult& SweepResult);

.cpp

GetSprite()->bGenerateOverlapEvents = true;
	GetSprite()->OnComponentBeginOverlap.AddDynamic(this, &AIndieCharacter::HitOverlap);
	GetSprite()->SetIsReplicated(true);

Im still getting this error

This is something that i’ve made before in the same way, but this time is’nt working, i don’t know why, maybe is because im working with sprites.

Please help me