hi! i have a problem with AddDynamics
c++
UsciereTop->OnComponentBeginOverlap.AddDynamic(this, &ARoom::UsciereTopStart);
[....]
void ARoom::UsciereTopStart(UPrimitiveComponent* OverlappedComp, AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult& SweepResult)
{
if ((OtherActor != nullptr) && (OtherActor != this) && (OtherComp != nullptr))
{
AniPortaTopDx->PlayFromStart();
AniPortaTopSx->PlayFromStart();
}
header
UFUNCTION(BlueprintCallable, Category = Teletrasporto)
void UsciereTopStart(UPrimitiveComponent* OverlappedComp, AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult& SweepResult);
this is the error
Severity Code Description Project File Line Suppression State
Error C2664 ‘void TBaseDynamicMulticastDelegate<FWeakObjectPtr,void,UPrimitiveComponent *,AActor *,UPrimitiveComponent *,int32>::__Internal_AddDynamic(UserClass ,void (__cdecl ARoom:: )(UPrimitiveComponent *,AActor *,UPrimitiveComponent ,int32),FName)’: cannot convert argument 2 from 'void (__cdecl ARoom:: )(UPrimitiveComponent *,AActor *,UPrimitiveComponent ,int32,bool,const FHitResult &)’ to 'void (__cdecl ARoom:: )(UPrimitiveComponent *,AActor *,UPrimitiveComponent *,int32)’ HeoressDoodle D:\mrcso\Desktop\InCorso\Source\HeoressDoodle\Room.cpp 255