MyActor.h
UCLASS()
class FPS_API AMyActor: public AActor
{
GENERATED_BODY()
...
public:
UFUNCTION(NetMulticast, Reliable)
void MulticastRPCMyFunction();
...
}
MyActor.cpp
void AMyActor::MulticastRPCMyFunction()
{
UE_LOG(LogTemp, Log, TEXT("Message"));
}
When i compile my project, i can check the error message below. Compile error
*.gen.cpp.obj : error LNK2005: "public: void __cdecl *::MulticastRPCMyFunction(void)" (?MulticastRPCMyFunction@*@@QEAAXXZ) already defined in *.cpp.obj