Navigation
API > API/Runtime > API/Runtime/MassEntity > API/Runtime/MassEntity/FMassEntityManager
Overloads
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
const FConstSharedStruct & GetOrCreateConstSharedFragment
(
const T& Fragment |
Returns or creates a shared struct associated to a given shared fragment set of values identified internally by a CRC. | MassEntityManager.h | |
const FConstSharedStruct & GetOrCreateConstSharedFragment
(
TArgs&&... InArgs |
Returns or creates a shared struct associated to a given shared fragment set of values identified internally by a CRC. | MassEntityManager.h | |
const FConstSharedStruct & GetOrCreateConstSharedFragment
(
const UScriptStruct& InScriptStruct, |
Returns or creates a shared struct associated to a given shared fragment set of values identified internally by a CRC. | MassEntityManager.h | |
const FConstSharedStruct & GetOrCreateConstSharedFragment
(
const FConstStructView HashingHelperStruct, |
Returns or creates a shared struct associated to a given shared fragment set of values identified internally by a CRC. | MassEntityManager.h |
GetOrCreateConstSharedFragment(const T &)
Description
Returns or creates a shared struct associated to a given shared fragment set of values identified internally by a CRC. Use this overload when an instance of the desired const shared fragment type is available and that can be used directly to compute a CRC (i.e., UE::StructUtils::GetStructInstanceCrc32) e.g., USTRUCT() struct FIntConstSharedFragment : public FMassConstSharedFragment {
int32 Value = 0; };
FIntConstSharedFragment Fragment; Fragment.Value = 123; const FConstSharedStruct SharedStruct = EntityManager.GetOrCreateConstSharedFragment(Fragment);
@params Fragment Instance of the desired fragment type
| Name | GetOrCreateConstSharedFragment |
| Type | function |
| Header File | /Engine/Source/Runtime/MassEntity/Public/MassEntityManager.h |
| Include Path | #include "MassEntityManager.h" |
template<typename T>
const FConstSharedStruct & GetOrCreateConstSharedFragment
(
const T & Fragment
)
FConstSharedStruct to the matching, or newly created shared fragment
GetOrCreateConstSharedFragment(TArgs &&...)
Description
Returns or creates a shared struct associated to a given shared fragment set of values identified internally by a CRC. Use this overload when values can be provided as constructor arguments for the desired const shared fragment type and that can be used directly to compute a CRC (i.e., UE::StructUtils::GetStructInstanceCrc32) e.g., USTRUCT() struct FIntConstSharedFragment : public FMassConstSharedFragment {
FIntConstSharedFragment(const int32 InValue) : Value(InValue) {}
int32 Value = 0; };
const FConstSharedStruct SharedStruct = EntityManager.GetOrCreateConstSharedFragment
@params InArgs List of arguments provided to the constructor of the desired fragment type
| Name | GetOrCreateConstSharedFragment |
| Type | function |
| Header File | /Engine/Source/Runtime/MassEntity/Public/MassEntityManager.h |
| Include Path | #include "MassEntityManager.h" |
template<typename T, typename... TArgs>
const FConstSharedStruct & GetOrCreateConstSharedFragment
(
TArgs &&... InArgs
)
FConstSharedStruct to the matching, or newly created shared fragment
GetOrCreateConstSharedFragment(const UScriptStruct &, const uint8 *)
Description
Returns or creates a shared struct associated to a given shared fragment set of values identified internally by a CRC. Use this overload when the reflection data and the memory of an instance of the desired const shared fragment type is available and that can be used directly to compute a CRC (i.e., UE::StructUtils::GetStructInstanceCrc32) e.g., FSharedStruct SharedStruct = EntityManager.GetOrCreateConstSharedFragment(*StructView.GetScriptStruct(), StructView.GetMemory());
@params InScriptStruct Reflection data structure associated to the desired fragment type @params InStructMemory Actual data of the desired fragment type
| Name | GetOrCreateConstSharedFragment |
| Type | function |
| Header File | /Engine/Source/Runtime/MassEntity/Public/MassEntityManager.h |
| Include Path | #include "MassEntityManager.h" |
const FConstSharedStruct & GetOrCreateConstSharedFragment
(
const UScriptStruct & InScriptStruct,
const uint8 * InStructMemory
)
FConstSharedStruct to the matching, or newly created shared fragment
GetOrCreateConstSharedFragment(const FConstStructView, TArgs &&...)
Description
Returns or creates a shared struct associated to a given shared fragment set of values identified internally by a CRC. Use this overload when a different struct should be used to compute a CRC (i.e., UE::StructUtils::GetStructInstanceCrc32) and values can be provided as constructor arguments for the desired const shared fragment type e.g.,
USTRUCT() struct FIntConstSharedFragmentParams {
FIntConstSharedFragmentParams(const int32 InValue) : Value(InValue) {}
int32 Value = 0; };
USTRUCT() struct FIntConstSharedFragment : public FMassConstSharedFragment {
FIntConstSharedFragment(const FIntConstSharedFragmentParams& InParams) : Value(InParams.Value) {}
int32 Value = 0; };
FIntConstSharedFragmentParams Params(123); const FConstSharedStruct SharedStruct = EntityManager.GetOrCreateConstSharedFragment
@params HashingHelperStruct Struct view passed to UE::StructUtils::GetStructInstanceCrc32 to compute the CRC @params InArgs List of arguments provided to the constructor of the desired fragment type
| Name | GetOrCreateConstSharedFragment |
| Type | function |
| Header File | /Engine/Source/Runtime/MassEntity/Public/MassEntityManager.h |
| Include Path | #include "MassEntityManager.h" |
template<typename T, typename... TArgs>
const FConstSharedStruct & GetOrCreateConstSharedFragment
(
const FConstStructView HashingHelperStruct,
TArgs &&... InArgs
)
FConstSharedStruct to the matching, or newly created shared fragment