Skip to content

Commit

Permalink
Engine - ECS: removed EntityStore.GetChildNodeByIndex()
Browse files Browse the repository at this point in the history
  • Loading branch information
friflo committed Dec 9, 2023
1 parent a016960 commit b32e341
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Engine/src/ECS/Entity/Store/NodeTree.cs
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,11 @@ internal bool RemoveChild (int parentId, int childId)
return true;
}

/* redundant: Entity.GetChildIndex() provide same feature but cleaner
internal ref readonly EntityNode GetChildNodeByIndex(int parentId, int childIndex) {
var childIds = nodes[parentId].childIds;
return ref nodes[childIds[childIndex]];
}
} */

/* redundant: Entity.ChildEntities[] provide same feature but cleaner
internal Entity GetChildEntityByIndex(int parentId, int childIndex) {
Expand Down

0 comments on commit b32e341

Please sign in to comment.