MCPcopy Create free account
hub / github.com/Illation/ETEngine / ReparentEntity

Method ReparentEntity

Engine/source/EtFramework/ECS/EcsCommandBuffer.cpp:91–99  ·  view source on GitHub ↗

---------------------------------- EcsCommandBuffer::ReparentEntity

Source from the content-addressed store, hash-verified

89// EcsCommandBuffer::ReparentEntity
90//
91void EcsCommandBuffer::ReparentEntity(T_EntityId const entity, T_EntityId const newParent)
92{
93 ET_ASSERT(std::find_if(m_ReparentEntities.cbegin(), m_ReparentEntities.cend(), [entity](std::pair<T_EntityId, T_EntityId> const& pair)
94 {
95 return (entity == pair.first);
96 }) == m_ReparentEntities.cend(), "Entity was already queued for reparenting!");
97
98 m_ReparentEntities.emplace_back(entity, newParent);
99}
100
101//----------------------------------
102// EcsCommandBuffer::RemoveEntity

Callers 1

MergeMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected