Add support for allocator type in Dictionary
This commit is contained in:
@@ -868,7 +868,7 @@ public:
|
||||
/// <param name="data">The input data.</param>
|
||||
/// <param name="idsMapping">The serialized objects Ids mapping. Can be used to convert the spawned objects ids and references to them.</param>
|
||||
/// <returns>The output actors.</returns>
|
||||
API_FUNCTION() static Array<Actor*> FromBytes(const Span<byte>& data, const Dictionary<Guid, Guid>& idsMapping);
|
||||
API_FUNCTION() static Array<Actor*> FromBytes(const Span<byte>& data, const Dictionary<Guid, Guid, HeapAllocation>& idsMapping);
|
||||
|
||||
/// <summary>
|
||||
/// Tries the get serialized objects ids from the raw bytes.
|
||||
|
||||
@@ -83,7 +83,7 @@ DECLARE_SCRIPTING_TYPE_NO_SPAWN(PrefabManager);
|
||||
/// <param name="objectsCache">The options output objects cache that can be filled with prefab object id mapping to deserialized object (actor or script).</param>
|
||||
/// <param name="withSynchronization">True if perform prefab changes synchronization for the spawned objects. It will check if need to add new objects due to nested prefab modifications.</param>
|
||||
/// <returns>The created actor (root) or null if failed.</returns>
|
||||
static Actor* SpawnPrefab(Prefab* prefab, Actor* parent, Dictionary<Guid, const void*>* objectsCache, bool withSynchronization = false);
|
||||
static Actor* SpawnPrefab(Prefab* prefab, Actor* parent, Dictionary<Guid, const void*, HeapAllocation>* objectsCache, bool withSynchronization = false);
|
||||
|
||||
#if USE_EDITOR
|
||||
|
||||
@@ -118,7 +118,7 @@ DECLARE_SCRIPTING_TYPE_NO_SPAWN(PrefabManager);
|
||||
/// <summary>
|
||||
/// The prefabs references mapping table. Maps the prefab asset id to the collection of the root actors of the prefab instances.
|
||||
/// </summary>
|
||||
static Dictionary<Guid, Array<Actor*, HeapAllocation>> PrefabsReferences;
|
||||
static Dictionary<Guid, Array<Actor*, HeapAllocation>, HeapAllocation> PrefabsReferences;
|
||||
|
||||
/// <summary>
|
||||
/// Locks PrefabsReferences to be used in a multi threaded environment.
|
||||
|
||||
@@ -39,7 +39,7 @@ public:
|
||||
/// <summary>
|
||||
/// The actors collection lookup type (id -> actor).
|
||||
/// </summary>
|
||||
typedef Dictionary<Guid, Actor*> ActorsLookup;
|
||||
typedef Dictionary<Guid, Actor*, HeapAllocation> ActorsLookup;
|
||||
|
||||
#define DECLARE_SCENE_OBJECT(type) \
|
||||
DECLARE_SCRIPTING_TYPE(type)
|
||||
|
||||
@@ -11,7 +11,7 @@ class SceneObjectsFactory
|
||||
{
|
||||
public:
|
||||
|
||||
typedef Dictionary<Actor*, const rapidjson_flax::Value*> ActorToRemovedObjectsDataLookup;
|
||||
typedef Dictionary<Actor*, const rapidjson_flax::Value*, HeapAllocation> ActorToRemovedObjectsDataLookup;
|
||||
|
||||
public:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user