mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 01:05:34 +08:00
refs #395, changed own aircraft provider to thread safe member functions
(similar to remote aircraft provider)
* removed references
* made own aircraft context thread safe (reg. own aircrat data)
* removed the read only versions of the provider
* adjusted consuming methods
* renamed some functions ("ownAircraft...") to avoid ambiguity (with remote aircraft)
This commit is contained in:
committed by
Mathew Sutcliffe
parent
7200f2e29c
commit
3ecf37dda4
@@ -215,7 +215,7 @@ namespace BlackSimPlugin
|
||||
{
|
||||
if (m_useFsuipc && m_fsuipc)
|
||||
{
|
||||
CSimulatedAircraft fsuipcAircraft(ownAircraft());
|
||||
CSimulatedAircraft fsuipcAircraft(getOwnAircraft());
|
||||
bool ok = m_fsuipc->read(fsuipcAircraft, true, true, true);
|
||||
if (ok)
|
||||
{
|
||||
@@ -244,7 +244,7 @@ namespace BlackSimPlugin
|
||||
{
|
||||
MPPositionVelocity mpPositionVelocity;
|
||||
MultiPlayerPacketParser::readMessage(message, mpPositionVelocity);
|
||||
ownAircraft().setSituation(aircraftSituationfromFS9(mpPositionVelocity));
|
||||
updateOwnSituation(aircraftSituationfromFS9(mpPositionVelocity));
|
||||
break;
|
||||
}
|
||||
case CFs9Sdk::MPCHAT_PACKET_ID_CHAT_TEXT_SEND:
|
||||
@@ -261,7 +261,7 @@ namespace BlackSimPlugin
|
||||
|
||||
void CSimulatorFs9::updateOwnAircraftFromSimulator(const CAircraft &simDataOwnAircraft)
|
||||
{
|
||||
this->providerUpdateCockpit(
|
||||
this->updateCockpit(
|
||||
simDataOwnAircraft.getCom1System(),
|
||||
simDataOwnAircraft.getCom2System(),
|
||||
simDataOwnAircraft.getTransponder(),
|
||||
|
||||
Reference in New Issue
Block a user