feat 包命名规范

This commit is contained in:
2026-02-11 14:49:52 +08:00
parent 146c1734fa
commit 185518257f
8 changed files with 49 additions and 51 deletions

View File

@@ -1,17 +1,15 @@
package npc
import (
"git.hlsq.asia/mmorpg/service-common/proto/rs/grpc_pb"
)
import "git.hlsq.asia/mmorpg/service-common/proto/rs/rspb"
// NPCNode 定义NPC节点
type NPCNode struct {
USN int64 // 用户ID
GatewaySID int64 // 网关服务ID
Position [2]float64 // 二维坐标 [x, y]
MoveCross int8 // 移动十字,1 上 2 下 4 左 8 右
Action []*grpc_pb.ActionReq // 其他操作
Position [2]float64 // 二维坐标 [x, y]
MoveCross int8 // 移动十字,1 上 2 下 4 左 8 右
Action []*rspb.ActionReq // 其他操作
}
func NewNPCNode(gatewaySID int64, usn int64) *NPCNode {
@@ -20,6 +18,6 @@ func NewNPCNode(gatewaySID int64, usn int64) *NPCNode {
GatewaySID: gatewaySID,
Position: [2]float64{0, 0},
MoveCross: 0,
Action: make([]*grpc_pb.ActionReq, 0),
Action: make([]*rspb.ActionReq, 0),
}
}