Fixed constness of functions in scene graph

This commit is contained in:
Cocoa 2022-09-20 15:35:10 +08:00
parent c0290b7185
commit f4bf895e45
2 changed files with 5 additions and 5 deletions

View File

@ -114,7 +114,7 @@ namespace SHADE
return parent; return parent;
} }
std::vector<SHSceneNode*>& SHSceneNode::GetChildren() noexcept const std::vector<SHSceneNode*>& SHSceneNode::GetChildren() const noexcept
{ {
return children; return children;
} }

View File

@ -49,7 +49,7 @@ namespace SHADE
[[nodiscard]] EntityID GetEntityID () const noexcept; [[nodiscard]] EntityID GetEntityID () const noexcept;
[[nodiscard]] SHSceneNode* GetParent () const noexcept; [[nodiscard]] SHSceneNode* GetParent () const noexcept;
[[nodiscard]] std::vector<SHSceneNode*>& GetChildren () noexcept; [[nodiscard]] const std::vector<SHSceneNode*>& GetChildren () const noexcept;
[[nodiscard]] SHSceneNode* GetChild (EntityID childID) const noexcept; [[nodiscard]] SHSceneNode* GetChild (EntityID childID) const noexcept;