123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105 |
- syntax = "proto3";
- package gamelang;
- option go_package = "/gamelang/jeopardypb";
- message Challenge {
- uint32 id = 1;
- string description = 2;
- string clue = 3;
- string solution = 4;
- string url = 5;
- uint32 points = 6;
- bool checked = 7;
- repeated string checker = 8;
- repeated string moderators = 9;
- }
- message Category {
- uint32 id = 1;
- string name = 2;
- string description = 3;
- repeated Challenge challenges = 4;
- repeated string moderators = 5;
- }
- message Round {
- uint32 id = 1;
- string name = 2;
- string description = 3;
- repeated Category categories = 4;
- repeated uint32 curcats = 5;
- repeated string moderators = 6;
- }
- message Option {
- string key = 1;
- string value = 2;
- enum TypeEnum {
- STRING = 0;
- BOOL = 1;
- INT = 2;
- }
- TypeEnum type = 3;
- bool bool = 4;
- uint32 int = 5;
- }
- message Event {
- string type = 1;
- string game = 2;
- string value = 3;
- string gamename = 4;
- string username = 5;
- repeated string neighborgames = 6;
- }
- service EventService {
- rpc Inform (Event) returns (Event);
- }
- message Player {
- uint32 id = 1;
- enum type {
- SHOWMASTER = 0;
- CONTESTANT = 1;
- VIEWER = 2;
- }
- string name = 2;
- uint32 points = 3;
- }
- message Jeopardy {
- uint32 id = 1;
- string name = 2;
- repeated Option options = 3;
- repeated Round rounds = 4;
- uint32 curround = 5;
- repeated Player players = 6;
- bool started = 7;
- bool finished = 8;
- string winner = 9;
- repeated string moderators = 10;
- }
- service JeopardyService {
- rpc CreateJeopardy (Jeopardy) returns (Jeopardy);
- rpc UpdateJeopardy (Jeopardy) returns (Jeopardy);
- rpc DeleteJeopardy (Jeopardy) returns (Jeopardy);
- rpc GetJeopardy (Jeopardy) returns (Jeopardy);
- rpc ListJeopardy (Jeopardy) returns (stream Jeopardy);
-
- rpc CreateRound (Round) returns (Round);
- rpc UpdateRound (Round) returns (Round);
- rpc DeleteRound (Round) returns (Round);
- rpc GetRound (Round) returns (Round);
- rpc ListRound (Round) returns (stream Round);
- rpc CreateChallenge (Challenge) returns (Challenge);
- rpc UpdateChallenge (Challenge) returns (Challenge);
- rpc DeleteChallenge (Challenge) returns (Challenge);
- rpc GetChallenge (Challenge) returns (Challenge);
- rpc ListChallenge (Challenge) returns (stream Challenge);
- }
|