Hello there
I am trying to make a simpler timer function for my project. More along the lines of what UE3 used to do, and I’m running into a bit of an issue. Where it shows “Manager->SetTimer(…)” in the code below, I get red jagged underlines in VC++ saying that
I’m confused as to why this is occuring? I have the SetTimer function definition I’m attempting to use in FTimerManager commented right above the problem line…
Code:
void MyActor::SetTimer(
float DelayInterval, bool bLooping,
typename FTimerDelegate::TUObjectMethodDelegate<UObject*>::FMethodPtr InTimerMethod
)
{
FTimerManager* Manager = &GetWorldTimerManager();
if (Manager)
{
FTimerHandle MemberTimerHandle = FTimerHandle();
//SetTimer(FTimerHandle& InOutHandle, UserClass* InObj, typename FTimerDelegate::TMethodPtr< UserClass > InTimerMethod, float InRate, bool InbLoop = false, float InFirstDelay = -1.f)
Manager->SetTimer(MemberTimerHandle, this, InTimerMethod, DelayInterval, bLooping, -1.f);
}
}