// Copyright 2019 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. syntax = "proto3"; package dofagon; option go_package = "github.com/castbox/guru-proto/dof/pb"; message ClientInitialize { int64 cid = 1; string uid = 2; } message Memos { repeated Memo memos = 1; } message Memo { oneof recipient { int64 to = 1; int64 everyone_but = 2; bool everyone = 3; } oneof actual { PlayerEnter player_enter = 10; DownloadResource download_resource = 11; LevelPrepared level_prepared = 12; GameStart game_start = 13; PointFound point_found = 14; LevelEnd level_end = 15; AllLevelEnd all_level_end = 16; ScoreSettlement score_settlement = 17; PlayerLeave player_leave = 18; } } // 客户端发送给服务器的消息 message PlayerEnter { int64 cid = 1; string nick_name = 2; string country = 3; } message LevelResource { string level = 1; } message DownloadResource { repeated LevelResource level_resource = 1; } message LevelPrepared { int64 cid = 1; } message GameStart { int64 cid = 1; } message PointFound { int64 cid = 1; int64 point_id = 2; string level = 3; } message LevelEnd { int64 cid = 1; string level = 2; } message AllLevelEnd { int64 cid = 1; } // 结算,翻译成英文是settlement message ScoreSettlement { int64 cid = 1; int64 score = 2; } message PlayerLeave { int64 cid = 1; }