diff --git a/include/Entities/Entity.hpp b/include/Entities/Entity.hpp index aff3d21..ae6afdd 100644 --- a/include/Entities/Entity.hpp +++ b/include/Entities/Entity.hpp @@ -1,6 +1,6 @@ #pragma once - +#include #include "DirectCommunicationServer.hpp" #include "Entities/Movement.hpp" @@ -81,6 +81,9 @@ namespace Entities { std::shared_ptr OwnShipTrack = nullptr; + std::unique_ptr TrackList_ = nullptr; + + std::string EntityName_; SimCore::Kind::EntityKind EntityKind_; SimCore::Side::EntitySide EntitySide_; diff --git a/libs/KubeControl b/libs/KubeControl index f11742c..f59652a 160000 --- a/libs/KubeControl +++ b/libs/KubeControl @@ -1 +1 @@ -Subproject commit f11742ce64a56307401e2a4110d68103f75703af +Subproject commit f59652ada171d389dff669b1472e89672f59829c diff --git a/libs/SimCore b/libs/SimCore index 630e8c4..d345fd5 160000 --- a/libs/SimCore +++ b/libs/SimCore @@ -1 +1 @@ -Subproject commit 630e8c4d74b95a6dcab834b42d23798535760e40 +Subproject commit d345fd5bc3cd864593da3ef2eac5010047b08c47 diff --git a/src/Entities/Entity.cpp b/src/Entities/Entity.cpp index 238a37f..8c4e7a8 100644 --- a/src/Entities/Entity.cpp +++ b/src/Entities/Entity.cpp @@ -69,6 +69,7 @@ namespace Entities BroadcastServer_ = std::make_shared(GroundTruthAddr, GroundTruthPort); // BroadcastServer_ = std::make_shared("239.0.0.1", 10000); + TrackList_ = std::make_unique(); } @@ -286,7 +287,10 @@ namespace Entities std::unique_ptr control = std::move(SimCore::Control::unpack(whisperMsg)); switch (control->Type) { - case SimCore::IDENTIFY : + case SimCore::IDENTIFY : + { + break; + } case SimCore::START: case SimCore::STOP : case SimCore::SHUT_DOWN : @@ -297,6 +301,18 @@ namespace Entities case SimCore::CREATE_ENTITY: case SimCore::DELETE_ENTITY : case SimCore::GET_CONTROL: + { + break; + } + case SimCore::GET_TRACKLIST: + { + nlohmann::json j; + this->TrackList_->getJsonTRackList(j); + // WHISPER::StringData(this->OwnShipTrack->getIdentifier(),) + this->CommandCommsServer_->sendMessage(j.dump()); + break; + } + break; };