1
All checks were successful
ci/woodpecker/push/my-first-workflow Pipeline was successful

This commit is contained in:
xinian
2026-02-11 01:05:47 +08:00
committed by cnb
parent 519f2c69a5
commit 1b930b5a19
3 changed files with 30 additions and 40 deletions

View File

@@ -1,20 +1,9 @@
package controller
import (
"blazing/common/socket/errorcode"
"blazing/cool"
"blazing/modules/player/service"
// // CreatePlayer 处理命令: 1001
// func (h Controller) CreatePlayer(data *user.CreatePlayerInboundInfo, c gnet.Conn) (result *user.CreatePlayerOutInfo, err errorcode.ErrorCode) {
// data.Nickname = strings.Trim(data.Nickname, "\x00")
// service.NewUserService(data.Head.UserID).Info.Reg(cool.Filter.Replace(data.Nickname, '*'), data.Color)
"blazing/logic/service/user"
"strings"
"github.com/panjf2000/gnet/v2"
)
// CreatePlayer 处理命令: 1001
func (h Controller) CreatePlayer(data *user.CreatePlayerInboundInfo, c gnet.Conn) (result *user.CreatePlayerOutInfo, err errorcode.ErrorCode) {
data.Nickname = strings.Trim(data.Nickname, "\x00")
service.NewUserService(data.Head.UserID).Info.Reg(cool.Filter.Replace(data.Nickname, '*'), data.Color)
return result, 0
}
// return result, 0
// }