任务单 #44037

mapgen: Split map_colatitude() into separate functions

开放日期: 2022-03-06 06:22 最后更新: 2022-03-07 21:07

报告人:
属主:
类型:
状态:
关闭
组件:
里程碑:
优先:
5 - Medium
严重性:
5 - Medium
处理结果:
Fixed
文件:
1

Details

Required for #44036. Split map_colatitude() into

  • an initial function handling tile position and topology, to figure out how far north/south a tile is
  • a second function adding in game settings (alltemperate/singlepole) to compute latitude (signed, for #44035)
  • a final function translating signed latitude into absolute colatitude for the map generator

Splitting the first and second should also enable actual singlepole torus maps with no added effort.

任务单历史 (3/4 Histories)

2022-03-06 06:22 Updated by: alienvalkyrie
  • New Ticket "mapgen: Split map_colatitude() into separate functions" created
2022-03-06 06:50 Updated by: alienvalkyrie
  • 处理结果 Update from to Accepted
评论

Note that this patch does change the resulting colatitude a bit (because floating-point numbers aren't great for this, and because trying to emulate the old behavior would've made for rather ugly code), so old seeds will not result in exactly the same map. More specifically, colatitude will generally be a little bit lower than before. In particular, the colatitude will generally not actually reach MAX_COLATITUDE anymore on maps with even dimensions, since the exact equator ends up between tiles.

2022-03-07 21:07 Updated by: alienvalkyrie
  • 状态 Update from 开启 to 关闭
  • 处理结果 Update from Accepted to Fixed

编辑

Please login to add comment to this ticket » 登录名