ADD: added orientation

This commit is contained in:
Henry Winkel
2023-03-18 19:36:53 +01:00
parent 9fe27e254d
commit 324f4adb6a
6 changed files with 31 additions and 14 deletions

View File

@@ -25,7 +25,8 @@ namespace Entities
SimCore::EntityKind EntityKind,
std::uint32_t GroundTruthPort,
std::uint32_t CommandPort,
std::string CommandIPAddress):EntityName_(EnttityName),
std::string CommandIPAddress):
EntityName_(EnttityName),
ownTrack_(OwnType, OwnID, SimCore::TrackKind::GROUND_TRUTH_TRACK),
ParentID_(ParentID),
EntityKind_(EntityKind),
@@ -37,6 +38,12 @@ namespace Entities
}
Entity::~Entity()
{
stop();
}
void Entity::start()
{
@@ -68,21 +75,19 @@ namespace Entities
// }
for (std::vector<std::thread>::iterator it = threads.begin(); it != threads.end();)
{
if (it->joinable())
for (std::vector<std::thread>::iterator it = threads.begin(); it != threads.end();)
{
it->join();
it = threads.erase(it);
if (it->joinable())
{
it->join();
it = threads.erase(it);
}
}
}
LOG_S(ERROR)<< threads.size();
}
void Entity::physicsWorker()