MCRO
C++23 utilities for Unreal Engine.
|
Namespaces | |
namespace | Detail |
Data Structures | |
struct | FConstructObjectParameters |
Concepts | |
concept | CUObjectInitializable |
Functions | |
template<CUObject T, typename... Args> | |
T * | NewInit (FConstructObjectParameters &¶ms, Args &&... args) |
template<CFunctorObject Initializer, typename TArg = TFunction_Arg<Initializer, 0>, CUObject T = std::decay_t<TArg>> requires std::is_lvalue_reference_v<TArg> | |
T * | Construct (FConstructObjectParameters &¶ms, Initializer &&init) |
template<CFunctorObject Initializer, typename... Args, typename TArg = TFunction_Arg<Initializer, 0>, CUObject T = std::decay_t<TArg>> requires std::is_lvalue_reference_v<TArg> | |
T * | ConstructInit (FConstructObjectParameters &¶ms, Initializer &&init, Args &&... args) |
T * Mcro::UObjects::Init::Construct | ( | FConstructObjectParameters && | params, |
Initializer && | init ) |
Equivalent to Mcro::Construct::Construct
but for UObjects. Usage:
Notice how the object type is deduced from the argument of the initializer.
Initializer | Initializer function type |
params | Parameters for every new object |
init | A setup function for the newly created UObject |
T * Mcro::UObjects::Init::ConstructInit | ( | FConstructObjectParameters && | params, |
Initializer && | init, | ||
Args &&... | args ) |
Equivalent to Mcro::Construct::Construct
but for UObjects. If the constructed UObject type also has an Initialize
function call that too after the lambda initializer. The args
parameters should match the signature of Initialize
in that case. Usage:
Notice how the object type is deduced from the argument of the initializer.
Initializer | Initializer function type |
Args | Arguments for the Initialize function |
params | Parameters for every new object |
init | A setup function for the newly created UObject |
args | Arguments for the Initialize function |
T * Mcro::UObjects::Init::NewInit | ( | FConstructObjectParameters && | params, |
Args &&... | args ) |
Create a new object which can also be initialized with an Initialize function if it has one. In case it has an Initialize function the args
parameters should match them. This is an equivalent to the template Mcro::SharedObjects::MakeShareableInit
T | Type of initializable UObject |
Args | Arguments for the Initialize function |
params | Parameters for every new object |
args | Arguments for the Initialize function |