Test baseline

This commit is contained in:
2023-10-10 12:34:21 -04:00
parent 859de1004e
commit 6494e07e9e
+1 -10
View File
@@ -99,22 +99,13 @@ public class Terrain {
// Transform world loc into zone space coordinate system
Vector2f terrainLoc = ZoneManager.worldToZoneSpace(worldLoc, terrainZone);
Vector2f parentLoc = ZoneManager.worldToZoneSpace(worldLoc, parentZone);
// Interpolate height for this position in terrain
float interpolatedChildHeight = terrainZone.terrain.getInterpolatedTerrainHeight(terrainLoc);
interpolatedChildHeight += terrainZone.worldAltitude;
// Interpolate height for this position in parent
float interpolatedParentTerrainHeight = parentZone.terrain.getInterpolatedTerrainHeight(parentLoc);
interpolatedParentTerrainHeight += parentZone.worldAltitude;
// Blend between heights
return interpolatedChildHeight + interpolatedParentTerrainHeight * (1 - terrainZone.terrain.terrainBlend(terrainLoc));
return interpolatedChildHeight;
}
public static float getWorldHeight(Vector3fImmutable worldLoc) {