// Message2Client syntax = "proto3"; package protobuf; import "MessageType.proto"; message MessageOfHuman { int32 x = 1; int32 y = 2; int32 speed = 3; int32 life = 4; // 本次未倒地前的血量,也即还可以受的伤害 int32 hanged_time = 5; // 被挂上的次数 double time_until_skill_available = 6; PlaceType place = 7; PropType prop = 8; HumanType human_type = 9; int64 guid = 10; bool on_chair = 11; // 是否被挂 double chair_time = 12; // 被挂的时间 bool on_ground = 13; // 是否倒地 double ground_time = 14; // 倒地时间 int64 player_id = 15; int32 view_range = 16; // 视野距离 repeated HumanBuffType buff = 17; } message MessageOfButcher { int32 x = 1; int32 y = 2; int32 speed = 3; int32 damage = 4; double time_until_skill_available = 5; PlaceType place = 6; PropType prop = 7; ButcherType butcher_type = 8; int64 guid = 9; bool movable = 10; // 是否进入了攻击后摇 int64 playerID = 11; int32 view_range = 12; // 视野距离 repeated ButcherBuffType buff = 13; } message MessageOfProp // 可拾取道具的信息 { PropType type = 1; int32 x = 2; int32 y = 3; double facing_direction = 4; int64 guid = 5; PlaceType place = 6; int32 size = 7; bool is_moving = 8; } message MessageOfPickedProp //for Unity,直接继承自THUAI5 { PropType type = 1; int32 x = 2; int32 y = 3; double facing_direction = 4; int64 mapping_id = 5; } message MessageOfMap { message Row { repeated PlaceType col = 1; } repeated Row row = 2; } message MessageToClient { repeated MessageOfHuman human_message = 1; repeated MessageOfButcher butcher_message = 2; // 是否真正repeated待定 repeated MessageOfProp prop_message = 3; MessageOfMap map_massage = 4; } message MoveRes // 如果打算设计撞墙保留平行速度分量,且需要返回值则可用这个(大概没啥用) { int64 actual_speed = 1; double actual_angle = 2; } message BoolRes // 用于只需要判断执行操作是否成功的行为,如捡起道具、使用道具 { bool act_success = 1; } message MsgRes // 用于获取队友发来的消息 { bool have_message = 1; // 是否有待接收的消息 int64 from_player_id = 2; string message_received = 3; }