From 869f96816c13a5d9b1e4ba6a93972f18ad744fe1 Mon Sep 17 00:00:00 2001 From: Michele Caini Date: Fri, 30 Aug 2019 14:50:48 +0200 Subject: [PATCH] updated doc --- TODO | 5 +++-- src/entt/entity/registry.hpp | 17 +++++++++++++++++ 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/TODO b/TODO index 14decd9e9..a9d6710df 100644 --- a/TODO +++ b/TODO @@ -18,8 +18,6 @@ * built-in support for dual (or N-) buffering * allow for custom stomp functions * deprecate/replace snapshot -* remove dependency -* remove prototype TODO * custom (decoupled) pools ==> double buffering, shared components, multi-model @@ -27,6 +25,9 @@ TODO - inline variables are fine here, only the head represents a problem - we should always resolve by looking into the list of types when working across boundaries, no direct resolve * nested groups: AB/ABC/ABCD/... (hints: sort, check functions) +* snapshot rework/deprecation + * create(hint: entity) -> force-create + * assign(first, last) * use unordered_map for named pools and context variables: * use direct access (pool-like) also for context variables * improves multi-stomp diff --git a/src/entt/entity/registry.hpp b/src/entt/entity/registry.hpp index d0a6f2566..971aead13 100644 --- a/src/entt/entity/registry.hpp +++ b/src/entt/entity/registry.hpp @@ -615,6 +615,14 @@ public: * * @sa create * + * The components must be copyable for obvious reasons. The source entity + * must be a valid one.
+ * If no components are provided, the registry will try to copy all the + * existing types. The non-copyable ones will be ignored. + * + * @note + * Specifying the list of components is ways faster than an opaque copy. + * * @tparam Component Types of components to copy. * @tparam Exclude Types of components not to be copied. * @param src A valid entity identifier to be copied. @@ -633,6 +641,15 @@ public: * * @sa create * + * The components must be copyable for obvious reasons. The entities must be + * all valid.
+ * If no components are provided, the registry will try to copy all the + * existing types. The non-copyable ones will be ignored. + * + * @note + * Specifying the list of components is ways faster than an opaque copy and + * uses the batch creation under the hood. + * * @tparam Component Types of components to copy. * @tparam Exclude Types of components not to be copied. * @param first An iterator to the first element of the range to generate.