mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-30 20:15:35 +08:00
PBH, minor style adjustments
This commit is contained in:
committed by
Mat Sutcliffe
parent
9aac7576c1
commit
84ae160b14
@@ -55,12 +55,12 @@ namespace BlackCore
|
|||||||
{
|
{
|
||||||
PBH pbhstrct;
|
PBH pbhstrct;
|
||||||
pbhstrct.pitch = qFloor(pitch * pitchMultiplier());
|
pbhstrct.pitch = qFloor(pitch * pitchMultiplier());
|
||||||
pbhstrct.bank = qFloor(bank * bankMultiplier());
|
pbhstrct.bank = qFloor(bank * bankMultiplier());
|
||||||
pbhstrct.hdg = static_cast<unsigned int>(heading * headingMultiplier());
|
pbhstrct.hdg = static_cast<unsigned int>(heading * headingMultiplier());
|
||||||
|
|
||||||
// FSD has inverted pitch and bank angles
|
// FSD has inverted pitch and bank angles
|
||||||
pbhstrct.pitch = ~pbhstrct.pitch;
|
pbhstrct.pitch = ~pbhstrct.pitch;
|
||||||
pbhstrct.bank = ~pbhstrct.bank;
|
pbhstrct.bank = ~pbhstrct.bank;
|
||||||
|
|
||||||
pbhstrct.onground = onGround ? 1 : 0;
|
pbhstrct.onground = onGround ? 1 : 0;
|
||||||
|
|
||||||
@@ -77,10 +77,10 @@ namespace BlackCore
|
|||||||
|
|
||||||
// MSFS has inverted pitch and bank angles
|
// MSFS has inverted pitch and bank angles
|
||||||
iPitch = ~iPitch;
|
iPitch = ~iPitch;
|
||||||
iBank = ~iBank;
|
iBank = ~iBank;
|
||||||
|
|
||||||
pitch = iPitch;
|
pitch = iPitch;
|
||||||
bank = iBank;
|
bank = iBank;
|
||||||
heading = pbhstrct.hdg / headingMultiplier();
|
heading = pbhstrct.hdg / headingMultiplier();
|
||||||
|
|
||||||
onGround = pbhstrct.onground == 1;
|
onGround = pbhstrct.onground == 1;
|
||||||
|
|||||||
Reference in New Issue
Block a user