From 6aba7c7dd1d6bcc1ddb4a5acb61ec0850c420824 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Sat, 8 Oct 2022 15:51:19 +0100 Subject: Add addStright to Network which looks up StraightLink in the network type --- game/network/network.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'game/network/network.h') diff --git a/game/network/network.h b/game/network/network.h index 44ad095..c0485a9 100644 --- a/game/network/network.h +++ b/game/network/network.h @@ -30,6 +30,8 @@ public: [[nodiscard]] Link::Nexts routeFromTo(const Link::End &, glm::vec3) const; [[nodiscard]] Link::Nexts routeFromTo(const Link::End &, const NodePtr &) const; + virtual LinkPtr addStraight(glm::vec3, glm::vec3) = 0; + protected: static void joinLinks(const LinkPtr & l, const LinkPtr & ol); @@ -60,5 +62,11 @@ public: return l; } + LinkPtr + addStraight(glm::vec3 n1, glm::vec3 n2) override + { + return addLink(n1, n2); + } + void render(const Shader &) const override; }; -- cgit v1.2.3