mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 17:35:34 +08:00
refs #369, changed interpolation to a working (but still too bad performing) version
* using split by callsign everywhere * helper function to insert_front * revised linear interpolator * renamed to remoteAircraft * renamed to container() in providers (gettters are usually copies) Issues why changes did so long: * insert in list is not adding in front, but same as push_back (that was confusing) * naming of values before/after in interpolator was ambigious * QMap keeps values sorted by key, not arbitrarily
This commit is contained in:
@@ -113,7 +113,7 @@ namespace BlackSimPlugin
|
||||
if (m_hashFs9Clients.contains(callsign))
|
||||
{
|
||||
// already exists, remove first
|
||||
this->removeRenderedAircraft(callsign);
|
||||
this->removeRemoteAircraft(callsign);
|
||||
}
|
||||
|
||||
CFs9Client *client = new CFs9Client(m_interpolator, this, callsign.toQString(), CTime(25, CTimeUnit::ms()));
|
||||
@@ -127,7 +127,7 @@ namespace BlackSimPlugin
|
||||
return true;
|
||||
}
|
||||
|
||||
bool CSimulatorFs9::removeRenderedAircraft(const CCallsign &callsign)
|
||||
bool CSimulatorFs9::removeRemoteAircraft(const CCallsign &callsign)
|
||||
{
|
||||
if (!m_hashFs9Clients.contains(callsign)) { return false; }
|
||||
|
||||
@@ -298,7 +298,7 @@ namespace BlackSimPlugin
|
||||
// Stop all FS9 client tasks
|
||||
for (auto fs9Client : m_hashFs9Clients.keys())
|
||||
{
|
||||
removeRenderedAircraft(fs9Client);
|
||||
removeRemoteAircraft(fs9Client);
|
||||
}
|
||||
}
|
||||
} // namespace
|
||||
|
||||
@@ -89,7 +89,7 @@ namespace BlackSimPlugin
|
||||
virtual bool addRemoteAircraft(const BlackMisc::Simulation::CSimulatedAircraft &newRemoteAircraft) override;
|
||||
|
||||
//! \copydoc ISimulator::removeRemoteAircraft()
|
||||
virtual bool removeRenderedAircraft(const BlackMisc::Aviation::CCallsign &callsign) override;
|
||||
virtual bool removeRemoteAircraft(const BlackMisc::Aviation::CCallsign &callsign) override;
|
||||
|
||||
//! \copydoc ISimulator::updateOwnSimulatorCockpit()
|
||||
virtual bool updateOwnSimulatorCockpit(const BlackMisc::Aviation::CAircraft &ownAircraft, const QString &originator) override;
|
||||
|
||||
Reference in New Issue
Block a user