From 95c56f9a14d5f1df739ee6790ad9b1359e8b49ca Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Wed, 10 Mar 2021 00:09:41 +0000 Subject: Merge nexts into ends --- game/network/link.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'game/network/link.h') diff --git a/game/network/link.h b/game/network/link.h index afb3900..a174275 100644 --- a/game/network/link.h +++ b/game/network/link.h @@ -32,7 +32,14 @@ using LinkCPtr = std::shared_ptr; using LinkWPtr = std::weak_ptr; class Link { public: - using End = std::pair; + using Next = std::pair; + using Nexts = std::vector; + + struct End { + NodePtr node; + float dir; + Nexts nexts {}; + }; Link(End, End, float); virtual ~Link() = default; @@ -43,9 +50,6 @@ public: std::array ends; float length; - using Next = std::pair; - using Nexts = std::vector; - std::array nexts; }; bool operator<(const glm::vec3 & a, const glm::vec3 & b); -- cgit v1.2.3