You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
876 B
34 lines
876 B
syntax = "proto3";
|
|
|
|
import "google/protobuf/empty.proto";
|
|
import "common.proto";
|
|
|
|
package connection;
|
|
|
|
// Connection utilities to get a client_id
|
|
// service Connection {
|
|
// rpc name(google.protobuf.Empty) returns(common.Name);
|
|
// rpc connect(common.Name) returns(UserID);
|
|
// rpc joinLobbyWithCode(LobbyCode) returns(google.protobuf.Empty);
|
|
// rpc createLobby(LobbyConfig) returns(LobbyCode);
|
|
// rpc getGames(google.protobuf.Empty) returns(stream Game);
|
|
// rpc getPublicLobbies (google.protobuf.Empty) returns (stream LobbyCode);
|
|
// rpc disconnect (google.protobuf.Empty) returns (google.protobuf.Empty);
|
|
// }
|
|
|
|
message Game {
|
|
string name = 1;
|
|
string version = 2;
|
|
repeated string authors = 3;
|
|
uint32 id = 4;
|
|
}
|
|
|
|
|
|
message UserID { string id = 1; }
|
|
|
|
message LobbyConfig {
|
|
bool public = 1;
|
|
// repeated uint32 allowed_games = 2;
|
|
}
|
|
|
|
message LobbyCode { uint32 code = 1; }
|