Hi,
I have been looking all over… is it possible to add something to a dynamic delegate through a function? I don’t want to return the new object to the caller and therefore just want to add to the delegate inside the function call, is this possible?
void ObjectX::Function1()
{
instanceOfY->CreateObject(..., &MyCallBack);
}
void ObjectX::MyCallBack()
{
....
}
void ObjectY::CreateObject(..., some parameter type)
{
newobject = CreateMyObject();
newobject.mydelegate.AddDynamic(...)
}
//What should i do here and what parameter should i accept in the function? I couldn’t find any examples on wiki tutorials on this one. If CreateObject could be a ufunction exposes to objects it would be even better
My delegate type:
DECLARE_DYNAMIC_MULTICAST_DELEGATE(FOnConfirmed);