Fixed #49 being able to parent an entity to itself, which resulted in infinite infinite loops everywhere! D:
This commit is contained in:
@@ -759,7 +759,7 @@ void EditorGUI::entityDelete(EntityWrapper entity)
|
||||
|
||||
void EditorGUI::entityChangeParent(EntityWrapper entity, EntityWrapper parent)
|
||||
{
|
||||
if (entity == parent) {
|
||||
if (entity == parent || parent.IsChildOf(entity)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user