From bb9c916232c605571321f523802c17c469c8ab1c Mon Sep 17 00:00:00 2001 From: zhanghualin <286990256@qq.com> Date: Fri, 11 Mar 2022 15:36:34 +0800 Subject: [PATCH] 新增proto注释 //ResponseCmd 用于约定消息回包对应类型 message 名字后面 大括号前面 需要一个空格 --- game.proto | 3 ++- models.proto | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/game.proto b/game.proto index c9f78e9..01d9f41 100644 --- a/game.proto +++ b/game.proto @@ -9,12 +9,13 @@ message HeartReq { int64 code = 1; } +//ResponseCmd RoleRsp message LoginReq { string uid = 1; string device = 2; } -message LoginResponse{ +message LoginResponse { string uid = 1; string device = 2; } diff --git a/models.proto b/models.proto index 0502026..0def334 100644 --- a/models.proto +++ b/models.proto @@ -4,7 +4,7 @@ option go_package = "./pb;pb"; package models; //import "google/protobuf/empty.proto"; -message Account{ +message Account { string phone = 1; // @inject_tag: index:"unique" pri:"1" string password = 2; string uid = 3; @@ -38,7 +38,7 @@ message Team { string hero_ids = 2; } -message Role{ +message Role { int64 id = 1; // @inject_tag: index:"unique" pri:"1" string uid = 2;// @inject_tag: index:"unique" string device = 3; -- libgit2 0.21.2