mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
1.18.8 (#784)
## Bug fixes - Default to automatic map mode positioning when mixing manual and automatic (would just break before) - Account for map mode image scale when automatically positioning
This commit is contained in:
commit
a85e966617
@ -45,13 +45,31 @@ namespace NewHorizons.Builder.ShipLog
|
||||
}
|
||||
}
|
||||
|
||||
if (flagAutoPositionUsed)
|
||||
var isBaseSolarSystem = systemName == "SolarSystem";
|
||||
|
||||
// Default to MANUAL in Base Solar System (we can't automatically fix them so it might just break, but AUTO breaks even more!)
|
||||
var useManual = (flagManualPositionUsed && !flagAutoPositionUsed) || (flagAutoPositionUsed && flagManualPositionUsed && isBaseSolarSystem);
|
||||
|
||||
// Default to AUTO in other solar systems (since we can actually fix them)
|
||||
var useAuto = (flagAutoPositionUsed && !flagManualPositionUsed) || (flagAutoPositionUsed && flagManualPositionUsed && !isBaseSolarSystem);
|
||||
|
||||
if (flagAutoPositionUsed && flagManualPositionUsed)
|
||||
{
|
||||
if (useAuto)
|
||||
{
|
||||
NHLogger.LogWarning("Can't mix manual and automatic layout of ship log map mode, defaulting to AUTOMATIC");
|
||||
}
|
||||
else
|
||||
{
|
||||
NHLogger.LogWarning("Can't mix manual and automatic layout of ship log map mode, defaulting to MANUAL");
|
||||
}
|
||||
}
|
||||
|
||||
if (useAuto)
|
||||
{
|
||||
if (flagAutoPositionUsed && flagManualPositionUsed)
|
||||
NHLogger.LogWarning("Can't mix manual and automatic layout of ship log map mode, defaulting to automatic");
|
||||
return ConstructMapModeAuto(bodies, transformParent, greyScaleMaterial, layer);
|
||||
}
|
||||
else if (flagManualPositionUsed)
|
||||
else if (useManual)
|
||||
{
|
||||
return ConstructMapModeManual(bodies, transformParent, greyScaleMaterial, currentNav, layer);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user