#Flat earthers?

6 messages · Page 1 of 1 (latest)

sly cipher
#

Hi, do you believe the earth is flat?

Looks like the code says "yes"...

Just completed an analysis of OpenFrontIO's map system and found some issues with the cartographic representation. The game treats Earth as a flat 2D grid without accounting for planetary curvature, creating some exploitable gameplay imbalances:

  1. No spherical map projection
    The game uses a simple flat grid without any Earth curvature consideration:
euclideanDist(c1: TileRef, c2: TileRef): number {
  return Math.sqrt(
    Math.pow(this.x(c1) - this.x(c2), 2) + 
    Math.pow(this.y(c1) - this.y(c2), 2)
  );
}```
Exploit: Players controlling "polar" regions (map edges) get disproportionate territory size advantage

2.  Territory cluster detection issues
```// PlayerExecution.ts
private isSurrounded(cluster: Set<TileRef>): boolean {
  // ...
  const enemyBox = calculateBoundingBox(this.mg, enemyTiles);
  const clusterBox = calculateBoundingBox(this.mg, cluster);
  return inscribed(enemyBox, clusterBox);
}

Exploit: "C-shaped" territory arrangements can avoid being detected as surrounded

  1. Non-uniform territorial resources
    (The flat representation makes no adjustment for territory real-world size:)
// DefaultConfig.ts
goldAdditionRate(player: Player): number {
  return Math.sqrt(player.workers() * player.numTilesOwned()) / 200;
}

Exploit: Players controlling "Greenland" get same resources as equal pixel-size territories despite huge real-world size differences
Of course, it's obvious for "advanced" players, but it least to serious imbalance for most novice players, as they'll pick countries they know etc.
Now, I can understand it might be a tactic to get people frustrated, losing, and searching for ways to improve, eventually getting more invovled in the game, yt content etc. but still creates some churn and loose players...

#

For the spherical map projection, we could do sth like a latitude-based distance correction

sth like that (maybe?):

  // Get coordinates
  const x1 = this.x(c1), y1 = this.y(c1);
  const x2 = this.x(c2), y2 = this.y(c2);
  
  // Calculate latitude factors (y=0 is equator, max distortion at y=height/2)
  const latFactor1 = Math.cos(Math.PI * (y1 - this.height_/2) / this.height_);
  const latFactor2 = Math.cos(Math.PI * (y2 - this.height_/2) / this.height_);
  const avgLatFactor = (latFactor1 + latFactor2) / 2;
  
  // Apply correction to x-distance based on latitude
  const adjustedXDist = (x2 - x1) * avgLatFactor;
  
  return Math.sqrt(Math.pow(adjustedXDist, 2) + Math.pow(y2 - y1, 2));
}
#

And for goldAdditionRate to be more accurate, maybe sth like that:

  let weightedTileCount = 0;
  
  // Calculate latitude-weighted territory count
  for (const tile of player.tiles()) {
    // Get y-coordinate (latitude)
    const y = this.mg.y(tile);
    
    // Weight factor: 1.0 at equator (y = height/2), decreasing toward poles
    const latWeightFactor = Math.cos(Math.PI * (y - this.mg.height()/2) / this.mg.height());
    
    // Apply weighting, equator tiles count as 1, polar tiles count as much less
    weightedTileCount += latWeightFactor;
  }
  
  return Math.sqrt(player.workers() * weightedTileCount) / 200;
}```
ruby adder
#

I'm a flat earther that's why

karmic basin
#

Gasp!

sly cipher