xy 2 dní pred
rodič
commit
9fcf7f527e

+ 2 - 0
bin/client_msg/common.proto

@@ -1,5 +1,7 @@
 syntax = "proto3";
 
+package common_pack;
+
 option go_package = "./msg";
 
 enum roleType {

+ 23 - 0
bin/client_msg/mail.proto

@@ -0,0 +1,23 @@
+syntax = "proto3";
+
+option go_package = "./msg";
+
+import "common.proto";          // 直接引入
+//请求获取邮箱
+message ReqMail{
+  string userid = 1;
+  int32 mail_type = 2;
+}
+//响应获取邮箱列表
+message ResMail{
+  bool success = 1;
+  common_pack.MsgError err_msg = 2;
+  repeated common_pack.ChatMessage list = 3;
+}
+//操作邮箱
+message OptMail{
+  int32 mail_id =1;
+  int32 check_status = 2;
+  int32 receive_status = 3;
+  bool is_delete = 4;
+}

+ 37 - 10
gen_proto.sh

@@ -1,19 +1,46 @@
 #!/bin/bash
 
-# 添加 GOPATH/bin 到 PATH
+# 添加必要的工具路径
 export PATH=$PATH:/usr/local/bin:$(go env GOPATH)/bin
 
 # 进入 proto 文件目录
-cd bin/client_msg
+cd bin/client_msg || { echo "Error: Failed to enter bin/client_msg"; exit 1; }
 
-# 生成 proto 文件
-protoc --go_out=. common.proto
+# 目标目录(确保存在)
+TARGET_DIR="../../src/server/msg"
+mkdir -p "$TARGET_DIR" || { echo "Error: Failed to create $TARGET_DIR"; exit 1; }
 
-# 创建目标目录(如果不存在)
-mkdir -p ../../src/server/msg
+# 遍历所有 .proto 文件并编译
+for proto_file in *.proto; do
+    if [ -f "$proto_file" ]; then
+        echo "Compiling $proto_file..."
 
-# 移动生成的文件到目标目录
-mv msg/common.pb.go ../../src/server/msg/
-rm -rf msg
+        # 生成 Go 代码(自动处理 go_package 路径)
+        protoc --proto_path=. --go_out=paths=source_relative:. "$proto_file" || {
+            echo "Error: protoc failed for $proto_file"
+            exit 1
+        }
 
-echo "Proto files generated and moved successfully!"
+        # 提取 go_package 名称(从 .proto 文件中解析)
+        go_package=$(grep "^option go_package" "$proto_file" | awk -F'"' '{print $2}')
+        if [ -z "$go_package" ]; then
+            echo "Warning: Missing 'option go_package' in $proto_file, using default"
+            go_package="msg"
+        fi
+
+        # 移动生成的 .pb.go 文件
+        gen_file="${proto_file%.proto}.pb.go"
+        if [ -f "$gen_file" ]; then
+            mv "$gen_file" "$TARGET_DIR/" || {
+                echo "Error: Failed to move $gen_file"
+                exit 1
+            }
+            echo "Moved $gen_file to $TARGET_DIR/"
+        else
+            echo "Error: Generated file $gen_file not found"
+            exit 1
+        fi
+    fi
+done
+
+echo "All proto files compiled and moved successfully!"

+ 145 - 0
src/server/datacenter/mail_db/mail.go

@@ -0,0 +1,145 @@
+package maildb
+
+import (
+	"database/sql"
+	"encoding/json"
+	"errors"
+	"fmt"
+	mysqlmgr "server/db/mysql"
+)
+
+type Mail struct {
+	ID            int             `json:"id"`
+	CreateTime    sql.NullTime    `json:"create_time"`
+	MailType      int             `json:"mail_type"`
+	UserID        sql.NullString  `json:"user_id"`
+	MailInfo      json.RawMessage `json:"mail_info"`
+	CheckStatus   int             `json:"check_status"`
+	ReceiveStatus int             `json:"receive_status"`
+}
+
+// CreateMail 创建新邮件
+// 参数:
+// - mailType: 邮件类型(1=系统,2=个人)
+// - userID: 用户ID(当mailType=2时必须提供)
+// - mailInfo: 邮件内容(JSON格式)
+// 返回:
+// - 新邮件的ID
+// - 错误信息
+func CreateMail(mailType int, userID string, mailInfo json.RawMessage) (int64, error) {
+	// 验证参数
+	if mailType != 1 && mailType != 2 {
+		return 0, errors.New("invalid mail_type, must be 1 or 2")
+	}
+
+	if mailType == 2 && userID == "" {
+		return 0, errors.New("user_id is required when mail_type is 2")
+	}
+
+	// 准备SQL语句
+	query := "INSERT INTO mail (mail_type, user_id, mail_info) VALUES (?, ?, ?)"
+	if mailType == 1 {
+		// 系统邮件不需要user_id
+		result, err := mysqlmgr.Insert(query, mailType, nil, mailInfo)
+		if err != nil {
+			return 0, fmt.Errorf("failed to create system mail: %v", err)
+		}
+		return result, err
+	} else {
+		// 个人邮件需要user_id
+		result, err := mysqlmgr.Insert(query, mailType, userID, mailInfo)
+		if err != nil {
+			return 0, fmt.Errorf("failed to create personal mail: %v", err)
+		}
+		return result, err
+	}
+}
+
+// UpdateCheckStatus 更新邮件查看状态
+// 参数:
+// - mailID: 邮件ID
+// - status: 新的查看状态(0=未查看,1=已查看)
+// 返回:
+// - 更新的行数
+// - 错误信息
+func UpdateCheckStatus(mailID int, status int) (int64, error) {
+	if status != 0 && status != 1 {
+		return 0, errors.New("invalid check_status, must be 0 or 1")
+	}
+
+	query := "UPDATE mail SET check_status = ? WHERE id = ?"
+	result, err := mysqlmgr.Update(query, status, mailID)
+	if err != nil {
+		return 0, fmt.Errorf("failed to update check status: %v", err)
+	}
+	return result, err
+}
+
+// UpdateReceiveStatus 更新邮件领取状态
+// 参数:
+// - mailID: 邮件ID
+// - status: 新的领取状态(0=未领取,1=已领取)
+// 返回:
+// - 更新的行数
+// - 错误信息
+func UpdateReceiveStatus(mailID int, status int) (int64, error) {
+	if status != 0 && status != 1 {
+		return 0, errors.New("invalid receive_status, must be 0 or 1")
+	}
+
+	query := "UPDATE mail SET receive_status = ? WHERE id = ?"
+	result, err := mysqlmgr.Update(query, status, mailID)
+	if err != nil {
+		return 0, fmt.Errorf("failed to update receive status: %v", err)
+	}
+
+	return result, err
+}
+
+func GetMailsByType(mailType int, userID string) ([]Mail, error) {
+	var mails []Mail
+	var rows *sql.Rows
+	var err error
+
+	// 基础查询语句
+	query := "SELECT id, create_time, mail_type, user_id, mail_info, check_status, receive_status FROM mail WHERE mail_type = ?"
+
+	// 根据mail_type决定是否添加user_id条件
+	if mailType == 2 {
+		if userID == "" {
+			return nil, fmt.Errorf("user_id is required when mail_type is 2")
+		}
+		query += " AND user_id = ?"
+		rows, err = mysqlmgr.Query(query, mailType, userID)
+	} else {
+		rows, err = mysqlmgr.Query(query, mailType)
+	}
+
+	if err != nil {
+		return nil, fmt.Errorf("query failed: %v", err)
+	}
+	defer rows.Close()
+
+	for rows.Next() {
+		var mail Mail
+		err := rows.Scan(
+			&mail.ID,
+			&mail.CreateTime,
+			&mail.MailType,
+			&mail.UserID,
+			&mail.MailInfo,
+			&mail.CheckStatus,
+			&mail.ReceiveStatus,
+		)
+		if err != nil {
+			return nil, fmt.Errorf("scan failed: %v", err)
+		}
+		mails = append(mails, mail)
+	}
+
+	if err = rows.Err(); err != nil {
+		return nil, fmt.Errorf("rows error: %v", err)
+	}
+
+	return mails, nil
+}

+ 3 - 0
src/server/gate/router.go

@@ -34,4 +34,7 @@ func init() {
 	msg.Processor.SetRouter(&msg.SendQuitRoom{}, game.ChanRPC)
 	msg.Processor.SetRouter(&msg.MatchLudo{}, game.ChanRPC)
 
+	//邮箱
+	msg.Processor.SetRouter(&msg.ReqMail{}, hall.ChanRPC)
+	msg.Processor.SetRouter(&msg.OptMail{}, hall.ChanRPC)
 }

+ 3 - 0
src/server/hall/internal/handler.go

@@ -5,6 +5,7 @@ import (
 	redismgr "server/db/redis"
 	"server/hall/chat"
 	"server/hall/friends"
+	"server/hall/mail"
 	"server/hall/shop"
 	"server/user"
 
@@ -35,6 +36,8 @@ func init() {
 	HandleMsg(&msg.ReqSendChatMsg{}, chat.SendChatMsg)
 	HandleMsg(&msg.ReqChatHistory{}, chat.GetChatHistory)
 
+	HandleMsg(&msg.ReqMail{}, mail.GetMail)
+	HandleMsg(&msg.OptMail{}, mail.OptMail)
 }
 
 func enterHall(args []interface{}) {

+ 9 - 0
src/server/hall/mail/mail.go

@@ -0,0 +1,9 @@
+package mail
+
+func GetMail(args []interface{}) {
+
+}
+
+func OptMail(args []interface{}) {
+
+}

+ 287 - 293
src/server/msg/common.pb.go

@@ -375,9 +375,9 @@ func (RoomStatus) EnumDescriptor() ([]byte, []int) {
 
 type Round struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	MColor        RoleType               `protobuf:"varint,1,opt,name=m_color,json=mColor,proto3,enum=RoleType" json:"m_color,omitempty"`
+	MColor        RoleType               `protobuf:"varint,1,opt,name=m_color,json=mColor,proto3,enum=common_pack.RoleType" json:"m_color,omitempty"`
 	MRoad         string                 `protobuf:"bytes,2,opt,name=m_road,json=mRoad,proto3" json:"m_road,omitempty"`
-	Opt           OptType                `protobuf:"varint,3,opt,name=opt,proto3,enum=OptType" json:"opt,omitempty"`
+	Opt           OptType                `protobuf:"varint,3,opt,name=opt,proto3,enum=common_pack.OptType" json:"opt,omitempty"`
 	SzNumber      int32                  `protobuf:"varint,4,opt,name=szNumber,proto3" json:"szNumber,omitempty"`
 	unknownFields protoimpl.UnknownFields
 	sizeCache     protoimpl.SizeCache
@@ -445,15 +445,15 @@ type RoomInfo struct {
 	state           protoimpl.MessageState `protogen:"open.v1"`
 	Roles           []*RoleData            `protobuf:"bytes,1,rep,name=roles,proto3" json:"roles,omitempty"`
 	Colors          []*ColorData           `protobuf:"bytes,2,rep,name=colors,proto3" json:"colors,omitempty"`
-	RoomType        RoomType               `protobuf:"varint,3,opt,name=room_type,json=roomType,proto3,enum=RoomType" json:"room_type,omitempty"`
-	RoomMode        RoomMode               `protobuf:"varint,4,opt,name=room_mode,json=roomMode,proto3,enum=RoomMode" json:"room_mode,omitempty"`
-	CurRoundColor   RoleType               `protobuf:"varint,5,opt,name=cur_round_color,json=curRoundColor,proto3,enum=RoleType" json:"cur_round_color,omitempty"` //当前那个阵营的回合
+	RoomType        RoomType               `protobuf:"varint,3,opt,name=room_type,json=roomType,proto3,enum=common_pack.RoomType" json:"room_type,omitempty"`
+	RoomMode        RoomMode               `protobuf:"varint,4,opt,name=room_mode,json=roomMode,proto3,enum=common_pack.RoomMode" json:"room_mode,omitempty"`
+	CurRoundColor   RoleType               `protobuf:"varint,5,opt,name=cur_round_color,json=curRoundColor,proto3,enum=common_pack.RoleType" json:"cur_round_color,omitempty"` //当前那个阵营的回合
 	Rounds          []*Round               `protobuf:"bytes,6,rep,name=rounds,proto3" json:"rounds,omitempty"`
 	FinishColors    []*ColorData           `protobuf:"bytes,7,rep,name=finish_colors,json=finishColors,proto3" json:"finish_colors,omitempty"`
 	KictColors      []*ColorData           `protobuf:"bytes,8,rep,name=kict_colors,json=kictColors,proto3" json:"kict_colors,omitempty"`
 	Id              int32                  `protobuf:"varint,9,opt,name=id,proto3" json:"id,omitempty"`
 	RoomLevel       int32                  `protobuf:"varint,10,opt,name=room_level,json=roomLevel,proto3" json:"room_level,omitempty"` //房间的每个等级都对应着不同的奖励和消耗
-	RoomStatus      RoomStatus             `protobuf:"varint,11,opt,name=room_status,json=roomStatus,proto3,enum=RoomStatus" json:"room_status,omitempty"`
+	RoomStatus      RoomStatus             `protobuf:"varint,11,opt,name=room_status,json=roomStatus,proto3,enum=common_pack.RoomStatus" json:"room_status,omitempty"`
 	CurColorOptData *NotifyPlayerOpt       `protobuf:"bytes,12,opt,name=cur_color_opt_data,json=curColorOptData,proto3" json:"cur_color_opt_data,omitempty"` //当前阵营操作的类型
 	OptTime         int32                  `protobuf:"varint,13,opt,name=opt_time,json=optTime,proto3" json:"opt_time,omitempty"`                            //玩家当前剩余操作时间
 	unknownFields   protoimpl.UnknownFields
@@ -583,10 +583,10 @@ func (x *RoomInfo) GetOptTime() int32 {
 
 type RoleData struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	MColor        RoleType               `protobuf:"varint,1,opt,name=m_color,json=mColor,proto3,enum=RoleType" json:"m_color,omitempty"`
+	MColor        RoleType               `protobuf:"varint,1,opt,name=m_color,json=mColor,proto3,enum=common_pack.RoleType" json:"m_color,omitempty"`
 	MSeat         int32                  `protobuf:"varint,2,opt,name=m_seat,json=mSeat,proto3" json:"m_seat,omitempty"`
 	MId           string                 `protobuf:"bytes,3,opt,name=m_id,json=mId,proto3" json:"m_id,omitempty"`
-	MCurRoad      RoadType               `protobuf:"varint,4,opt,name=m_cur_road,json=mCurRoad,proto3,enum=RoadType" json:"m_cur_road,omitempty"`
+	MCurRoad      RoadType               `protobuf:"varint,4,opt,name=m_cur_road,json=mCurRoad,proto3,enum=common_pack.RoadType" json:"m_cur_road,omitempty"`
 	Step          int32                  `protobuf:"varint,5,opt,name=step,proto3" json:"step,omitempty"`
 	OldSetp       int32                  `protobuf:"varint,6,opt,name=old_setp,json=oldSetp,proto3" json:"old_setp,omitempty"`
 	unknownFields protoimpl.UnknownFields
@@ -668,7 +668,7 @@ func (x *RoleData) GetOldSetp() int32 {
 type ColorData struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
 	MId           string                 `protobuf:"bytes,1,opt,name=m_id,json=mId,proto3" json:"m_id,omitempty"`
-	MColor        RoleType               `protobuf:"varint,2,opt,name=m_color,json=mColor,proto3,enum=RoleType" json:"m_color,omitempty"`
+	MColor        RoleType               `protobuf:"varint,2,opt,name=m_color,json=mColor,proto3,enum=common_pack.RoleType" json:"m_color,omitempty"`
 	IsKick        bool                   `protobuf:"varint,3,opt,name=is_kick,json=isKick,proto3" json:"is_kick,omitempty"`
 	IsFinish      bool                   `protobuf:"varint,4,opt,name=is_finish,json=isFinish,proto3" json:"is_finish,omitempty"`
 	TimeOutNum    int32                  `protobuf:"varint,5,opt,name=time_out_num,json=timeOutNum,proto3" json:"time_out_num,omitempty"`
@@ -843,7 +843,7 @@ func (x *MoveStepData) GetOldSetp() int32 {
 
 type SendColorSz struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=RoleType" json:"color,omitempty"` //
+	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=common_pack.RoleType" json:"color,omitempty"` //
 	unknownFields protoimpl.UnknownFields
 	sizeCache     protoimpl.SizeCache
 }
@@ -887,7 +887,7 @@ func (x *SendColorSz) GetColor() RoleType {
 
 type SendRoleMove struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=RoleType" json:"color,omitempty"` //
+	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=common_pack.RoleType" json:"color,omitempty"` //
 	RoleId        string                 `protobuf:"bytes,2,opt,name=roleId,proto3" json:"roleId,omitempty"`
 	unknownFields protoimpl.UnknownFields
 	sizeCache     protoimpl.SizeCache
@@ -939,7 +939,7 @@ func (x *SendRoleMove) GetRoleId() string {
 
 type SendQuitRoom struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=RoleType" json:"color,omitempty"` //
+	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=common_pack.RoleType" json:"color,omitempty"` //
 	unknownFields protoimpl.UnknownFields
 	sizeCache     protoimpl.SizeCache
 }
@@ -983,8 +983,8 @@ func (x *SendQuitRoom) GetColor() RoleType {
 
 type NotifyPlayerSzNumber struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=RoleType" json:"color,omitempty"` //
-	SzNumber      int32                  `protobuf:"varint,2,opt,name=szNumber,proto3" json:"szNumber,omitempty"`         //
+	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=common_pack.RoleType" json:"color,omitempty"` //
+	SzNumber      int32                  `protobuf:"varint,2,opt,name=szNumber,proto3" json:"szNumber,omitempty"`                     //
 	ErrMsg        *MsgError              `protobuf:"bytes,3,opt,name=err_msg,json=errMsg,proto3" json:"err_msg,omitempty"`
 	unknownFields protoimpl.UnknownFields
 	sizeCache     protoimpl.SizeCache
@@ -1043,8 +1043,8 @@ func (x *NotifyPlayerSzNumber) GetErrMsg() *MsgError {
 
 type NotifyPlayerMove struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=RoleType" json:"color,omitempty"` //
-	Step          *MoveStepData          `protobuf:"bytes,2,opt,name=step,proto3" json:"step,omitempty"`                  //
+	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=common_pack.RoleType" json:"color,omitempty"` //
+	Step          *MoveStepData          `protobuf:"bytes,2,opt,name=step,proto3" json:"step,omitempty"`                              //
 	Kick          []*RoleData            `protobuf:"bytes,3,rep,name=kick,proto3" json:"kick,omitempty"`
 	unknownFields protoimpl.UnknownFields
 	sizeCache     protoimpl.SizeCache
@@ -1103,8 +1103,8 @@ func (x *NotifyPlayerMove) GetKick() []*RoleData {
 
 type NotifyPlayerOpt struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=RoleType" json:"color,omitempty"` //
-	Opt           OptType                `protobuf:"varint,2,opt,name=opt,proto3,enum=OptType" json:"opt,omitempty"`      //
+	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=common_pack.RoleType" json:"color,omitempty"` //
+	Opt           OptType                `protobuf:"varint,2,opt,name=opt,proto3,enum=common_pack.OptType" json:"opt,omitempty"`      //
 	CanMoveRoles  []*RoleData            `protobuf:"bytes,3,rep,name=canMoveRoles,proto3" json:"canMoveRoles,omitempty"`
 	OptTime       int32                  `protobuf:"varint,4,opt,name=opt_time,json=optTime,proto3" json:"opt_time,omitempty"`
 	unknownFields protoimpl.UnknownFields
@@ -1171,8 +1171,8 @@ func (x *NotifyPlayerOpt) GetOptTime() int32 {
 
 type NotifyPlayerStatus struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=RoleType" json:"color,omitempty"` //
-	Status        PlayerStatus           `protobuf:"varint,2,opt,name=status,proto3,enum=PlayerStatus" json:"status,omitempty"`
+	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=common_pack.RoleType" json:"color,omitempty"` //
+	Status        PlayerStatus           `protobuf:"varint,2,opt,name=status,proto3,enum=common_pack.PlayerStatus" json:"status,omitempty"`
 	Colors        []*ColorData           `protobuf:"bytes,3,rep,name=colors,proto3" json:"colors,omitempty"`
 	TimeOutColor  *ColorData             `protobuf:"bytes,4,opt,name=time_out_color,json=timeOutColor,proto3" json:"time_out_color,omitempty"`
 	unknownFields protoimpl.UnknownFields
@@ -1239,7 +1239,7 @@ func (x *NotifyPlayerStatus) GetTimeOutColor() *ColorData {
 
 type NotifySettlement struct {
 	state         protoimpl.MessageState `protogen:"open.v1"`
-	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=RoleType" json:"color,omitempty"` //
+	Color         RoleType               `protobuf:"varint,1,opt,name=color,proto3,enum=common_pack.RoleType" json:"color,omitempty"` //
 	FinishColors  []*ColorData           `protobuf:"bytes,2,rep,name=finish_colors,json=finishColors,proto3" json:"finish_colors,omitempty"`
 	unknownFields protoimpl.UnknownFields
 	sizeCache     protoimpl.SizeCache
@@ -1816,9 +1816,9 @@ func (x *LeaveHall) GetUserId() string {
 // 匹配ludo
 type MatchLudo struct {
 	state          protoimpl.MessageState `protogen:"open.v1"`
-	SelectRoomType RoomType               `protobuf:"varint,1,opt,name=select_room_type,json=selectRoomType,proto3,enum=RoomType" json:"select_room_type,omitempty"`
+	SelectRoomType RoomType               `protobuf:"varint,1,opt,name=select_room_type,json=selectRoomType,proto3,enum=common_pack.RoomType" json:"select_room_type,omitempty"`
 	RoomLevel      int32                  `protobuf:"varint,2,opt,name=room_level,json=roomLevel,proto3" json:"room_level,omitempty"`
-	SelectColor    RoleType               `protobuf:"varint,3,opt,name=select_color,json=selectColor,proto3,enum=RoleType" json:"select_color,omitempty"`
+	SelectColor    RoleType               `protobuf:"varint,3,opt,name=select_color,json=selectColor,proto3,enum=common_pack.RoleType" json:"select_color,omitempty"`
 	unknownFields  protoimpl.UnknownFields
 	sizeCache      protoimpl.SizeCache
 }
@@ -3840,44 +3840,41 @@ var File_common_proto protoreflect.FileDescriptor
 
 const file_common_proto_rawDesc = "" +
 	"\n" +
-	"\fcommon.proto\"z\n" +
-	"\x05round\x12\"\n" +
-	"\am_color\x18\x01 \x01(\x0e2\t.roleTypeR\x06mColor\x12\x15\n" +
-	"\x06m_road\x18\x02 \x01(\tR\x05mRoad\x12\x1a\n" +
-	"\x03opt\x18\x03 \x01(\x0e2\b.OptTypeR\x03opt\x12\x1a\n" +
-	"\bszNumber\x18\x04 \x01(\x05R\bszNumber\"\x87\x04\n" +
-	"\bRoomInfo\x12\x1f\n" +
-	"\x05roles\x18\x01 \x03(\v2\t.RoleDataR\x05roles\x12\"\n" +
-	"\x06colors\x18\x02 \x03(\v2\n" +
-	".ColorDataR\x06colors\x12&\n" +
-	"\troom_type\x18\x03 \x01(\x0e2\t.roomTypeR\broomType\x12&\n" +
-	"\troom_mode\x18\x04 \x01(\x0e2\t.roomModeR\broomMode\x121\n" +
-	"\x0fcur_round_color\x18\x05 \x01(\x0e2\t.roleTypeR\rcurRoundColor\x12\x1e\n" +
-	"\x06rounds\x18\x06 \x03(\v2\x06.roundR\x06rounds\x12/\n" +
-	"\rfinish_colors\x18\a \x03(\v2\n" +
-	".ColorDataR\ffinishColors\x12+\n" +
-	"\vkict_colors\x18\b \x03(\v2\n" +
-	".ColorDataR\n" +
+	"\fcommon.proto\x12\vcommon_pack\"\x92\x01\n" +
+	"\x05round\x12.\n" +
+	"\am_color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x06mColor\x12\x15\n" +
+	"\x06m_road\x18\x02 \x01(\tR\x05mRoad\x12&\n" +
+	"\x03opt\x18\x03 \x01(\x0e2\x14.common_pack.OptTypeR\x03opt\x12\x1a\n" +
+	"\bszNumber\x18\x04 \x01(\x05R\bszNumber\"\xff\x04\n" +
+	"\bRoomInfo\x12+\n" +
+	"\x05roles\x18\x01 \x03(\v2\x15.common_pack.RoleDataR\x05roles\x12.\n" +
+	"\x06colors\x18\x02 \x03(\v2\x16.common_pack.ColorDataR\x06colors\x122\n" +
+	"\troom_type\x18\x03 \x01(\x0e2\x15.common_pack.roomTypeR\broomType\x122\n" +
+	"\troom_mode\x18\x04 \x01(\x0e2\x15.common_pack.roomModeR\broomMode\x12=\n" +
+	"\x0fcur_round_color\x18\x05 \x01(\x0e2\x15.common_pack.roleTypeR\rcurRoundColor\x12*\n" +
+	"\x06rounds\x18\x06 \x03(\v2\x12.common_pack.roundR\x06rounds\x12;\n" +
+	"\rfinish_colors\x18\a \x03(\v2\x16.common_pack.ColorDataR\ffinishColors\x127\n" +
+	"\vkict_colors\x18\b \x03(\v2\x16.common_pack.ColorDataR\n" +
 	"kictColors\x12\x0e\n" +
 	"\x02id\x18\t \x01(\x05R\x02id\x12\x1d\n" +
 	"\n" +
 	"room_level\x18\n" +
-	" \x01(\x05R\troomLevel\x12,\n" +
-	"\vroom_status\x18\v \x01(\x0e2\v.roomStatusR\n" +
-	"roomStatus\x12=\n" +
-	"\x12cur_color_opt_data\x18\f \x01(\v2\x10.NotifyPlayerOptR\x0fcurColorOptData\x12\x19\n" +
-	"\bopt_time\x18\r \x01(\x05R\aoptTime\"\xb0\x01\n" +
-	"\bRoleData\x12\"\n" +
-	"\am_color\x18\x01 \x01(\x0e2\t.roleTypeR\x06mColor\x12\x15\n" +
+	" \x01(\x05R\troomLevel\x128\n" +
+	"\vroom_status\x18\v \x01(\x0e2\x17.common_pack.roomStatusR\n" +
+	"roomStatus\x12I\n" +
+	"\x12cur_color_opt_data\x18\f \x01(\v2\x1c.common_pack.NotifyPlayerOptR\x0fcurColorOptData\x12\x19\n" +
+	"\bopt_time\x18\r \x01(\x05R\aoptTime\"\xc8\x01\n" +
+	"\bRoleData\x12.\n" +
+	"\am_color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x06mColor\x12\x15\n" +
 	"\x06m_seat\x18\x02 \x01(\x05R\x05mSeat\x12\x11\n" +
-	"\x04m_id\x18\x03 \x01(\tR\x03mId\x12'\n" +
+	"\x04m_id\x18\x03 \x01(\tR\x03mId\x123\n" +
 	"\n" +
-	"m_cur_road\x18\x04 \x01(\x0e2\t.roadTypeR\bmCurRoad\x12\x12\n" +
+	"m_cur_road\x18\x04 \x01(\x0e2\x15.common_pack.roadTypeR\bmCurRoad\x12\x12\n" +
 	"\x04step\x18\x05 \x01(\x05R\x04step\x12\x19\n" +
-	"\bold_setp\x18\x06 \x01(\x05R\aoldSetp\"\x9e\x02\n" +
+	"\bold_setp\x18\x06 \x01(\x05R\aoldSetp\"\xaa\x02\n" +
 	"\tColorData\x12\x11\n" +
-	"\x04m_id\x18\x01 \x01(\tR\x03mId\x12\"\n" +
-	"\am_color\x18\x02 \x01(\x0e2\t.roleTypeR\x06mColor\x12\x17\n" +
+	"\x04m_id\x18\x01 \x01(\tR\x03mId\x12.\n" +
+	"\am_color\x18\x02 \x01(\x0e2\x15.common_pack.roleTypeR\x06mColor\x12\x17\n" +
 	"\ais_kick\x18\x03 \x01(\bR\x06isKick\x12\x1b\n" +
 	"\tis_finish\x18\x04 \x01(\bR\bisFinish\x12 \n" +
 	"\ftime_out_num\x18\x05 \x01(\x05R\n" +
@@ -3891,40 +3888,37 @@ const file_common_proto_rawDesc = "" +
 	"\fMoveStepData\x12\x11\n" +
 	"\x04m_id\x18\x01 \x01(\tR\x03mId\x12\x12\n" +
 	"\x04step\x18\x02 \x01(\x05R\x04step\x12\x19\n" +
-	"\bold_setp\x18\x03 \x01(\x05R\aoldSetp\".\n" +
-	"\vSendColorSz\x12\x1f\n" +
-	"\x05color\x18\x01 \x01(\x0e2\t.roleTypeR\x05color\"G\n" +
-	"\fSendRoleMove\x12\x1f\n" +
-	"\x05color\x18\x01 \x01(\x0e2\t.roleTypeR\x05color\x12\x16\n" +
-	"\x06roleId\x18\x02 \x01(\tR\x06roleId\"/\n" +
-	"\fSendQuitRoom\x12\x1f\n" +
-	"\x05color\x18\x01 \x01(\x0e2\t.roleTypeR\x05color\"w\n" +
-	"\x14NotifyPlayerSzNumber\x12\x1f\n" +
-	"\x05color\x18\x01 \x01(\x0e2\t.roleTypeR\x05color\x12\x1a\n" +
-	"\bszNumber\x18\x02 \x01(\x05R\bszNumber\x12\"\n" +
-	"\aerr_msg\x18\x03 \x01(\v2\t.MsgErrorR\x06errMsg\"u\n" +
-	"\x10NotifyPlayerMove\x12\x1f\n" +
-	"\x05color\x18\x01 \x01(\x0e2\t.roleTypeR\x05color\x12!\n" +
-	"\x04step\x18\x02 \x01(\v2\r.MoveStepDataR\x04step\x12\x1d\n" +
-	"\x04kick\x18\x03 \x03(\v2\t.RoleDataR\x04kick\"\x98\x01\n" +
-	"\x0fNotifyPlayerOpt\x12\x1f\n" +
-	"\x05color\x18\x01 \x01(\x0e2\t.roleTypeR\x05color\x12\x1a\n" +
-	"\x03opt\x18\x02 \x01(\x0e2\b.OptTypeR\x03opt\x12-\n" +
-	"\fcanMoveRoles\x18\x03 \x03(\v2\t.RoleDataR\fcanMoveRoles\x12\x19\n" +
-	"\bopt_time\x18\x04 \x01(\x05R\aoptTime\"\xb2\x01\n" +
-	"\x12NotifyPlayerStatus\x12\x1f\n" +
-	"\x05color\x18\x01 \x01(\x0e2\t.roleTypeR\x05color\x12%\n" +
-	"\x06status\x18\x02 \x01(\x0e2\r.playerStatusR\x06status\x12\"\n" +
-	"\x06colors\x18\x03 \x03(\v2\n" +
-	".ColorDataR\x06colors\x120\n" +
-	"\x0etime_out_color\x18\x04 \x01(\v2\n" +
-	".ColorDataR\ftimeOutColor\"d\n" +
-	"\x10NotifySettlement\x12\x1f\n" +
-	"\x05color\x18\x01 \x01(\x0e2\t.roleTypeR\x05color\x12/\n" +
-	"\rfinish_colors\x18\x02 \x03(\v2\n" +
-	".ColorDataR\ffinishColors\">\n" +
-	"\x14NotifyUpdateRoomInfo\x12&\n" +
-	"\troom_info\x18\x01 \x01(\v2\t.RoomInfoR\broomInfo\"\xa2\x01\n" +
+	"\bold_setp\x18\x03 \x01(\x05R\aoldSetp\":\n" +
+	"\vSendColorSz\x12+\n" +
+	"\x05color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x05color\"S\n" +
+	"\fSendRoleMove\x12+\n" +
+	"\x05color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x05color\x12\x16\n" +
+	"\x06roleId\x18\x02 \x01(\tR\x06roleId\";\n" +
+	"\fSendQuitRoom\x12+\n" +
+	"\x05color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x05color\"\x8f\x01\n" +
+	"\x14NotifyPlayerSzNumber\x12+\n" +
+	"\x05color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x05color\x12\x1a\n" +
+	"\bszNumber\x18\x02 \x01(\x05R\bszNumber\x12.\n" +
+	"\aerr_msg\x18\x03 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\"\x99\x01\n" +
+	"\x10NotifyPlayerMove\x12+\n" +
+	"\x05color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x05color\x12-\n" +
+	"\x04step\x18\x02 \x01(\v2\x19.common_pack.MoveStepDataR\x04step\x12)\n" +
+	"\x04kick\x18\x03 \x03(\v2\x15.common_pack.RoleDataR\x04kick\"\xbc\x01\n" +
+	"\x0fNotifyPlayerOpt\x12+\n" +
+	"\x05color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x05color\x12&\n" +
+	"\x03opt\x18\x02 \x01(\x0e2\x14.common_pack.OptTypeR\x03opt\x129\n" +
+	"\fcanMoveRoles\x18\x03 \x03(\v2\x15.common_pack.RoleDataR\fcanMoveRoles\x12\x19\n" +
+	"\bopt_time\x18\x04 \x01(\x05R\aoptTime\"\xe2\x01\n" +
+	"\x12NotifyPlayerStatus\x12+\n" +
+	"\x05color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x05color\x121\n" +
+	"\x06status\x18\x02 \x01(\x0e2\x19.common_pack.playerStatusR\x06status\x12.\n" +
+	"\x06colors\x18\x03 \x03(\v2\x16.common_pack.ColorDataR\x06colors\x12<\n" +
+	"\x0etime_out_color\x18\x04 \x01(\v2\x16.common_pack.ColorDataR\ftimeOutColor\"|\n" +
+	"\x10NotifySettlement\x12+\n" +
+	"\x05color\x18\x01 \x01(\x0e2\x15.common_pack.roleTypeR\x05color\x12;\n" +
+	"\rfinish_colors\x18\x02 \x03(\v2\x16.common_pack.ColorDataR\ffinishColors\"J\n" +
+	"\x14NotifyUpdateRoomInfo\x122\n" +
+	"\troom_info\x18\x01 \x01(\v2\x15.common_pack.RoomInfoR\broomInfo\"\xa2\x01\n" +
 	"\bUserInfo\x12\x16\n" +
 	"\x06UserId\x18\x01 \x01(\tR\x06UserId\x12\x15\n" +
 	"\x06m_head\x18\x02 \x01(\tR\x05mHead\x12\x15\n" +
@@ -3934,43 +3928,43 @@ const file_common_proto_rawDesc = "" +
 	"\ronline_status\x18\x06 \x01(\x05R\fonlineStatus\"@\n" +
 	"\bReqLogin\x12\x18\n" +
 	"\aaccount\x18\x01 \x01(\tR\aaccount\x12\x1a\n" +
-	"\bpassword\x18\x02 \x01(\tR\bpassword\"\x89\x01\n" +
+	"\bpassword\x18\x02 \x01(\tR\bpassword\"\xa1\x01\n" +
 	"\bResLogin\x12\x16\n" +
 	"\x06userId\x18\x01 \x01(\tR\x06userId\x12\x1a\n" +
-	"\bnikeName\x18\x02 \x01(\tR\bnikeName\x12%\n" +
-	"\buserInfo\x18\x03 \x01(\v2\t.UserInfoR\buserInfo\x12\"\n" +
-	"\aerr_msg\x18\x04 \x01(\v2\t.MsgErrorR\x06errMsg\"v\n" +
+	"\bnikeName\x18\x02 \x01(\tR\bnikeName\x121\n" +
+	"\buserInfo\x18\x03 \x01(\v2\x15.common_pack.UserInfoR\buserInfo\x12.\n" +
+	"\aerr_msg\x18\x04 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\"v\n" +
 	"\vReqRegister\x12\x1a\n" +
 	"\bnikeName\x18\x01 \x01(\tR\bnikeName\x12\x18\n" +
 	"\aaccount\x18\x02 \x01(\tR\aaccount\x12\x1a\n" +
 	"\bpassword\x18\x03 \x01(\tR\bpassword\x12\x15\n" +
-	"\x06m_head\x18\x04 \x01(\tR\x05mHead\"K\n" +
+	"\x06m_head\x18\x04 \x01(\tR\x05mHead\"W\n" +
 	"\vResRegister\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\"#\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\"#\n" +
 	"\tEnterHall\x12\x16\n" +
-	"\x06userId\x18\x01 \x01(\tR\x06userId\"\x87\x01\n" +
+	"\x06userId\x18\x01 \x01(\tR\x06userId\"\x9f\x01\n" +
 	"\fResEnterHall\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x129\n" +
-	"\x13reconnect_room_info\x18\x03 \x01(\v2\t.RoomInfoR\x11reconnectRoomInfo\"#\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12E\n" +
+	"\x13reconnect_room_info\x18\x03 \x01(\v2\x15.common_pack.RoomInfoR\x11reconnectRoomInfo\"#\n" +
 	"\tLeaveHall\x12\x16\n" +
-	"\x06userId\x18\x01 \x01(\tR\x06userId\"\x8d\x01\n" +
-	"\tMatchLudo\x123\n" +
-	"\x10select_room_type\x18\x01 \x01(\x0e2\t.roomTypeR\x0eselectRoomType\x12\x1d\n" +
+	"\x06userId\x18\x01 \x01(\tR\x06userId\"\xa5\x01\n" +
+	"\tMatchLudo\x12?\n" +
+	"\x10select_room_type\x18\x01 \x01(\x0e2\x15.common_pack.roomTypeR\x0eselectRoomType\x12\x1d\n" +
 	"\n" +
-	"room_level\x18\x02 \x01(\x05R\troomLevel\x12,\n" +
-	"\fselect_color\x18\x03 \x01(\x0e2\t.roleTypeR\vselectColor\"k\n" +
+	"room_level\x18\x02 \x01(\x05R\troomLevel\x128\n" +
+	"\fselect_color\x18\x03 \x01(\x0e2\x15.common_pack.roleTypeR\vselectColor\"\x83\x01\n" +
 	"\fResMatchLudo\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12\x1d\n" +
-	"\x04room\x18\x03 \x01(\v2\t.RoomInfoR\x04room\"F\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12)\n" +
+	"\x04room\x18\x03 \x01(\v2\x15.common_pack.RoomInfoR\x04room\"F\n" +
 	"\bMsgError\x12\x1d\n" +
 	"\n" +
 	"error_code\x18\x01 \x01(\x05R\terrorCode\x12\x1b\n" +
-	"\terror_msg\x18\x02 \x01(\tR\berrorMsg\"/\n" +
-	"\x0eUpdateUserInfo\x12\x1d\n" +
-	"\x04info\x18\x01 \x01(\v2\t.UserInfoR\x04info\" \n" +
+	"\terror_msg\x18\x02 \x01(\tR\berrorMsg\";\n" +
+	"\x0eUpdateUserInfo\x12)\n" +
+	"\x04info\x18\x01 \x01(\v2\x15.common_pack.UserInfoR\x04info\" \n" +
 	"\fResHeartBeat\x12\x10\n" +
 	"\x03msg\x18\x01 \x01(\tR\x03msg\" \n" +
 	"\fReqHeartBeat\x12\x10\n" +
@@ -3979,32 +3973,32 @@ const file_common_proto_rawDesc = "" +
 	"\x04name\x18\x01 \x01(\tR\x04name\x12\x0e\n" +
 	"\x02id\x18\x02 \x01(\tR\x02id\x12\x14\n" +
 	"\x05price\x18\x03 \x01(\x05R\x05price\x12\x10\n" +
-	"\x03num\x18\x04 \x01(\x05R\x03num\"1\n" +
-	"\vBeKickLogin\x12\"\n" +
-	"\aerr_msg\x18\x01 \x01(\v2\t.MsgErrorR\x06errMsg\"%\n" +
+	"\x03num\x18\x04 \x01(\x05R\x03num\"=\n" +
+	"\vBeKickLogin\x12.\n" +
+	"\aerr_msg\x18\x01 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\"%\n" +
 	"\aReqShop\x12\x1a\n" +
-	"\bshopType\x18\x01 \x01(\x05R\bshopType\"f\n" +
+	"\bshopType\x18\x01 \x01(\x05R\bshopType\"~\n" +
 	"\aResShop\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12\x1d\n" +
-	"\x04list\x18\x03 \x03(\v2\t.ShopItemR\x04list\"e\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12)\n" +
+	"\x04list\x18\x03 \x03(\v2\x15.common_pack.ShopItemR\x04list\"e\n" +
 	"\rHistoryRecord\x12\x0e\n" +
 	"\x02id\x18\x01 \x01(\x05R\x02id\x12\x17\n" +
 	"\aroom_id\x18\x02 \x01(\x05R\x06roomId\x12\x17\n" +
 	"\auser_id\x18\x03 \x01(\tR\x06userId\x12\x12\n" +
 	"\x04time\x18\x04 \x01(\tR\x04time\")\n" +
 	"\x0eReqLudoHistory\x12\x17\n" +
-	"\auser_id\x18\x01 \x01(\tR\x06userId\"r\n" +
+	"\auser_id\x18\x01 \x01(\tR\x06userId\"\x8a\x01\n" +
 	"\x0eResLudoHistory\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12\"\n" +
-	"\x04list\x18\x03 \x03(\v2\x0e.HistoryRecordR\x04list\"*\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12.\n" +
+	"\x04list\x18\x03 \x03(\v2\x1a.common_pack.HistoryRecordR\x04list\"*\n" +
 	"\x0fReqLudoRoomInfo\x12\x17\n" +
-	"\aroom_id\x18\x01 \x01(\x03R\x06roomId\"n\n" +
+	"\aroom_id\x18\x01 \x01(\x03R\x06roomId\"\x86\x01\n" +
 	"\x0fResLudoRoomInfo\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12\x1d\n" +
-	"\x04info\x18\x03 \x01(\v2\t.RoomInfoR\x04info\"\x1d\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12)\n" +
+	"\x04info\x18\x03 \x01(\v2\x15.common_pack.RoomInfoR\x04info\"\x1d\n" +
 	"\vBuyShopItem\x12\x0e\n" +
 	"\x02id\x18\x01 \x01(\tR\x02id\"\xb2\x01\n" +
 	"\x14RequestAddFriendItem\x12\x0e\n" +
@@ -4017,49 +4011,49 @@ const file_common_proto_rawDesc = "" +
 	"\x06Status\x18\x05 \x01(\x05R\x06Status\x12\x18\n" +
 	"\aMessage\x18\x06 \x01(\tR\aMessage\"(\n" +
 	"\rReqFriendList\x12\x17\n" +
-	"\auser_id\x18\x01 \x01(\tR\x06userId\"l\n" +
+	"\auser_id\x18\x01 \x01(\tR\x06userId\"\x84\x01\n" +
 	"\rResFriendList\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12\x1d\n" +
-	"\x04list\x18\x03 \x03(\v2\t.UserInfoR\x04list\"\x8c\x01\n" +
-	"\x11FriendRequestItem\x12\x1d\n" +
-	"\x04info\x18\x01 \x01(\v2\t.UserInfoR\x04info\x12\x1f\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12)\n" +
+	"\x04list\x18\x03 \x03(\v2\x15.common_pack.UserInfoR\x04list\"\x98\x01\n" +
+	"\x11FriendRequestItem\x12)\n" +
+	"\x04info\x18\x01 \x01(\v2\x15.common_pack.UserInfoR\x04info\x12\x1f\n" +
 	"\vrequest_msg\x18\x02 \x01(\tR\n" +
 	"requestMsg\x12\x1f\n" +
 	"\vcreate_time\x18\x03 \x01(\tR\n" +
 	"createTime\x12\x16\n" +
 	"\x06status\x18\x04 \x01(\x05R\x06status\"/\n" +
 	"\x14ReqFriendRequestList\x12\x17\n" +
-	"\auser_id\x18\x01 \x01(\tR\x06userId\"|\n" +
+	"\auser_id\x18\x01 \x01(\tR\x06userId\"\x94\x01\n" +
 	"\x14ResFriendRequestList\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12&\n" +
-	"\x04list\x18\x03 \x03(\v2\x12.FriendRequestItemR\x04list\"<\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x122\n" +
+	"\x04list\x18\x03 \x03(\v2\x1e.common_pack.FriendRequestItemR\x04list\"<\n" +
 	"\fReqAddFriend\x12\x1a\n" +
 	"\bToUserID\x18\x01 \x01(\tR\bToUserID\x12\x10\n" +
-	"\x03msg\x18\x02 \x01(\tR\x03msg\"5\n" +
-	"\x14RecvAddFriendRequest\x12\x1d\n" +
-	"\x04info\x18\x01 \x01(\v2\t.UserInfoR\x04info\"@\n" +
-	"\x13OptAddFriendRequest\x12)\n" +
-	"\x04info\x18\x01 \x01(\v2\x15.RequestAddFriendItemR\x04info\"<\n" +
-	"\x0fNotifyOptFriend\x12)\n" +
-	"\x04info\x18\x01 \x01(\v2\x15.RequestAddFriendItemR\x04info\"%\n" +
+	"\x03msg\x18\x02 \x01(\tR\x03msg\"A\n" +
+	"\x14RecvAddFriendRequest\x12)\n" +
+	"\x04info\x18\x01 \x01(\v2\x15.common_pack.UserInfoR\x04info\"L\n" +
+	"\x13OptAddFriendRequest\x125\n" +
+	"\x04info\x18\x01 \x01(\v2!.common_pack.RequestAddFriendItemR\x04info\"H\n" +
+	"\x0fNotifyOptFriend\x125\n" +
+	"\x04info\x18\x01 \x01(\v2!.common_pack.RequestAddFriendItemR\x04info\"%\n" +
 	"\n" +
 	"SearchUser\x12\x17\n" +
-	"\auser_id\x18\x01 \x01(\tR\x06userId\"l\n" +
+	"\auser_id\x18\x01 \x01(\tR\x06userId\"\x84\x01\n" +
 	"\rResSearchUser\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12\x1d\n" +
-	"\x04info\x18\x03 \x01(\v2\t.UserInfoR\x04info\"-\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12)\n" +
+	"\x04info\x18\x03 \x01(\v2\x15.common_pack.UserInfoR\x04info\"-\n" +
 	"\x0fReqDeleteFriend\x12\x1a\n" +
-	"\bToUserID\x18\x01 \x01(\tR\bToUserID\"O\n" +
+	"\bToUserID\x18\x01 \x01(\tR\bToUserID\"[\n" +
 	"\x0fResDeleteFriend\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\"t\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\"\x8c\x01\n" +
 	"\x15ResFriendOnLineStatus\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12\x1d\n" +
-	"\x04info\x18\x03 \x01(\v2\t.UserInfoR\x04info\"\xb5\x01\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12)\n" +
+	"\x04info\x18\x03 \x01(\v2\x15.common_pack.UserInfoR\x04info\"\xb5\x01\n" +
 	"\vChatMessage\x12\x0e\n" +
 	"\x02id\x18\x01 \x01(\x05R\x02id\x12\x1d\n" +
 	"\n" +
@@ -4072,20 +4066,20 @@ const file_common_proto_rawDesc = "" +
 	"\x0eReqSendChatMsg\x12!\n" +
 	"\fcontent_type\x18\x01 \x01(\tR\vcontentType\x12\x1b\n" +
 	"\tto_userid\x18\x02 \x01(\tR\btoUserid\x12\x18\n" +
-	"\acontent\x18\x03 \x01(\tR\acontent\"N\n" +
+	"\acontent\x18\x03 \x01(\tR\acontent\"Z\n" +
 	"\x0eResSendChatMsg\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\"/\n" +
-	"\vRecvChatMsg\x12 \n" +
-	"\x04info\x18\x01 \x01(\v2\f.ChatMessageR\x04info\"L\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\";\n" +
+	"\vRecvChatMsg\x12,\n" +
+	"\x04info\x18\x01 \x01(\v2\x18.common_pack.ChatMessageR\x04info\"L\n" +
 	"\x0eReqChatHistory\x12\x1b\n" +
 	"\tto_userid\x18\x01 \x01(\tR\btoUserid\x12\x1d\n" +
 	"\n" +
-	"last_msgid\x18\x02 \x01(\x05R\tlastMsgid\"p\n" +
+	"last_msgid\x18\x02 \x01(\x05R\tlastMsgid\"\x88\x01\n" +
 	"\x0eResChatHistory\x12\x18\n" +
-	"\asuccess\x18\x01 \x01(\bR\asuccess\x12\"\n" +
-	"\aerr_msg\x18\x02 \x01(\v2\t.MsgErrorR\x06errMsg\x12 \n" +
-	"\x04list\x18\x03 \x03(\v2\f.ChatMessageR\x04list*K\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12,\n" +
+	"\x04list\x18\x03 \x03(\v2\x18.common_pack.ChatMessageR\x04list*K\n" +
 	"\broleType\x12\x15\n" +
 	"\x11ROLE_TYPE_UNKNOWN\x10\x00\x12\a\n" +
 	"\x03RED\x10\x01\x12\b\n" +
@@ -4138,141 +4132,141 @@ func file_common_proto_rawDescGZIP() []byte {
 var file_common_proto_enumTypes = make([]protoimpl.EnumInfo, 7)
 var file_common_proto_msgTypes = make([]protoimpl.MessageInfo, 59)
 var file_common_proto_goTypes = []any{
-	(RoleType)(0),                 // 0: roleType
-	(OptType)(0),                  // 1: OptType
-	(RoomType)(0),                 // 2: roomType
-	(RoomMode)(0),                 // 3: roomMode
-	(RoadType)(0),                 // 4: roadType
-	(PlayerStatus)(0),             // 5: playerStatus
-	(RoomStatus)(0),               // 6: roomStatus
-	(*Round)(nil),                 // 7: round
-	(*RoomInfo)(nil),              // 8: RoomInfo
-	(*RoleData)(nil),              // 9: RoleData
-	(*ColorData)(nil),             // 10: ColorData
-	(*MoveStepData)(nil),          // 11: MoveStepData
-	(*SendColorSz)(nil),           // 12: SendColorSz
-	(*SendRoleMove)(nil),          // 13: SendRoleMove
-	(*SendQuitRoom)(nil),          // 14: SendQuitRoom
-	(*NotifyPlayerSzNumber)(nil),  // 15: NotifyPlayerSzNumber
-	(*NotifyPlayerMove)(nil),      // 16: NotifyPlayerMove
-	(*NotifyPlayerOpt)(nil),       // 17: NotifyPlayerOpt
-	(*NotifyPlayerStatus)(nil),    // 18: NotifyPlayerStatus
-	(*NotifySettlement)(nil),      // 19: NotifySettlement
-	(*NotifyUpdateRoomInfo)(nil),  // 20: NotifyUpdateRoomInfo
-	(*UserInfo)(nil),              // 21: UserInfo
-	(*ReqLogin)(nil),              // 22: ReqLogin
-	(*ResLogin)(nil),              // 23: ResLogin
-	(*ReqRegister)(nil),           // 24: ReqRegister
-	(*ResRegister)(nil),           // 25: ResRegister
-	(*EnterHall)(nil),             // 26: EnterHall
-	(*ResEnterHall)(nil),          // 27: ResEnterHall
-	(*LeaveHall)(nil),             // 28: LeaveHall
-	(*MatchLudo)(nil),             // 29: MatchLudo
-	(*ResMatchLudo)(nil),          // 30: ResMatchLudo
-	(*MsgError)(nil),              // 31: MsgError
-	(*UpdateUserInfo)(nil),        // 32: UpdateUserInfo
-	(*ResHeartBeat)(nil),          // 33: ResHeartBeat
-	(*ReqHeartBeat)(nil),          // 34: ReqHeartBeat
-	(*ShopItem)(nil),              // 35: ShopItem
-	(*BeKickLogin)(nil),           // 36: BeKickLogin
-	(*ReqShop)(nil),               // 37: ReqShop
-	(*ResShop)(nil),               // 38: ResShop
-	(*HistoryRecord)(nil),         // 39: HistoryRecord
-	(*ReqLudoHistory)(nil),        // 40: ReqLudoHistory
-	(*ResLudoHistory)(nil),        // 41: ResLudoHistory
-	(*ReqLudoRoomInfo)(nil),       // 42: ReqLudoRoomInfo
-	(*ResLudoRoomInfo)(nil),       // 43: ResLudoRoomInfo
-	(*BuyShopItem)(nil),           // 44: BuyShopItem
-	(*RequestAddFriendItem)(nil),  // 45: RequestAddFriendItem
-	(*ReqFriendList)(nil),         // 46: ReqFriendList
-	(*ResFriendList)(nil),         // 47: ResFriendList
-	(*FriendRequestItem)(nil),     // 48: FriendRequestItem
-	(*ReqFriendRequestList)(nil),  // 49: ReqFriendRequestList
-	(*ResFriendRequestList)(nil),  // 50: ResFriendRequestList
-	(*ReqAddFriend)(nil),          // 51: ReqAddFriend
-	(*RecvAddFriendRequest)(nil),  // 52: RecvAddFriendRequest
-	(*OptAddFriendRequest)(nil),   // 53: OptAddFriendRequest
-	(*NotifyOptFriend)(nil),       // 54: NotifyOptFriend
-	(*SearchUser)(nil),            // 55: SearchUser
-	(*ResSearchUser)(nil),         // 56: ResSearchUser
-	(*ReqDeleteFriend)(nil),       // 57: ReqDeleteFriend
-	(*ResDeleteFriend)(nil),       // 58: ResDeleteFriend
-	(*ResFriendOnLineStatus)(nil), // 59: ResFriendOnLineStatus
-	(*ChatMessage)(nil),           // 60: ChatMessage
-	(*ReqSendChatMsg)(nil),        // 61: ReqSendChatMsg
-	(*ResSendChatMsg)(nil),        // 62: ResSendChatMsg
-	(*RecvChatMsg)(nil),           // 63: RecvChatMsg
-	(*ReqChatHistory)(nil),        // 64: ReqChatHistory
-	(*ResChatHistory)(nil),        // 65: ResChatHistory
+	(RoleType)(0),                 // 0: common_pack.roleType
+	(OptType)(0),                  // 1: common_pack.OptType
+	(RoomType)(0),                 // 2: common_pack.roomType
+	(RoomMode)(0),                 // 3: common_pack.roomMode
+	(RoadType)(0),                 // 4: common_pack.roadType
+	(PlayerStatus)(0),             // 5: common_pack.playerStatus
+	(RoomStatus)(0),               // 6: common_pack.roomStatus
+	(*Round)(nil),                 // 7: common_pack.round
+	(*RoomInfo)(nil),              // 8: common_pack.RoomInfo
+	(*RoleData)(nil),              // 9: common_pack.RoleData
+	(*ColorData)(nil),             // 10: common_pack.ColorData
+	(*MoveStepData)(nil),          // 11: common_pack.MoveStepData
+	(*SendColorSz)(nil),           // 12: common_pack.SendColorSz
+	(*SendRoleMove)(nil),          // 13: common_pack.SendRoleMove
+	(*SendQuitRoom)(nil),          // 14: common_pack.SendQuitRoom
+	(*NotifyPlayerSzNumber)(nil),  // 15: common_pack.NotifyPlayerSzNumber
+	(*NotifyPlayerMove)(nil),      // 16: common_pack.NotifyPlayerMove
+	(*NotifyPlayerOpt)(nil),       // 17: common_pack.NotifyPlayerOpt
+	(*NotifyPlayerStatus)(nil),    // 18: common_pack.NotifyPlayerStatus
+	(*NotifySettlement)(nil),      // 19: common_pack.NotifySettlement
+	(*NotifyUpdateRoomInfo)(nil),  // 20: common_pack.NotifyUpdateRoomInfo
+	(*UserInfo)(nil),              // 21: common_pack.UserInfo
+	(*ReqLogin)(nil),              // 22: common_pack.ReqLogin
+	(*ResLogin)(nil),              // 23: common_pack.ResLogin
+	(*ReqRegister)(nil),           // 24: common_pack.ReqRegister
+	(*ResRegister)(nil),           // 25: common_pack.ResRegister
+	(*EnterHall)(nil),             // 26: common_pack.EnterHall
+	(*ResEnterHall)(nil),          // 27: common_pack.ResEnterHall
+	(*LeaveHall)(nil),             // 28: common_pack.LeaveHall
+	(*MatchLudo)(nil),             // 29: common_pack.MatchLudo
+	(*ResMatchLudo)(nil),          // 30: common_pack.ResMatchLudo
+	(*MsgError)(nil),              // 31: common_pack.MsgError
+	(*UpdateUserInfo)(nil),        // 32: common_pack.UpdateUserInfo
+	(*ResHeartBeat)(nil),          // 33: common_pack.ResHeartBeat
+	(*ReqHeartBeat)(nil),          // 34: common_pack.ReqHeartBeat
+	(*ShopItem)(nil),              // 35: common_pack.ShopItem
+	(*BeKickLogin)(nil),           // 36: common_pack.BeKickLogin
+	(*ReqShop)(nil),               // 37: common_pack.ReqShop
+	(*ResShop)(nil),               // 38: common_pack.ResShop
+	(*HistoryRecord)(nil),         // 39: common_pack.HistoryRecord
+	(*ReqLudoHistory)(nil),        // 40: common_pack.ReqLudoHistory
+	(*ResLudoHistory)(nil),        // 41: common_pack.ResLudoHistory
+	(*ReqLudoRoomInfo)(nil),       // 42: common_pack.ReqLudoRoomInfo
+	(*ResLudoRoomInfo)(nil),       // 43: common_pack.ResLudoRoomInfo
+	(*BuyShopItem)(nil),           // 44: common_pack.BuyShopItem
+	(*RequestAddFriendItem)(nil),  // 45: common_pack.RequestAddFriendItem
+	(*ReqFriendList)(nil),         // 46: common_pack.ReqFriendList
+	(*ResFriendList)(nil),         // 47: common_pack.ResFriendList
+	(*FriendRequestItem)(nil),     // 48: common_pack.FriendRequestItem
+	(*ReqFriendRequestList)(nil),  // 49: common_pack.ReqFriendRequestList
+	(*ResFriendRequestList)(nil),  // 50: common_pack.ResFriendRequestList
+	(*ReqAddFriend)(nil),          // 51: common_pack.ReqAddFriend
+	(*RecvAddFriendRequest)(nil),  // 52: common_pack.RecvAddFriendRequest
+	(*OptAddFriendRequest)(nil),   // 53: common_pack.OptAddFriendRequest
+	(*NotifyOptFriend)(nil),       // 54: common_pack.NotifyOptFriend
+	(*SearchUser)(nil),            // 55: common_pack.SearchUser
+	(*ResSearchUser)(nil),         // 56: common_pack.ResSearchUser
+	(*ReqDeleteFriend)(nil),       // 57: common_pack.ReqDeleteFriend
+	(*ResDeleteFriend)(nil),       // 58: common_pack.ResDeleteFriend
+	(*ResFriendOnLineStatus)(nil), // 59: common_pack.ResFriendOnLineStatus
+	(*ChatMessage)(nil),           // 60: common_pack.ChatMessage
+	(*ReqSendChatMsg)(nil),        // 61: common_pack.ReqSendChatMsg
+	(*ResSendChatMsg)(nil),        // 62: common_pack.ResSendChatMsg
+	(*RecvChatMsg)(nil),           // 63: common_pack.RecvChatMsg
+	(*ReqChatHistory)(nil),        // 64: common_pack.ReqChatHistory
+	(*ResChatHistory)(nil),        // 65: common_pack.ResChatHistory
 }
 var file_common_proto_depIdxs = []int32{
-	0,  // 0: round.m_color:type_name -> roleType
-	1,  // 1: round.opt:type_name -> OptType
-	9,  // 2: RoomInfo.roles:type_name -> RoleData
-	10, // 3: RoomInfo.colors:type_name -> ColorData
-	2,  // 4: RoomInfo.room_type:type_name -> roomType
-	3,  // 5: RoomInfo.room_mode:type_name -> roomMode
-	0,  // 6: RoomInfo.cur_round_color:type_name -> roleType
-	7,  // 7: RoomInfo.rounds:type_name -> round
-	10, // 8: RoomInfo.finish_colors:type_name -> ColorData
-	10, // 9: RoomInfo.kict_colors:type_name -> ColorData
-	6,  // 10: RoomInfo.room_status:type_name -> roomStatus
-	17, // 11: RoomInfo.cur_color_opt_data:type_name -> NotifyPlayerOpt
-	0,  // 12: RoleData.m_color:type_name -> roleType
-	4,  // 13: RoleData.m_cur_road:type_name -> roadType
-	0,  // 14: ColorData.m_color:type_name -> roleType
-	0,  // 15: SendColorSz.color:type_name -> roleType
-	0,  // 16: SendRoleMove.color:type_name -> roleType
-	0,  // 17: SendQuitRoom.color:type_name -> roleType
-	0,  // 18: NotifyPlayerSzNumber.color:type_name -> roleType
-	31, // 19: NotifyPlayerSzNumber.err_msg:type_name -> MsgError
-	0,  // 20: NotifyPlayerMove.color:type_name -> roleType
-	11, // 21: NotifyPlayerMove.step:type_name -> MoveStepData
-	9,  // 22: NotifyPlayerMove.kick:type_name -> RoleData
-	0,  // 23: NotifyPlayerOpt.color:type_name -> roleType
-	1,  // 24: NotifyPlayerOpt.opt:type_name -> OptType
-	9,  // 25: NotifyPlayerOpt.canMoveRoles:type_name -> RoleData
-	0,  // 26: NotifyPlayerStatus.color:type_name -> roleType
-	5,  // 27: NotifyPlayerStatus.status:type_name -> playerStatus
-	10, // 28: NotifyPlayerStatus.colors:type_name -> ColorData
-	10, // 29: NotifyPlayerStatus.time_out_color:type_name -> ColorData
-	0,  // 30: NotifySettlement.color:type_name -> roleType
-	10, // 31: NotifySettlement.finish_colors:type_name -> ColorData
-	8,  // 32: NotifyUpdateRoomInfo.room_info:type_name -> RoomInfo
-	21, // 33: ResLogin.userInfo:type_name -> UserInfo
-	31, // 34: ResLogin.err_msg:type_name -> MsgError
-	31, // 35: ResRegister.err_msg:type_name -> MsgError
-	31, // 36: ResEnterHall.err_msg:type_name -> MsgError
-	8,  // 37: ResEnterHall.reconnect_room_info:type_name -> RoomInfo
-	2,  // 38: MatchLudo.select_room_type:type_name -> roomType
-	0,  // 39: MatchLudo.select_color:type_name -> roleType
-	31, // 40: ResMatchLudo.err_msg:type_name -> MsgError
-	8,  // 41: ResMatchLudo.room:type_name -> RoomInfo
-	21, // 42: UpdateUserInfo.info:type_name -> UserInfo
-	31, // 43: BeKickLogin.err_msg:type_name -> MsgError
-	31, // 44: ResShop.err_msg:type_name -> MsgError
-	35, // 45: ResShop.list:type_name -> ShopItem
-	31, // 46: ResLudoHistory.err_msg:type_name -> MsgError
-	39, // 47: ResLudoHistory.list:type_name -> HistoryRecord
-	31, // 48: ResLudoRoomInfo.err_msg:type_name -> MsgError
-	8,  // 49: ResLudoRoomInfo.info:type_name -> RoomInfo
-	31, // 50: ResFriendList.err_msg:type_name -> MsgError
-	21, // 51: ResFriendList.list:type_name -> UserInfo
-	21, // 52: FriendRequestItem.info:type_name -> UserInfo
-	31, // 53: ResFriendRequestList.err_msg:type_name -> MsgError
-	48, // 54: ResFriendRequestList.list:type_name -> FriendRequestItem
-	21, // 55: RecvAddFriendRequest.info:type_name -> UserInfo
-	45, // 56: OptAddFriendRequest.info:type_name -> RequestAddFriendItem
-	45, // 57: NotifyOptFriend.info:type_name -> RequestAddFriendItem
-	31, // 58: ResSearchUser.err_msg:type_name -> MsgError
-	21, // 59: ResSearchUser.info:type_name -> UserInfo
-	31, // 60: ResDeleteFriend.err_msg:type_name -> MsgError
-	31, // 61: ResFriendOnLineStatus.err_msg:type_name -> MsgError
-	21, // 62: ResFriendOnLineStatus.info:type_name -> UserInfo
-	31, // 63: ResSendChatMsg.err_msg:type_name -> MsgError
-	60, // 64: RecvChatMsg.info:type_name -> ChatMessage
-	31, // 65: ResChatHistory.err_msg:type_name -> MsgError
-	60, // 66: ResChatHistory.list:type_name -> ChatMessage
+	0,  // 0: common_pack.round.m_color:type_name -> common_pack.roleType
+	1,  // 1: common_pack.round.opt:type_name -> common_pack.OptType
+	9,  // 2: common_pack.RoomInfo.roles:type_name -> common_pack.RoleData
+	10, // 3: common_pack.RoomInfo.colors:type_name -> common_pack.ColorData
+	2,  // 4: common_pack.RoomInfo.room_type:type_name -> common_pack.roomType
+	3,  // 5: common_pack.RoomInfo.room_mode:type_name -> common_pack.roomMode
+	0,  // 6: common_pack.RoomInfo.cur_round_color:type_name -> common_pack.roleType
+	7,  // 7: common_pack.RoomInfo.rounds:type_name -> common_pack.round
+	10, // 8: common_pack.RoomInfo.finish_colors:type_name -> common_pack.ColorData
+	10, // 9: common_pack.RoomInfo.kict_colors:type_name -> common_pack.ColorData
+	6,  // 10: common_pack.RoomInfo.room_status:type_name -> common_pack.roomStatus
+	17, // 11: common_pack.RoomInfo.cur_color_opt_data:type_name -> common_pack.NotifyPlayerOpt
+	0,  // 12: common_pack.RoleData.m_color:type_name -> common_pack.roleType
+	4,  // 13: common_pack.RoleData.m_cur_road:type_name -> common_pack.roadType
+	0,  // 14: common_pack.ColorData.m_color:type_name -> common_pack.roleType
+	0,  // 15: common_pack.SendColorSz.color:type_name -> common_pack.roleType
+	0,  // 16: common_pack.SendRoleMove.color:type_name -> common_pack.roleType
+	0,  // 17: common_pack.SendQuitRoom.color:type_name -> common_pack.roleType
+	0,  // 18: common_pack.NotifyPlayerSzNumber.color:type_name -> common_pack.roleType
+	31, // 19: common_pack.NotifyPlayerSzNumber.err_msg:type_name -> common_pack.MsgError
+	0,  // 20: common_pack.NotifyPlayerMove.color:type_name -> common_pack.roleType
+	11, // 21: common_pack.NotifyPlayerMove.step:type_name -> common_pack.MoveStepData
+	9,  // 22: common_pack.NotifyPlayerMove.kick:type_name -> common_pack.RoleData
+	0,  // 23: common_pack.NotifyPlayerOpt.color:type_name -> common_pack.roleType
+	1,  // 24: common_pack.NotifyPlayerOpt.opt:type_name -> common_pack.OptType
+	9,  // 25: common_pack.NotifyPlayerOpt.canMoveRoles:type_name -> common_pack.RoleData
+	0,  // 26: common_pack.NotifyPlayerStatus.color:type_name -> common_pack.roleType
+	5,  // 27: common_pack.NotifyPlayerStatus.status:type_name -> common_pack.playerStatus
+	10, // 28: common_pack.NotifyPlayerStatus.colors:type_name -> common_pack.ColorData
+	10, // 29: common_pack.NotifyPlayerStatus.time_out_color:type_name -> common_pack.ColorData
+	0,  // 30: common_pack.NotifySettlement.color:type_name -> common_pack.roleType
+	10, // 31: common_pack.NotifySettlement.finish_colors:type_name -> common_pack.ColorData
+	8,  // 32: common_pack.NotifyUpdateRoomInfo.room_info:type_name -> common_pack.RoomInfo
+	21, // 33: common_pack.ResLogin.userInfo:type_name -> common_pack.UserInfo
+	31, // 34: common_pack.ResLogin.err_msg:type_name -> common_pack.MsgError
+	31, // 35: common_pack.ResRegister.err_msg:type_name -> common_pack.MsgError
+	31, // 36: common_pack.ResEnterHall.err_msg:type_name -> common_pack.MsgError
+	8,  // 37: common_pack.ResEnterHall.reconnect_room_info:type_name -> common_pack.RoomInfo
+	2,  // 38: common_pack.MatchLudo.select_room_type:type_name -> common_pack.roomType
+	0,  // 39: common_pack.MatchLudo.select_color:type_name -> common_pack.roleType
+	31, // 40: common_pack.ResMatchLudo.err_msg:type_name -> common_pack.MsgError
+	8,  // 41: common_pack.ResMatchLudo.room:type_name -> common_pack.RoomInfo
+	21, // 42: common_pack.UpdateUserInfo.info:type_name -> common_pack.UserInfo
+	31, // 43: common_pack.BeKickLogin.err_msg:type_name -> common_pack.MsgError
+	31, // 44: common_pack.ResShop.err_msg:type_name -> common_pack.MsgError
+	35, // 45: common_pack.ResShop.list:type_name -> common_pack.ShopItem
+	31, // 46: common_pack.ResLudoHistory.err_msg:type_name -> common_pack.MsgError
+	39, // 47: common_pack.ResLudoHistory.list:type_name -> common_pack.HistoryRecord
+	31, // 48: common_pack.ResLudoRoomInfo.err_msg:type_name -> common_pack.MsgError
+	8,  // 49: common_pack.ResLudoRoomInfo.info:type_name -> common_pack.RoomInfo
+	31, // 50: common_pack.ResFriendList.err_msg:type_name -> common_pack.MsgError
+	21, // 51: common_pack.ResFriendList.list:type_name -> common_pack.UserInfo
+	21, // 52: common_pack.FriendRequestItem.info:type_name -> common_pack.UserInfo
+	31, // 53: common_pack.ResFriendRequestList.err_msg:type_name -> common_pack.MsgError
+	48, // 54: common_pack.ResFriendRequestList.list:type_name -> common_pack.FriendRequestItem
+	21, // 55: common_pack.RecvAddFriendRequest.info:type_name -> common_pack.UserInfo
+	45, // 56: common_pack.OptAddFriendRequest.info:type_name -> common_pack.RequestAddFriendItem
+	45, // 57: common_pack.NotifyOptFriend.info:type_name -> common_pack.RequestAddFriendItem
+	31, // 58: common_pack.ResSearchUser.err_msg:type_name -> common_pack.MsgError
+	21, // 59: common_pack.ResSearchUser.info:type_name -> common_pack.UserInfo
+	31, // 60: common_pack.ResDeleteFriend.err_msg:type_name -> common_pack.MsgError
+	31, // 61: common_pack.ResFriendOnLineStatus.err_msg:type_name -> common_pack.MsgError
+	21, // 62: common_pack.ResFriendOnLineStatus.info:type_name -> common_pack.UserInfo
+	31, // 63: common_pack.ResSendChatMsg.err_msg:type_name -> common_pack.MsgError
+	60, // 64: common_pack.RecvChatMsg.info:type_name -> common_pack.ChatMessage
+	31, // 65: common_pack.ResChatHistory.err_msg:type_name -> common_pack.MsgError
+	60, // 66: common_pack.ResChatHistory.list:type_name -> common_pack.ChatMessage
 	67, // [67:67] is the sub-list for method output_type
 	67, // [67:67] is the sub-list for method input_type
 	67, // [67:67] is the sub-list for extension type_name

+ 279 - 0
src/server/msg/mail.pb.go

@@ -0,0 +1,279 @@
+// Code generated by protoc-gen-go. DO NOT EDIT.
+// versions:
+// 	protoc-gen-go v1.36.6
+// 	protoc        v3.21.5
+// source: mail.proto
+
+package msg
+
+import (
+	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
+	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
+	reflect "reflect"
+	sync "sync"
+	unsafe "unsafe"
+)
+
+const (
+	// Verify that this generated code is sufficiently up-to-date.
+	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
+	// Verify that runtime/protoimpl is sufficiently up-to-date.
+	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
+)
+
+// 请求获取邮箱
+type ReqMail struct {
+	state         protoimpl.MessageState `protogen:"open.v1"`
+	Userid        string                 `protobuf:"bytes,1,opt,name=userid,proto3" json:"userid,omitempty"`
+	MailType      int32                  `protobuf:"varint,2,opt,name=mail_type,json=mailType,proto3" json:"mail_type,omitempty"`
+	unknownFields protoimpl.UnknownFields
+	sizeCache     protoimpl.SizeCache
+}
+
+func (x *ReqMail) Reset() {
+	*x = ReqMail{}
+	mi := &file_mail_proto_msgTypes[0]
+	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+	ms.StoreMessageInfo(mi)
+}
+
+func (x *ReqMail) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*ReqMail) ProtoMessage() {}
+
+func (x *ReqMail) ProtoReflect() protoreflect.Message {
+	mi := &file_mail_proto_msgTypes[0]
+	if x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use ReqMail.ProtoReflect.Descriptor instead.
+func (*ReqMail) Descriptor() ([]byte, []int) {
+	return file_mail_proto_rawDescGZIP(), []int{0}
+}
+
+func (x *ReqMail) GetUserid() string {
+	if x != nil {
+		return x.Userid
+	}
+	return ""
+}
+
+func (x *ReqMail) GetMailType() int32 {
+	if x != nil {
+		return x.MailType
+	}
+	return 0
+}
+
+// 响应获取邮箱列表
+type ResMail struct {
+	state         protoimpl.MessageState `protogen:"open.v1"`
+	Success       bool                   `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
+	ErrMsg        *MsgError              `protobuf:"bytes,2,opt,name=err_msg,json=errMsg,proto3" json:"err_msg,omitempty"`
+	List          []*ChatMessage         `protobuf:"bytes,3,rep,name=list,proto3" json:"list,omitempty"`
+	unknownFields protoimpl.UnknownFields
+	sizeCache     protoimpl.SizeCache
+}
+
+func (x *ResMail) Reset() {
+	*x = ResMail{}
+	mi := &file_mail_proto_msgTypes[1]
+	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+	ms.StoreMessageInfo(mi)
+}
+
+func (x *ResMail) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*ResMail) ProtoMessage() {}
+
+func (x *ResMail) ProtoReflect() protoreflect.Message {
+	mi := &file_mail_proto_msgTypes[1]
+	if x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use ResMail.ProtoReflect.Descriptor instead.
+func (*ResMail) Descriptor() ([]byte, []int) {
+	return file_mail_proto_rawDescGZIP(), []int{1}
+}
+
+func (x *ResMail) GetSuccess() bool {
+	if x != nil {
+		return x.Success
+	}
+	return false
+}
+
+func (x *ResMail) GetErrMsg() *MsgError {
+	if x != nil {
+		return x.ErrMsg
+	}
+	return nil
+}
+
+func (x *ResMail) GetList() []*ChatMessage {
+	if x != nil {
+		return x.List
+	}
+	return nil
+}
+
+// 操作邮箱
+type OptMail struct {
+	state         protoimpl.MessageState `protogen:"open.v1"`
+	MailId        int32                  `protobuf:"varint,1,opt,name=mail_id,json=mailId,proto3" json:"mail_id,omitempty"`
+	CheckStatus   int32                  `protobuf:"varint,2,opt,name=check_status,json=checkStatus,proto3" json:"check_status,omitempty"`
+	ReceiveStatus int32                  `protobuf:"varint,3,opt,name=receive_status,json=receiveStatus,proto3" json:"receive_status,omitempty"`
+	IsDelete      bool                   `protobuf:"varint,4,opt,name=is_delete,json=isDelete,proto3" json:"is_delete,omitempty"`
+	unknownFields protoimpl.UnknownFields
+	sizeCache     protoimpl.SizeCache
+}
+
+func (x *OptMail) Reset() {
+	*x = OptMail{}
+	mi := &file_mail_proto_msgTypes[2]
+	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+	ms.StoreMessageInfo(mi)
+}
+
+func (x *OptMail) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*OptMail) ProtoMessage() {}
+
+func (x *OptMail) ProtoReflect() protoreflect.Message {
+	mi := &file_mail_proto_msgTypes[2]
+	if x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use OptMail.ProtoReflect.Descriptor instead.
+func (*OptMail) Descriptor() ([]byte, []int) {
+	return file_mail_proto_rawDescGZIP(), []int{2}
+}
+
+func (x *OptMail) GetMailId() int32 {
+	if x != nil {
+		return x.MailId
+	}
+	return 0
+}
+
+func (x *OptMail) GetCheckStatus() int32 {
+	if x != nil {
+		return x.CheckStatus
+	}
+	return 0
+}
+
+func (x *OptMail) GetReceiveStatus() int32 {
+	if x != nil {
+		return x.ReceiveStatus
+	}
+	return 0
+}
+
+func (x *OptMail) GetIsDelete() bool {
+	if x != nil {
+		return x.IsDelete
+	}
+	return false
+}
+
+var File_mail_proto protoreflect.FileDescriptor
+
+const file_mail_proto_rawDesc = "" +
+	"\n" +
+	"\n" +
+	"mail.proto\x1a\fcommon.proto\">\n" +
+	"\aReqMail\x12\x16\n" +
+	"\x06userid\x18\x01 \x01(\tR\x06userid\x12\x1b\n" +
+	"\tmail_type\x18\x02 \x01(\x05R\bmailType\"\x81\x01\n" +
+	"\aResMail\x12\x18\n" +
+	"\asuccess\x18\x01 \x01(\bR\asuccess\x12.\n" +
+	"\aerr_msg\x18\x02 \x01(\v2\x15.common_pack.MsgErrorR\x06errMsg\x12,\n" +
+	"\x04list\x18\x03 \x03(\v2\x18.common_pack.ChatMessageR\x04list\"\x89\x01\n" +
+	"\aOptMail\x12\x17\n" +
+	"\amail_id\x18\x01 \x01(\x05R\x06mailId\x12!\n" +
+	"\fcheck_status\x18\x02 \x01(\x05R\vcheckStatus\x12%\n" +
+	"\x0ereceive_status\x18\x03 \x01(\x05R\rreceiveStatus\x12\x1b\n" +
+	"\tis_delete\x18\x04 \x01(\bR\bisDeleteB\aZ\x05./msgb\x06proto3"
+
+var (
+	file_mail_proto_rawDescOnce sync.Once
+	file_mail_proto_rawDescData []byte
+)
+
+func file_mail_proto_rawDescGZIP() []byte {
+	file_mail_proto_rawDescOnce.Do(func() {
+		file_mail_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mail_proto_rawDesc), len(file_mail_proto_rawDesc)))
+	})
+	return file_mail_proto_rawDescData
+}
+
+var file_mail_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
+var file_mail_proto_goTypes = []any{
+	(*ReqMail)(nil),     // 0: ReqMail
+	(*ResMail)(nil),     // 1: ResMail
+	(*OptMail)(nil),     // 2: OptMail
+	(*MsgError)(nil),    // 3: common_pack.MsgError
+	(*ChatMessage)(nil), // 4: common_pack.ChatMessage
+}
+var file_mail_proto_depIdxs = []int32{
+	3, // 0: ResMail.err_msg:type_name -> common_pack.MsgError
+	4, // 1: ResMail.list:type_name -> common_pack.ChatMessage
+	2, // [2:2] is the sub-list for method output_type
+	2, // [2:2] is the sub-list for method input_type
+	2, // [2:2] is the sub-list for extension type_name
+	2, // [2:2] is the sub-list for extension extendee
+	0, // [0:2] is the sub-list for field type_name
+}
+
+func init() { file_mail_proto_init() }
+func file_mail_proto_init() {
+	if File_mail_proto != nil {
+		return
+	}
+	file_common_proto_init()
+	type x struct{}
+	out := protoimpl.TypeBuilder{
+		File: protoimpl.DescBuilder{
+			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
+			RawDescriptor: unsafe.Slice(unsafe.StringData(file_mail_proto_rawDesc), len(file_mail_proto_rawDesc)),
+			NumEnums:      0,
+			NumMessages:   3,
+			NumExtensions: 0,
+			NumServices:   0,
+		},
+		GoTypes:           file_mail_proto_goTypes,
+		DependencyIndexes: file_mail_proto_depIdxs,
+		MessageInfos:      file_mail_proto_msgTypes,
+	}.Build()
+	File_mail_proto = out.File
+	file_mail_proto_goTypes = nil
+	file_mail_proto_depIdxs = nil
+}

+ 4 - 0
src/server/msg/msg.go

@@ -79,6 +79,10 @@ func init() {
 	Processor.Register(&ReqChatHistory{})
 	Processor.Register(&ResChatHistory{})
 
+	Processor.Register(&ReqMail{})
+	Processor.Register(&ResMail{})
+	Processor.Register(&OptMail{})
+
 	Processor.Range(func(id uint16, t reflect.Type) {
 		log.Debug("消息ID: %d, 消息类型: %s\n", id, t.Elem().Name())
 		msgList = append(msgList, MsgInfo{