Initializing a simple class variable?
Lets say that I have a variable foo which is of the type SomeClass* in my header file and I want to initialize it in the constructor of my source file.
How should I go about doing that?
Would it require using NewObject or ConstructObject?
Would the method be different if SomeClass inherited from UObject or AActor?
asked Dec 30 '14 at 05:39 PM in C++ Programming
yes, it would be different. For UObject, if SomeClass inherits from it, you go;
If its an actor you'd spawn it, and I don't think you could do that in a constructor..
answered Dec 30 '14 at 05:58 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here