Hello guys,
I’m trying to make method for binding with FCoreDelegates::OnMountPak delegate. If I’m binding this delegate with lambda in .cpp everything is ok, but when I’m trying to declare a function with the same signature (as lamda) in header I have compile error:
#pragma once
#include "GameFramework/GameMode.h"
#include "GenericPlatformFile.h"
#include "MyGameMode.generated.h"
UCLASS()
class MYGAME_API AMyGameMode : public AGameMode
{
GENERATED_BODY()
public:
AMyGameMode();
virtual void BeginPlay() override;
UFUNCTION()
bool HandleMountPakDelegate(const FString& PakFilePath, uint32 PakOrder, IPlatformFile::FDirectoryVisitor* Visitor);
//compile error: Cannot find class 'PlatformFile', to resolve delegate 'FDirectoryVisitor'
}
It’s very strange because IPlatformFile is declared in “GenericPlatformFile.h” but it’s included… Please help me to resolve this frustrating issue.
Thanks!