refactor(logic): 优化地图热度获取逻辑,移除临时变量

This commit is contained in:
1
2025-08-16 03:19:47 +00:00
parent 92c2d95764
commit 7fc445ce61

View File

@@ -14,8 +14,7 @@ func (h Controller) MapHot(data *maphot.InInfo, c *entity.Player) (result *mapho
HotInfos: make([]maphot.MapHotInfo, 0),
}
ttt := space.GetMapHot()
for k, v := range ttt {
for k, v := range space.GetMapHot() {
result.HotInfos = append(result.HotInfos, maphot.MapHotInfo{
MapID: uint32(k),
Count: uint32(space.GetPlanet(uint32(v)).Len()),