I am a programmer for a long time and i was following the official programming tutorials.I was writing pickup class and of course it didn’t work.
These are questions that i just want to be sure. Because last time i did without being sure. UE got crashed everytime i opened project.
Q1
Says TSubobjectPtr is deprecated and c++11 smart pointers doesnt works on every platform. And i should use raw pointers.(Not sure if i got right)
If so where should i delete the pointer? I found this BeginDestroy() function. Will it do?
Q2
UFUNCTION(BlueprintNativeEvent)
void OnPickedUp();
// Says i should declare it for future versions here because UHT wont auto generate anymore
virtual void OnPickedUp_Implementation();
Not something i should worry at the moment but should i use another UFUNCTION() macro for that?
Q3
Says i need to use FObjectInitializer. Is usage like this
APickUp::APickUp(const class FObjectInitializer& ObjectInitializer)
:Super(ObjectInitializer)
....
....
I just got confused between the tutorial and the changes that happened.
Thanks in advance.