21 lines
583 B
Go
21 lines
583 B
Go
|
|
package controller
|
||
|
|
|
||
|
|
import (
|
||
|
|
"blazing/common/data/entity"
|
||
|
|
"blazing/common/socket/errorcode"
|
||
|
|
"blazing/logic/service/maps"
|
||
|
|
)
|
||
|
|
|
||
|
|
func (h *Controller) MapList(data *maps.ListMapPlayerInboundInfo, c *entity.Player) (result *maps.ListMapPlayerOutboundInfo, err errorcode.ErrorCode) { //这个时候player应该是空的
|
||
|
|
|
||
|
|
result = &maps.ListMapPlayerOutboundInfo{}
|
||
|
|
result.Player = make([]maps.OutInfo, 0)
|
||
|
|
result1 := maps.NewOutInfo()
|
||
|
|
|
||
|
|
result1.UserID = c.UserID
|
||
|
|
//result.Pos = model.Pos{X: 500, Y: 400}
|
||
|
|
result1.Nick = c.Nick
|
||
|
|
result.Player = append(result.Player, *result1)
|
||
|
|
return
|
||
|
|
}
|