mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 12:05:23 +01:00
Revert "fix error"
This reverts commit 2e07c93fc45c2511084b66ff9ffd810e266ad86d.
This commit is contained in:
parent
2e07c93fc4
commit
be3f77d02b
@ -83,8 +83,8 @@ namespace NewHorizons.Builder.Props
|
||||
bool reasonableHeightConstraints = true;
|
||||
if (!propInfo.preventOverlap && (heightMapTexture != null) && (propInfo.minHeight != null || propInfo.maxHeight != null)) // If caution is relevant
|
||||
{
|
||||
var maxHeight = (propInfo.maxHeight != null ? Math.Min(propInfo.maxHeight.Value, heightMap.maxHeight) : heightMap.maxHeight);
|
||||
var minHeight = (propInfo.minHeight != null ? Math.Max(propInfo.minHeight.Value, heightMap.minHeight) : heightMap.minHeight);
|
||||
var maxHeight = (propInfo.maxHeight != null ? Math.Min(propInfo.maxHeight, heightMap.maxHeight) : heightMap.maxHeight);
|
||||
var minHeight = (propInfo.minHeight != null ? Math.Max(propInfo.minHeight, heightMap.minHeight) : heightMap.minHeight);
|
||||
if ((maxHeight - minHeight) / (heightMap.maxHeight - heightMap.minHeight) < 0.001) // If height roll has less than 0.1% chance of being valid
|
||||
{
|
||||
NHLogger.LogError($"Ignoring minHeight/maxHeight for scatter of [{scatterPrefab.name}] to prevent infinite rerolls from too much constraint on height.");
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user