refactor(logic): 优化地图热度获取逻辑,移除临时变量
This commit is contained in:
@@ -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()),
|
||||
|
||||
Reference in New Issue
Block a user