Skip to content

Commit 6c53578

Browse files
committed
Added IsTag() and Detach<First>(Second).
1 parent b2ad195 commit 6c53578

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

Foundation/Public/Aurora.Scene/Component.hpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,12 @@ namespace Scene
8181
return mHandle.has(flecs::Prefab);
8282
}
8383

84+
// -=(Undocumented)=-
85+
Bool IsTag() const
86+
{
87+
return ecs_id_is_tag(mHandle.world(), mHandle.id());
88+
}
89+
8490
// -=(Undocumented)=-
8591
template<typename Type>
8692
Ref<Component> Attach()

Foundation/Public/Aurora.Scene/Entity.hpp

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,12 @@ namespace Scene
9393
return mHandle.has(flecs::Prefab);
9494
}
9595

96+
// -=(Undocumented)=-
97+
Bool IsTag() const
98+
{
99+
return ecs_id_is_tag(mHandle.world(), mHandle.id());
100+
}
101+
96102
// -=(Undocumented)=-
97103
template<typename Type>
98104
void Attach()
@@ -294,6 +300,13 @@ namespace Scene
294300
mHandle.remove<First, Second>();
295301
}
296302

303+
// -=(Undocumented)=-
304+
template<typename First>
305+
void Detach(Entity Second)
306+
{
307+
mHandle.remove<First>(Second.GetID());
308+
}
309+
297310
// -=(Undocumented)=-
298311
void Detach(Entity First, Entity Second)
299312
{

0 commit comments

Comments
 (0)