fork/rust_serialization_benchmark

git clone https://git.julia.blue/fork/rust_serialization_benchmark

David KoloskiAdd prost benches, update benchmark numbers35fba56

bebop
2.5 KiB116 linesraw
1syntax = "proto3";
2
3package prost.minecraft_savedata;
4
5enum GameType {
6    SURVIVAL = 0;
7    CREATIVE = 1;
8    ADVENTURE = 2;
9    SPECTATOR = 3;
10}
11
12message Item {
13    int32 count = 1;
14    uint32 slot = 2;
15    string id = 3;
16}
17
18message Abilities {
19    float walk_speed = 1;
20    float fly_speed = 2;
21    bool may_fly = 3;
22    bool flying = 4;
23    bool invulnerable = 5;
24    bool may_build = 6;
25    bool instabuild = 7;
26}
27
28message Vector3d {
29    double x = 1;
30    double y = 2;
31    double z = 3;
32}
33
34message Vector2f {
35    float x = 1;
36    float y = 2;
37}
38
39message Uuid {
40    uint32 x0 = 1;
41    uint32 x1 = 2;
42    uint32 x2 = 3;
43    uint32 x3 = 4;
44}
45
46message Entity {
47    string id = 1;
48    Vector3d pos = 2;
49    Vector3d motion = 3;
50    Vector2f rotation = 4;
51    float fall_distance = 5;
52    uint32 fire = 6;
53    uint32 air = 7;
54    bool on_ground = 8;
55    bool no_gravity = 9;
56    bool invulnerable = 10;
57    int32 portal_cooldown = 11;
58    Uuid uuid = 12;
59    optional string custom_name = 13;
60    bool custom_name_visible = 14;
61    bool silent = 15;
62    bool glowing = 16;
63}
64
65message RecipeBook {
66    repeated string recipes = 1;
67    repeated string to_be_displayed = 2;
68    bool is_filtering_craftable = 3;
69    bool is_gui_open = 4;
70    bool is_furnace_filtering_craftable = 5;
71    bool is_furnace_gui_open = 6;
72    bool is_blasting_furnace_filtering_craftable = 7;
73    bool is_blasting_furnace_gui_open = 8;
74    bool is_smoker_filtering_craftable = 9;
75    bool is_smoker_gui_open = 10;
76}
77
78message Vehicle {
79    Uuid uuid = 1;
80    Entity entity = 2;
81}
82
83message Player {
84    GameType game_type = 1;
85    GameType previous_game_type = 2;
86    uint64 score = 3;
87    string dimension = 4;
88    uint32 selected_item_slot = 5;
89    Item selected_item = 6;
90    optional string spawn_dimension = 7;
91    int64 spawn_x = 8;
92    int64 spawn_y = 9;
93    int64 spawn_z = 10;
94    optional bool spawn_forced = 11;
95    uint32 sleep_timer = 12;
96    float food_exhaustion_level = 13;
97    float food_saturation_level = 14;
98    uint32 food_tick_timer = 15;
99    uint32 xp_level = 16;
100    float xp_p = 17;
101    int32 xp_total = 18;
102    int32 xp_seed = 19;
103    repeated Item inventory = 20;
104    repeated Item ender_items = 21;
105    Abilities abilities = 22;
106    optional Vector3d entered_nether_position = 23;
107    optional Vehicle root_vehicle = 24;
108    optional Entity shoulder_entity_left = 25;
109    optional Entity shoulder_entity_right = 26;
110    bool seen_credits = 27;
111    RecipeBook recipe_book = 28;
112}
113
114message Players {
115    repeated Player players = 1;
116}