NewObject or CreateDefaultSubobject
I'd like to know what is the difference between the 2 methods stated in the title.
asked Oct 12 '15 at 08:12 PM in C++ Programming
From what I understand, NewObject creates and instance that is not visible to editor however instance created by CreateDefaultSubobject is visible to editor. For example, if you create instance of camera using CreateDefaultSubobject and attach it to your pawn, then that camera will actually appear as child of pawn in editor. This is also why CreateDefaultSubobject usage is restricted to constructor.
answered Sep 25 '17 at 04:06 AM
if we want create something dynamically or in other word creating in Run-time we are using newobject but createdefaultsubject it is not for creating something dynamically we create it once.
answered Nov 19 '18 at 08:31 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here