diff --git a/CAPI/proto/Message2Clients.pb.cc b/CAPI/proto/Message2Clients.pb.cc index a9d54da..6f266ee 100644 --- a/CAPI/proto/Message2Clients.pb.cc +++ b/CAPI/proto/Message2Clients.pb.cc @@ -66,6 +66,50 @@ namespace protobuf }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MessageOfTrickerDefaultTypeInternal _MessageOfTricker_default_instance_; + PROTOBUF_CONSTEXPR MessageOfBullet::MessageOfBullet( + ::_pbi::ConstantInitialized + ) : + _impl_{ + /*decltype(_impl_.type_)*/ 0, /*decltype(_impl_.x_)*/ 0, /*decltype(_impl_.facing_direction_)*/ 0, /*decltype(_impl_.guid_)*/ int64_t{0}, /*decltype(_impl_.y_)*/ 0, /*decltype(_impl_.place_)*/ 0, /*decltype(_impl_.parent_team_id_)*/ int64_t{0}, /*decltype(_impl_.bomb_range_)*/ 0, /*decltype(_impl_._cached_size_)*/ {}} + { + } + struct MessageOfBulletDefaultTypeInternal + { + PROTOBUF_CONSTEXPR MessageOfBulletDefaultTypeInternal() : + _instance(::_pbi::ConstantInitialized{}) + { + } + ~MessageOfBulletDefaultTypeInternal() + { + } + union + { + MessageOfBullet _instance; + }; + }; + PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MessageOfBulletDefaultTypeInternal _MessageOfBullet_default_instance_; + PROTOBUF_CONSTEXPR MessageOfBombedBullet::MessageOfBombedBullet( + ::_pbi::ConstantInitialized + ) : + _impl_{ + /*decltype(_impl_.type_)*/ 0, /*decltype(_impl_.x_)*/ 0, /*decltype(_impl_.facing_direction_)*/ 0, /*decltype(_impl_.mapping_id_)*/ int64_t{0}, /*decltype(_impl_.bomb_range_)*/ 0, /*decltype(_impl_.y_)*/ 0, /*decltype(_impl_._cached_size_)*/ {}} + { + } + struct MessageOfBombedBulletDefaultTypeInternal + { + PROTOBUF_CONSTEXPR MessageOfBombedBulletDefaultTypeInternal() : + _instance(::_pbi::ConstantInitialized{}) + { + } + ~MessageOfBombedBulletDefaultTypeInternal() + { + } + union + { + MessageOfBombedBullet _instance; + }; + }; + PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MessageOfBombedBulletDefaultTypeInternal _MessageOfBombedBullet_default_instance_; PROTOBUF_CONSTEXPR MessageOfProp::MessageOfProp( ::_pbi::ConstantInitialized ) : @@ -243,7 +287,7 @@ namespace protobuf }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MsgResDefaultTypeInternal _MsgRes_default_instance_; } // namespace protobuf -static ::_pb::Metadata file_level_metadata_Message2Clients_2eproto[10]; +static ::_pb::Metadata file_level_metadata_Message2Clients_2eproto[12]; static constexpr ::_pb::EnumDescriptor const** file_level_enum_descriptors_Message2Clients_2eproto = nullptr; static constexpr ::_pb::ServiceDescriptor const** file_level_service_descriptors_Message2Clients_2eproto = nullptr; @@ -293,6 +337,32 @@ const uint32_t TableStruct_Message2Clients_2eproto::offsets[] PROTOBUF_SECTION_V PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfTricker, _impl_.radius_), PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfTricker, _impl_.buff_), ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _impl_.type_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _impl_.x_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _impl_.y_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _impl_.facing_direction_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _impl_.guid_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _impl_.parent_team_id_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _impl_.place_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBullet, _impl_.bomb_range_), + ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBombedBullet, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBombedBullet, _impl_.type_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBombedBullet, _impl_.x_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBombedBullet, _impl_.y_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBombedBullet, _impl_.facing_direction_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBombedBullet, _impl_.mapping_id_), + PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfBombedBullet, _impl_.bomb_range_), + ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::protobuf::MessageOfProp, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ @@ -371,19 +441,23 @@ const uint32_t TableStruct_Message2Clients_2eproto::offsets[] PROTOBUF_SECTION_V static const ::_pbi::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { {0, -1, -1, sizeof(::protobuf::MessageOfStudent)}, {24, -1, -1, sizeof(::protobuf::MessageOfTricker)}, - {44, -1, -1, sizeof(::protobuf::MessageOfProp)}, - {58, -1, -1, sizeof(::protobuf::MessageOfPickedProp)}, - {69, -1, -1, sizeof(::protobuf::MessageOfMap_Row)}, - {76, -1, -1, sizeof(::protobuf::MessageOfMap)}, - {83, -1, -1, sizeof(::protobuf::MessageToClient)}, - {94, -1, -1, sizeof(::protobuf::MoveRes)}, - {103, -1, -1, sizeof(::protobuf::BoolRes)}, - {110, -1, -1, sizeof(::protobuf::MsgRes)}, + {44, -1, -1, sizeof(::protobuf::MessageOfBullet)}, + {58, -1, -1, sizeof(::protobuf::MessageOfBombedBullet)}, + {70, -1, -1, sizeof(::protobuf::MessageOfProp)}, + {84, -1, -1, sizeof(::protobuf::MessageOfPickedProp)}, + {95, -1, -1, sizeof(::protobuf::MessageOfMap_Row)}, + {102, -1, -1, sizeof(::protobuf::MessageOfMap)}, + {109, -1, -1, sizeof(::protobuf::MessageToClient)}, + {120, -1, -1, sizeof(::protobuf::MoveRes)}, + {129, -1, -1, sizeof(::protobuf::BoolRes)}, + {136, -1, -1, sizeof(::protobuf::MsgRes)}, }; static const ::_pb::Message* const file_default_instances[] = { &::protobuf::_MessageOfStudent_default_instance_._instance, &::protobuf::_MessageOfTricker_default_instance_._instance, + &::protobuf::_MessageOfBullet_default_instance_._instance, + &::protobuf::_MessageOfBombedBullet_default_instance_._instance, &::protobuf::_MessageOfProp_default_instance_._instance, &::protobuf::_MessageOfPickedProp_default_instance_._instance, &::protobuf::_MessageOfMap_Row_default_instance_._instance, @@ -416,28 +490,37 @@ const char descriptor_table_protodef_Message2Clients_2eproto[] PROTOBUF_SECTION_ "ickerType\022\014\n\004guid\030\t \001(\003\022\017\n\007movable\030\n \001(\010" "\022\021\n\tplayer_id\030\013 \001(\003\022\022\n\nview_range\030\014 \001(\005\022" "\016\n\006radius\030\r \001(\005\022\'\n\004buff\030\016 \003(\0162\031.protobuf" - ".TrickerBuffType\"\264\001\n\rMessageOfProp\022 \n\004ty" - "pe\030\001 \001(\0162\022.protobuf.PropType\022\t\n\001x\030\002 \001(\005\022" - "\t\n\001y\030\003 \001(\005\022\030\n\020facing_direction\030\004 \001(\001\022\014\n\004" - "guid\030\005 \001(\003\022\"\n\005place\030\006 \001(\0162\023.protobuf.Pla" - "ceType\022\014\n\004size\030\007 \001(\005\022\021\n\tis_moving\030\010 \001(\010\"" - "{\n\023MessageOfPickedProp\022 \n\004type\030\001 \001(\0162\022.p" + ".TrickerBuffType\"\303\001\n\017MessageOfBullet\022\"\n\004" + "type\030\001 \001(\0162\024.protobuf.BulletType\022\t\n\001x\030\002 " + "\001(\005\022\t\n\001y\030\003 \001(\005\022\030\n\020facing_direction\030\004 \001(\001" + "\022\014\n\004guid\030\005 \001(\003\022\026\n\016parent_team_id\030\006 \001(\003\022\"" + "\n\005place\030\007 \001(\0162\023.protobuf.PlaceType\022\022\n\nbo" + "mb_range\030\010 \001(\001\"\223\001\n\025MessageOfBombedBullet" + "\022\"\n\004type\030\001 \001(\0162\024.protobuf.BulletType\022\t\n\001" + "x\030\002 \001(\005\022\t\n\001y\030\003 \001(\005\022\030\n\020facing_direction\030\004" + " \001(\001\022\022\n\nmapping_id\030\005 \001(\003\022\022\n\nbomb_range\030\006" + " \001(\001\"\264\001\n\rMessageOfProp\022 \n\004type\030\001 \001(\0162\022.p" "rotobuf.PropType\022\t\n\001x\030\002 \001(\005\022\t\n\001y\030\003 \001(\005\022\030" - "\n\020facing_direction\030\004 \001(\001\022\022\n\nmapping_id\030\005" - " \001(\003\"`\n\014MessageOfMap\022\'\n\003row\030\002 \003(\0132\032.prot" - "obuf.MessageOfMap.Row\032\'\n\003Row\022 \n\003col\030\001 \003(" - "\0162\023.protobuf.PlaceType\"\200\002\n\017MessageToClie" - "nt\0223\n\017student_message\030\001 \003(\0132\032.protobuf.M" - "essageOfStudent\0223\n\017tricker_message\030\002 \003(\013" - "2\032.protobuf.MessageOfTricker\022-\n\014prop_mes" - "sage\030\003 \003(\0132\027.protobuf.MessageOfProp\022+\n\013m" - "ap_message\030\004 \001(\0132\026.protobuf.MessageOfMap" - "\022\'\n\ngame_state\030\005 \001(\0162\023.protobuf.GameStat" - "e\"J\n\007MoveRes\022\024\n\014actual_speed\030\001 \001(\003\022\024\n\014ac" - "tual_angle\030\002 \001(\001\022\023\n\013act_success\030\003 \001(\010\"\036\n" - "\007BoolRes\022\023\n\013act_success\030\001 \001(\010\"P\n\006MsgRes\022" - "\024\n\014have_message\030\001 \001(\010\022\026\n\016from_player_id\030" - "\002 \001(\003\022\030\n\020message_received\030\003 \001(\tb\006proto3"; + "\n\020facing_direction\030\004 \001(\001\022\014\n\004guid\030\005 \001(\003\022\"" + "\n\005place\030\006 \001(\0162\023.protobuf.PlaceType\022\014\n\004si" + "ze\030\007 \001(\005\022\021\n\tis_moving\030\010 \001(\010\"{\n\023MessageOf" + "PickedProp\022 \n\004type\030\001 \001(\0162\022.protobuf.Prop" + "Type\022\t\n\001x\030\002 \001(\005\022\t\n\001y\030\003 \001(\005\022\030\n\020facing_dir" + "ection\030\004 \001(\001\022\022\n\nmapping_id\030\005 \001(\003\"`\n\014Mess" + "ageOfMap\022\'\n\003row\030\002 \003(\0132\032.protobuf.Message" + "OfMap.Row\032\'\n\003Row\022 \n\003col\030\001 \003(\0162\023.protobuf" + ".PlaceType\"\200\002\n\017MessageToClient\0223\n\017studen" + "t_message\030\001 \003(\0132\032.protobuf.MessageOfStud" + "ent\0223\n\017tricker_message\030\002 \003(\0132\032.protobuf." + "MessageOfTricker\022-\n\014prop_message\030\003 \003(\0132\027" + ".protobuf.MessageOfProp\022+\n\013map_message\030\004" + " \001(\0132\026.protobuf.MessageOfMap\022\'\n\ngame_sta" + "te\030\005 \001(\0162\023.protobuf.GameState\"J\n\007MoveRes" + "\022\024\n\014actual_speed\030\001 \001(\003\022\024\n\014actual_angle\030\002" + " \001(\001\022\023\n\013act_success\030\003 \001(\010\"\036\n\007BoolRes\022\023\n\013" + "act_success\030\001 \001(\010\"P\n\006MsgRes\022\024\n\014have_mess" + "age\030\001 \001(\010\022\026\n\016from_player_id\030\002 \001(\003\022\030\n\020mes" + "sage_received\030\003 \001(\tb\006proto3"; static const ::_pbi::DescriptorTable* const descriptor_table_Message2Clients_2eproto_deps[1] = { &::descriptor_table_MessageType_2eproto, }; @@ -445,13 +528,13 @@ static ::_pbi::once_flag descriptor_table_Message2Clients_2eproto_once; const ::_pbi::DescriptorTable descriptor_table_Message2Clients_2eproto = { false, false, - 1719, + 2067, descriptor_table_protodef_Message2Clients_2eproto, "Message2Clients.proto", &descriptor_table_Message2Clients_2eproto_once, descriptor_table_Message2Clients_2eproto_deps, 1, - 10, + 12, schemas, file_default_instances, TableStruct_Message2Clients_2eproto::offsets, @@ -1548,59 +1631,957 @@ namespace protobuf ); } - // .protobuf.TrickerType tricker_type = 8; - if (this->_internal_tricker_type() != 0) + // .protobuf.TrickerType tricker_type = 8; + if (this->_internal_tricker_type() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteEnumToArray( + 8, this->_internal_tricker_type(), target + ); + } + + // int64 guid = 9; + if (this->_internal_guid() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteInt64ToArray(9, this->_internal_guid(), target); + } + + // bool movable = 10; + if (this->_internal_movable() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteBoolToArray(10, this->_internal_movable(), target); + } + + // int64 player_id = 11; + if (this->_internal_player_id() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteInt64ToArray(11, this->_internal_player_id(), target); + } + + // int32 view_range = 12; + if (this->_internal_view_range() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray(12, this->_internal_view_range(), target); + } + + // int32 radius = 13; + if (this->_internal_radius() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray(13, this->_internal_radius(), target); + } + + // repeated .protobuf.TrickerBuffType buff = 14; + { + int byte_size = _impl_._buff_cached_byte_size_.load(std::memory_order_relaxed); + if (byte_size > 0) + { + target = stream->WriteEnumPacked( + 14, _impl_.buff_, byte_size, target + ); + } + } + + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) + { + target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray( + _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream + ); + } + // @@protoc_insertion_point(serialize_to_array_end:protobuf.MessageOfTricker) + return target; + } + + size_t MessageOfTricker::ByteSizeLong() const + { + // @@protoc_insertion_point(message_byte_size_start:protobuf.MessageOfTricker) + size_t total_size = 0; + + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void)cached_has_bits; + + // repeated .protobuf.TrickerBuffType buff = 14; + { + size_t data_size = 0; + unsigned int count = static_cast(this->_internal_buff_size()); + for (unsigned int i = 0; i < count; i++) + { + data_size += ::_pbi::WireFormatLite::EnumSize( + this->_internal_buff(static_cast(i)) + ); + } + if (data_size > 0) + { + total_size += 1 + + ::_pbi::WireFormatLite::Int32Size(static_cast(data_size)); + } + int cached_size = ::_pbi::ToCachedSize(data_size); + _impl_._buff_cached_byte_size_.store(cached_size, std::memory_order_relaxed); + total_size += data_size; + } + + // int32 x = 1; + if (this->_internal_x() != 0) + { + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_x()); + } + + // int32 y = 2; + if (this->_internal_y() != 0) + { + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_y()); + } + + // int32 speed = 3; + if (this->_internal_speed() != 0) + { + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_speed()); + } + + // int32 damage = 4; + if (this->_internal_damage() != 0) + { + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_damage()); + } + + // double time_until_skill_available = 5; + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_time_until_skill_available = this->_internal_time_until_skill_available(); + uint64_t raw_time_until_skill_available; + memcpy(&raw_time_until_skill_available, &tmp_time_until_skill_available, sizeof(tmp_time_until_skill_available)); + if (raw_time_until_skill_available != 0) + { + total_size += 1 + 8; + } + + // .protobuf.PlaceType place = 6; + if (this->_internal_place() != 0) + { + total_size += 1 + + ::_pbi::WireFormatLite::EnumSize(this->_internal_place()); + } + + // .protobuf.PropType prop = 7; + if (this->_internal_prop() != 0) + { + total_size += 1 + + ::_pbi::WireFormatLite::EnumSize(this->_internal_prop()); + } + + // int64 guid = 9; + if (this->_internal_guid() != 0) + { + total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_guid()); + } + + // .protobuf.TrickerType tricker_type = 8; + if (this->_internal_tricker_type() != 0) + { + total_size += 1 + + ::_pbi::WireFormatLite::EnumSize(this->_internal_tricker_type()); + } + + // bool movable = 10; + if (this->_internal_movable() != 0) + { + total_size += 1 + 1; + } + + // int64 player_id = 11; + if (this->_internal_player_id() != 0) + { + total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_player_id()); + } + + // int32 view_range = 12; + if (this->_internal_view_range() != 0) + { + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_view_range()); + } + + // int32 radius = 13; + if (this->_internal_radius() != 0) + { + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_radius()); + } + + return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); + } + + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData MessageOfTricker::_class_data_ = { + ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck, + MessageOfTricker::MergeImpl}; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData* MessageOfTricker::GetClassData() const + { + return &_class_data_; + } + + void MessageOfTricker::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) + { + auto* const _this = static_cast(&to_msg); + auto& from = static_cast(from_msg); + // @@protoc_insertion_point(class_specific_merge_from_start:protobuf.MessageOfTricker) + GOOGLE_DCHECK_NE(&from, _this); + uint32_t cached_has_bits = 0; + (void)cached_has_bits; + + _this->_impl_.buff_.MergeFrom(from._impl_.buff_); + if (from._internal_x() != 0) + { + _this->_internal_set_x(from._internal_x()); + } + if (from._internal_y() != 0) + { + _this->_internal_set_y(from._internal_y()); + } + if (from._internal_speed() != 0) + { + _this->_internal_set_speed(from._internal_speed()); + } + if (from._internal_damage() != 0) + { + _this->_internal_set_damage(from._internal_damage()); + } + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_time_until_skill_available = from._internal_time_until_skill_available(); + uint64_t raw_time_until_skill_available; + memcpy(&raw_time_until_skill_available, &tmp_time_until_skill_available, sizeof(tmp_time_until_skill_available)); + if (raw_time_until_skill_available != 0) + { + _this->_internal_set_time_until_skill_available(from._internal_time_until_skill_available()); + } + if (from._internal_place() != 0) + { + _this->_internal_set_place(from._internal_place()); + } + if (from._internal_prop() != 0) + { + _this->_internal_set_prop(from._internal_prop()); + } + if (from._internal_guid() != 0) + { + _this->_internal_set_guid(from._internal_guid()); + } + if (from._internal_tricker_type() != 0) + { + _this->_internal_set_tricker_type(from._internal_tricker_type()); + } + if (from._internal_movable() != 0) + { + _this->_internal_set_movable(from._internal_movable()); + } + if (from._internal_player_id() != 0) + { + _this->_internal_set_player_id(from._internal_player_id()); + } + if (from._internal_view_range() != 0) + { + _this->_internal_set_view_range(from._internal_view_range()); + } + if (from._internal_radius() != 0) + { + _this->_internal_set_radius(from._internal_radius()); + } + _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); + } + + void MessageOfTricker::CopyFrom(const MessageOfTricker& from) + { + // @@protoc_insertion_point(class_specific_copy_from_start:protobuf.MessageOfTricker) + if (&from == this) + return; + Clear(); + MergeFrom(from); + } + + bool MessageOfTricker::IsInitialized() const + { + return true; + } + + void MessageOfTricker::InternalSwap(MessageOfTricker* other) + { + using std::swap; + _internal_metadata_.InternalSwap(&other->_internal_metadata_); + _impl_.buff_.InternalSwap(&other->_impl_.buff_); + ::PROTOBUF_NAMESPACE_ID::internal::memswap< + PROTOBUF_FIELD_OFFSET(MessageOfTricker, _impl_.radius_) + sizeof(MessageOfTricker::_impl_.radius_) - PROTOBUF_FIELD_OFFSET(MessageOfTricker, _impl_.x_)>( + reinterpret_cast(&_impl_.x_), + reinterpret_cast(&other->_impl_.x_) + ); + } + + ::PROTOBUF_NAMESPACE_ID::Metadata MessageOfTricker::GetMetadata() const + { + return ::_pbi::AssignDescriptors( + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[1] + ); + } + + // =================================================================== + + class MessageOfBullet::_Internal + { + public: + }; + + MessageOfBullet::MessageOfBullet(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned) : + ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) + { + SharedCtor(arena, is_message_owned); + // @@protoc_insertion_point(arena_constructor:protobuf.MessageOfBullet) + } + MessageOfBullet::MessageOfBullet(const MessageOfBullet& from) : + ::PROTOBUF_NAMESPACE_ID::Message() + { + MessageOfBullet* const _this = this; + (void)_this; + new (&_impl_) Impl_{ + decltype(_impl_.type_){}, decltype(_impl_.x_){}, decltype(_impl_.facing_direction_){}, decltype(_impl_.guid_){}, decltype(_impl_.y_){}, decltype(_impl_.place_){}, decltype(_impl_.parent_team_id_){}, decltype(_impl_.bomb_range_){}, /*decltype(_impl_._cached_size_)*/ {}}; + + _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); + ::memcpy(&_impl_.type_, &from._impl_.type_, static_cast(reinterpret_cast(&_impl_.bomb_range_) - reinterpret_cast(&_impl_.type_)) + sizeof(_impl_.bomb_range_)); + // @@protoc_insertion_point(copy_constructor:protobuf.MessageOfBullet) + } + + inline void MessageOfBullet::SharedCtor( + ::_pb::Arena* arena, bool is_message_owned + ) + { + (void)arena; + (void)is_message_owned; + new (&_impl_) Impl_{ + decltype(_impl_.type_){0}, decltype(_impl_.x_){0}, decltype(_impl_.facing_direction_){0}, decltype(_impl_.guid_){int64_t{0}}, decltype(_impl_.y_){0}, decltype(_impl_.place_){0}, decltype(_impl_.parent_team_id_){int64_t{0}}, decltype(_impl_.bomb_range_){0}, /*decltype(_impl_._cached_size_)*/ {}}; + } + + MessageOfBullet::~MessageOfBullet() + { + // @@protoc_insertion_point(destructor:protobuf.MessageOfBullet) + if (auto* arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) + { + (void)arena; + return; + } + SharedDtor(); + } + + inline void MessageOfBullet::SharedDtor() + { + GOOGLE_DCHECK(GetArenaForAllocation() == nullptr); + } + + void MessageOfBullet::SetCachedSize(int size) const + { + _impl_._cached_size_.Set(size); + } + + void MessageOfBullet::Clear() + { + // @@protoc_insertion_point(message_clear_start:protobuf.MessageOfBullet) + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void)cached_has_bits; + + ::memset(&_impl_.type_, 0, static_cast(reinterpret_cast(&_impl_.bomb_range_) - reinterpret_cast(&_impl_.type_)) + sizeof(_impl_.bomb_range_)); + _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); + } + + const char* MessageOfBullet::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) + { +#define CHK_(x) \ + if (PROTOBUF_PREDICT_FALSE(!(x))) \ + goto failure + while (!ctx->Done(&ptr)) + { + uint32_t tag; + ptr = ::_pbi::ReadTag(ptr, &tag); + switch (tag >> 3) + { + // .protobuf.BulletType type = 1; + case 1: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 8)) + { + uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr); + CHK_(ptr); + _internal_set_type(static_cast<::protobuf::BulletType>(val)); + } + else + goto handle_unusual; + continue; + // int32 x = 2; + case 2: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 16)) + { + _impl_.x_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr); + CHK_(ptr); + } + else + goto handle_unusual; + continue; + // int32 y = 3; + case 3: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 24)) + { + _impl_.y_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr); + CHK_(ptr); + } + else + goto handle_unusual; + continue; + // double facing_direction = 4; + case 4: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 33)) + { + _impl_.facing_direction_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad(ptr); + ptr += sizeof(double); + } + else + goto handle_unusual; + continue; + // int64 guid = 5; + case 5: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 40)) + { + _impl_.guid_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr); + CHK_(ptr); + } + else + goto handle_unusual; + continue; + // int64 parent_team_id = 6; + case 6: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 48)) + { + _impl_.parent_team_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr); + CHK_(ptr); + } + else + goto handle_unusual; + continue; + // .protobuf.PlaceType place = 7; + case 7: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 56)) + { + uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr); + CHK_(ptr); + _internal_set_place(static_cast<::protobuf::PlaceType>(val)); + } + else + goto handle_unusual; + continue; + // double bomb_range = 8; + case 8: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 65)) + { + _impl_.bomb_range_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad(ptr); + ptr += sizeof(double); + } + else + goto handle_unusual; + continue; + default: + goto handle_unusual; + } // switch + handle_unusual: + if ((tag == 0) || ((tag & 7) == 4)) + { + CHK_(ptr); + ctx->SetLastTag(tag); + goto message_done; + } + ptr = UnknownFieldParse( + tag, + _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), + ptr, + ctx + ); + CHK_(ptr != nullptr); + } // while + message_done: + return ptr; + failure: + ptr = nullptr; + goto message_done; +#undef CHK_ + } + + uint8_t* MessageOfBullet::_InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream + ) const + { + // @@protoc_insertion_point(serialize_to_array_start:protobuf.MessageOfBullet) + uint32_t cached_has_bits = 0; + (void)cached_has_bits; + + // .protobuf.BulletType type = 1; + if (this->_internal_type() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteEnumToArray( + 1, this->_internal_type(), target + ); + } + + // int32 x = 2; + if (this->_internal_x() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_x(), target); + } + + // int32 y = 3; + if (this->_internal_y() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray(3, this->_internal_y(), target); + } + + // double facing_direction = 4; + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_facing_direction = this->_internal_facing_direction(); + uint64_t raw_facing_direction; + memcpy(&raw_facing_direction, &tmp_facing_direction, sizeof(tmp_facing_direction)); + if (raw_facing_direction != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteDoubleToArray(4, this->_internal_facing_direction(), target); + } + + // int64 guid = 5; + if (this->_internal_guid() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteInt64ToArray(5, this->_internal_guid(), target); + } + + // int64 parent_team_id = 6; + if (this->_internal_parent_team_id() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteInt64ToArray(6, this->_internal_parent_team_id(), target); + } + + // .protobuf.PlaceType place = 7; + if (this->_internal_place() != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteEnumToArray( + 7, this->_internal_place(), target + ); + } + + // double bomb_range = 8; + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_bomb_range = this->_internal_bomb_range(); + uint64_t raw_bomb_range; + memcpy(&raw_bomb_range, &tmp_bomb_range, sizeof(tmp_bomb_range)); + if (raw_bomb_range != 0) + { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteDoubleToArray(8, this->_internal_bomb_range(), target); + } + + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) + { + target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray( + _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream + ); + } + // @@protoc_insertion_point(serialize_to_array_end:protobuf.MessageOfBullet) + return target; + } + + size_t MessageOfBullet::ByteSizeLong() const + { + // @@protoc_insertion_point(message_byte_size_start:protobuf.MessageOfBullet) + size_t total_size = 0; + + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void)cached_has_bits; + + // .protobuf.BulletType type = 1; + if (this->_internal_type() != 0) + { + total_size += 1 + + ::_pbi::WireFormatLite::EnumSize(this->_internal_type()); + } + + // int32 x = 2; + if (this->_internal_x() != 0) + { + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_x()); + } + + // double facing_direction = 4; + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_facing_direction = this->_internal_facing_direction(); + uint64_t raw_facing_direction; + memcpy(&raw_facing_direction, &tmp_facing_direction, sizeof(tmp_facing_direction)); + if (raw_facing_direction != 0) + { + total_size += 1 + 8; + } + + // int64 guid = 5; + if (this->_internal_guid() != 0) + { + total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_guid()); + } + + // int32 y = 3; + if (this->_internal_y() != 0) + { + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_y()); + } + + // .protobuf.PlaceType place = 7; + if (this->_internal_place() != 0) + { + total_size += 1 + + ::_pbi::WireFormatLite::EnumSize(this->_internal_place()); + } + + // int64 parent_team_id = 6; + if (this->_internal_parent_team_id() != 0) + { + total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_parent_team_id()); + } + + // double bomb_range = 8; + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_bomb_range = this->_internal_bomb_range(); + uint64_t raw_bomb_range; + memcpy(&raw_bomb_range, &tmp_bomb_range, sizeof(tmp_bomb_range)); + if (raw_bomb_range != 0) + { + total_size += 1 + 8; + } + + return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); + } + + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData MessageOfBullet::_class_data_ = { + ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck, + MessageOfBullet::MergeImpl}; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData* MessageOfBullet::GetClassData() const + { + return &_class_data_; + } + + void MessageOfBullet::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) + { + auto* const _this = static_cast(&to_msg); + auto& from = static_cast(from_msg); + // @@protoc_insertion_point(class_specific_merge_from_start:protobuf.MessageOfBullet) + GOOGLE_DCHECK_NE(&from, _this); + uint32_t cached_has_bits = 0; + (void)cached_has_bits; + + if (from._internal_type() != 0) + { + _this->_internal_set_type(from._internal_type()); + } + if (from._internal_x() != 0) + { + _this->_internal_set_x(from._internal_x()); + } + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_facing_direction = from._internal_facing_direction(); + uint64_t raw_facing_direction; + memcpy(&raw_facing_direction, &tmp_facing_direction, sizeof(tmp_facing_direction)); + if (raw_facing_direction != 0) + { + _this->_internal_set_facing_direction(from._internal_facing_direction()); + } + if (from._internal_guid() != 0) + { + _this->_internal_set_guid(from._internal_guid()); + } + if (from._internal_y() != 0) + { + _this->_internal_set_y(from._internal_y()); + } + if (from._internal_place() != 0) + { + _this->_internal_set_place(from._internal_place()); + } + if (from._internal_parent_team_id() != 0) + { + _this->_internal_set_parent_team_id(from._internal_parent_team_id()); + } + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_bomb_range = from._internal_bomb_range(); + uint64_t raw_bomb_range; + memcpy(&raw_bomb_range, &tmp_bomb_range, sizeof(tmp_bomb_range)); + if (raw_bomb_range != 0) + { + _this->_internal_set_bomb_range(from._internal_bomb_range()); + } + _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); + } + + void MessageOfBullet::CopyFrom(const MessageOfBullet& from) + { + // @@protoc_insertion_point(class_specific_copy_from_start:protobuf.MessageOfBullet) + if (&from == this) + return; + Clear(); + MergeFrom(from); + } + + bool MessageOfBullet::IsInitialized() const + { + return true; + } + + void MessageOfBullet::InternalSwap(MessageOfBullet* other) + { + using std::swap; + _internal_metadata_.InternalSwap(&other->_internal_metadata_); + ::PROTOBUF_NAMESPACE_ID::internal::memswap< + PROTOBUF_FIELD_OFFSET(MessageOfBullet, _impl_.bomb_range_) + sizeof(MessageOfBullet::_impl_.bomb_range_) - PROTOBUF_FIELD_OFFSET(MessageOfBullet, _impl_.type_)>( + reinterpret_cast(&_impl_.type_), + reinterpret_cast(&other->_impl_.type_) + ); + } + + ::PROTOBUF_NAMESPACE_ID::Metadata MessageOfBullet::GetMetadata() const + { + return ::_pbi::AssignDescriptors( + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[2] + ); + } + + // =================================================================== + + class MessageOfBombedBullet::_Internal + { + public: + }; + + MessageOfBombedBullet::MessageOfBombedBullet(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned) : + ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) + { + SharedCtor(arena, is_message_owned); + // @@protoc_insertion_point(arena_constructor:protobuf.MessageOfBombedBullet) + } + MessageOfBombedBullet::MessageOfBombedBullet(const MessageOfBombedBullet& from) : + ::PROTOBUF_NAMESPACE_ID::Message() + { + MessageOfBombedBullet* const _this = this; + (void)_this; + new (&_impl_) Impl_{ + decltype(_impl_.type_){}, decltype(_impl_.x_){}, decltype(_impl_.facing_direction_){}, decltype(_impl_.mapping_id_){}, decltype(_impl_.bomb_range_){}, decltype(_impl_.y_){}, /*decltype(_impl_._cached_size_)*/ {}}; + + _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); + ::memcpy(&_impl_.type_, &from._impl_.type_, static_cast(reinterpret_cast(&_impl_.y_) - reinterpret_cast(&_impl_.type_)) + sizeof(_impl_.y_)); + // @@protoc_insertion_point(copy_constructor:protobuf.MessageOfBombedBullet) + } + + inline void MessageOfBombedBullet::SharedCtor( + ::_pb::Arena* arena, bool is_message_owned + ) + { + (void)arena; + (void)is_message_owned; + new (&_impl_) Impl_{ + decltype(_impl_.type_){0}, decltype(_impl_.x_){0}, decltype(_impl_.facing_direction_){0}, decltype(_impl_.mapping_id_){int64_t{0}}, decltype(_impl_.bomb_range_){0}, decltype(_impl_.y_){0}, /*decltype(_impl_._cached_size_)*/ {}}; + } + + MessageOfBombedBullet::~MessageOfBombedBullet() + { + // @@protoc_insertion_point(destructor:protobuf.MessageOfBombedBullet) + if (auto* arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) + { + (void)arena; + return; + } + SharedDtor(); + } + + inline void MessageOfBombedBullet::SharedDtor() + { + GOOGLE_DCHECK(GetArenaForAllocation() == nullptr); + } + + void MessageOfBombedBullet::SetCachedSize(int size) const + { + _impl_._cached_size_.Set(size); + } + + void MessageOfBombedBullet::Clear() + { + // @@protoc_insertion_point(message_clear_start:protobuf.MessageOfBombedBullet) + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void)cached_has_bits; + + ::memset(&_impl_.type_, 0, static_cast(reinterpret_cast(&_impl_.y_) - reinterpret_cast(&_impl_.type_)) + sizeof(_impl_.y_)); + _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); + } + + const char* MessageOfBombedBullet::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) + { +#define CHK_(x) \ + if (PROTOBUF_PREDICT_FALSE(!(x))) \ + goto failure + while (!ctx->Done(&ptr)) + { + uint32_t tag; + ptr = ::_pbi::ReadTag(ptr, &tag); + switch (tag >> 3) + { + // .protobuf.BulletType type = 1; + case 1: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 8)) + { + uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr); + CHK_(ptr); + _internal_set_type(static_cast<::protobuf::BulletType>(val)); + } + else + goto handle_unusual; + continue; + // int32 x = 2; + case 2: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 16)) + { + _impl_.x_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr); + CHK_(ptr); + } + else + goto handle_unusual; + continue; + // int32 y = 3; + case 3: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 24)) + { + _impl_.y_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr); + CHK_(ptr); + } + else + goto handle_unusual; + continue; + // double facing_direction = 4; + case 4: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 33)) + { + _impl_.facing_direction_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad(ptr); + ptr += sizeof(double); + } + else + goto handle_unusual; + continue; + // int64 mapping_id = 5; + case 5: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 40)) + { + _impl_.mapping_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr); + CHK_(ptr); + } + else + goto handle_unusual; + continue; + // double bomb_range = 6; + case 6: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 49)) + { + _impl_.bomb_range_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad(ptr); + ptr += sizeof(double); + } + else + goto handle_unusual; + continue; + default: + goto handle_unusual; + } // switch + handle_unusual: + if ((tag == 0) || ((tag & 7) == 4)) + { + CHK_(ptr); + ctx->SetLastTag(tag); + goto message_done; + } + ptr = UnknownFieldParse( + tag, + _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), + ptr, + ctx + ); + CHK_(ptr != nullptr); + } // while + message_done: + return ptr; + failure: + ptr = nullptr; + goto message_done; +#undef CHK_ + } + + uint8_t* MessageOfBombedBullet::_InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream + ) const + { + // @@protoc_insertion_point(serialize_to_array_start:protobuf.MessageOfBombedBullet) + uint32_t cached_has_bits = 0; + (void)cached_has_bits; + + // .protobuf.BulletType type = 1; + if (this->_internal_type() != 0) { target = stream->EnsureSpace(target); target = ::_pbi::WireFormatLite::WriteEnumToArray( - 8, this->_internal_tricker_type(), target + 1, this->_internal_type(), target ); } - // int64 guid = 9; - if (this->_internal_guid() != 0) + // int32 x = 2; + if (this->_internal_x() != 0) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt64ToArray(9, this->_internal_guid(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_x(), target); } - // bool movable = 10; - if (this->_internal_movable() != 0) + // int32 y = 3; + if (this->_internal_y() != 0) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(10, this->_internal_movable(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray(3, this->_internal_y(), target); } - // int64 player_id = 11; - if (this->_internal_player_id() != 0) + // double facing_direction = 4; + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_facing_direction = this->_internal_facing_direction(); + uint64_t raw_facing_direction; + memcpy(&raw_facing_direction, &tmp_facing_direction, sizeof(tmp_facing_direction)); + if (raw_facing_direction != 0) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt64ToArray(11, this->_internal_player_id(), target); + target = ::_pbi::WireFormatLite::WriteDoubleToArray(4, this->_internal_facing_direction(), target); } - // int32 view_range = 12; - if (this->_internal_view_range() != 0) + // int64 mapping_id = 5; + if (this->_internal_mapping_id() != 0) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(12, this->_internal_view_range(), target); + target = ::_pbi::WireFormatLite::WriteInt64ToArray(5, this->_internal_mapping_id(), target); } - // int32 radius = 13; - if (this->_internal_radius() != 0) + // double bomb_range = 6; + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_bomb_range = this->_internal_bomb_range(); + uint64_t raw_bomb_range; + memcpy(&raw_bomb_range, &tmp_bomb_range, sizeof(tmp_bomb_range)); + if (raw_bomb_range != 0) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(13, this->_internal_radius(), target); - } - - // repeated .protobuf.TrickerBuffType buff = 14; - { - int byte_size = _impl_._buff_cached_byte_size_.load(std::memory_order_relaxed); - if (byte_size > 0) - { - target = stream->WriteEnumPacked( - 14, _impl_.buff_, byte_size, target - ); - } + target = ::_pbi::WireFormatLite::WriteDoubleToArray(6, this->_internal_bomb_range(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) @@ -1609,234 +2590,148 @@ namespace protobuf _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream ); } - // @@protoc_insertion_point(serialize_to_array_end:protobuf.MessageOfTricker) + // @@protoc_insertion_point(serialize_to_array_end:protobuf.MessageOfBombedBullet) return target; } - size_t MessageOfTricker::ByteSizeLong() const + size_t MessageOfBombedBullet::ByteSizeLong() const { - // @@protoc_insertion_point(message_byte_size_start:protobuf.MessageOfTricker) + // @@protoc_insertion_point(message_byte_size_start:protobuf.MessageOfBombedBullet) size_t total_size = 0; uint32_t cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void)cached_has_bits; - // repeated .protobuf.TrickerBuffType buff = 14; + // .protobuf.BulletType type = 1; + if (this->_internal_type() != 0) { - size_t data_size = 0; - unsigned int count = static_cast(this->_internal_buff_size()); - for (unsigned int i = 0; i < count; i++) - { - data_size += ::_pbi::WireFormatLite::EnumSize( - this->_internal_buff(static_cast(i)) - ); - } - if (data_size > 0) - { - total_size += 1 + - ::_pbi::WireFormatLite::Int32Size(static_cast(data_size)); - } - int cached_size = ::_pbi::ToCachedSize(data_size); - _impl_._buff_cached_byte_size_.store(cached_size, std::memory_order_relaxed); - total_size += data_size; + total_size += 1 + + ::_pbi::WireFormatLite::EnumSize(this->_internal_type()); } - // int32 x = 1; + // int32 x = 2; if (this->_internal_x() != 0) { total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_x()); } - // int32 y = 2; - if (this->_internal_y() != 0) - { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_y()); - } - - // int32 speed = 3; - if (this->_internal_speed() != 0) - { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_speed()); - } - - // int32 damage = 4; - if (this->_internal_damage() != 0) - { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_damage()); - } - - // double time_until_skill_available = 5; + // double facing_direction = 4; static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); - double tmp_time_until_skill_available = this->_internal_time_until_skill_available(); - uint64_t raw_time_until_skill_available; - memcpy(&raw_time_until_skill_available, &tmp_time_until_skill_available, sizeof(tmp_time_until_skill_available)); - if (raw_time_until_skill_available != 0) + double tmp_facing_direction = this->_internal_facing_direction(); + uint64_t raw_facing_direction; + memcpy(&raw_facing_direction, &tmp_facing_direction, sizeof(tmp_facing_direction)); + if (raw_facing_direction != 0) { total_size += 1 + 8; } - // .protobuf.PlaceType place = 6; - if (this->_internal_place() != 0) - { - total_size += 1 + - ::_pbi::WireFormatLite::EnumSize(this->_internal_place()); - } - - // .protobuf.PropType prop = 7; - if (this->_internal_prop() != 0) - { - total_size += 1 + - ::_pbi::WireFormatLite::EnumSize(this->_internal_prop()); - } - - // int64 guid = 9; - if (this->_internal_guid() != 0) - { - total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_guid()); - } - - // .protobuf.TrickerType tricker_type = 8; - if (this->_internal_tricker_type() != 0) - { - total_size += 1 + - ::_pbi::WireFormatLite::EnumSize(this->_internal_tricker_type()); - } - - // bool movable = 10; - if (this->_internal_movable() != 0) - { - total_size += 1 + 1; - } - - // int64 player_id = 11; - if (this->_internal_player_id() != 0) + // int64 mapping_id = 5; + if (this->_internal_mapping_id() != 0) { - total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_player_id()); + total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_mapping_id()); } - // int32 view_range = 12; - if (this->_internal_view_range() != 0) + // double bomb_range = 6; + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_bomb_range = this->_internal_bomb_range(); + uint64_t raw_bomb_range; + memcpy(&raw_bomb_range, &tmp_bomb_range, sizeof(tmp_bomb_range)); + if (raw_bomb_range != 0) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_view_range()); + total_size += 1 + 8; } - // int32 radius = 13; - if (this->_internal_radius() != 0) + // int32 y = 3; + if (this->_internal_y() != 0) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_radius()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_y()); } return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); } - const ::PROTOBUF_NAMESPACE_ID::Message::ClassData MessageOfTricker::_class_data_ = { + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData MessageOfBombedBullet::_class_data_ = { ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck, - MessageOfTricker::MergeImpl}; - const ::PROTOBUF_NAMESPACE_ID::Message::ClassData* MessageOfTricker::GetClassData() const + MessageOfBombedBullet::MergeImpl}; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData* MessageOfBombedBullet::GetClassData() const { return &_class_data_; } - void MessageOfTricker::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) + void MessageOfBombedBullet::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) { - auto* const _this = static_cast(&to_msg); - auto& from = static_cast(from_msg); - // @@protoc_insertion_point(class_specific_merge_from_start:protobuf.MessageOfTricker) + auto* const _this = static_cast(&to_msg); + auto& from = static_cast(from_msg); + // @@protoc_insertion_point(class_specific_merge_from_start:protobuf.MessageOfBombedBullet) GOOGLE_DCHECK_NE(&from, _this); uint32_t cached_has_bits = 0; (void)cached_has_bits; - _this->_impl_.buff_.MergeFrom(from._impl_.buff_); - if (from._internal_x() != 0) - { - _this->_internal_set_x(from._internal_x()); - } - if (from._internal_y() != 0) - { - _this->_internal_set_y(from._internal_y()); - } - if (from._internal_speed() != 0) + if (from._internal_type() != 0) { - _this->_internal_set_speed(from._internal_speed()); + _this->_internal_set_type(from._internal_type()); } - if (from._internal_damage() != 0) + if (from._internal_x() != 0) { - _this->_internal_set_damage(from._internal_damage()); + _this->_internal_set_x(from._internal_x()); } static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); - double tmp_time_until_skill_available = from._internal_time_until_skill_available(); - uint64_t raw_time_until_skill_available; - memcpy(&raw_time_until_skill_available, &tmp_time_until_skill_available, sizeof(tmp_time_until_skill_available)); - if (raw_time_until_skill_available != 0) - { - _this->_internal_set_time_until_skill_available(from._internal_time_until_skill_available()); - } - if (from._internal_place() != 0) - { - _this->_internal_set_place(from._internal_place()); - } - if (from._internal_prop() != 0) - { - _this->_internal_set_prop(from._internal_prop()); - } - if (from._internal_guid() != 0) - { - _this->_internal_set_guid(from._internal_guid()); - } - if (from._internal_tricker_type() != 0) - { - _this->_internal_set_tricker_type(from._internal_tricker_type()); - } - if (from._internal_movable() != 0) + double tmp_facing_direction = from._internal_facing_direction(); + uint64_t raw_facing_direction; + memcpy(&raw_facing_direction, &tmp_facing_direction, sizeof(tmp_facing_direction)); + if (raw_facing_direction != 0) { - _this->_internal_set_movable(from._internal_movable()); + _this->_internal_set_facing_direction(from._internal_facing_direction()); } - if (from._internal_player_id() != 0) + if (from._internal_mapping_id() != 0) { - _this->_internal_set_player_id(from._internal_player_id()); + _this->_internal_set_mapping_id(from._internal_mapping_id()); } - if (from._internal_view_range() != 0) + static_assert(sizeof(uint64_t) == sizeof(double), "Code assumes uint64_t and double are the same size."); + double tmp_bomb_range = from._internal_bomb_range(); + uint64_t raw_bomb_range; + memcpy(&raw_bomb_range, &tmp_bomb_range, sizeof(tmp_bomb_range)); + if (raw_bomb_range != 0) { - _this->_internal_set_view_range(from._internal_view_range()); + _this->_internal_set_bomb_range(from._internal_bomb_range()); } - if (from._internal_radius() != 0) + if (from._internal_y() != 0) { - _this->_internal_set_radius(from._internal_radius()); + _this->_internal_set_y(from._internal_y()); } _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); } - void MessageOfTricker::CopyFrom(const MessageOfTricker& from) + void MessageOfBombedBullet::CopyFrom(const MessageOfBombedBullet& from) { - // @@protoc_insertion_point(class_specific_copy_from_start:protobuf.MessageOfTricker) + // @@protoc_insertion_point(class_specific_copy_from_start:protobuf.MessageOfBombedBullet) if (&from == this) return; Clear(); MergeFrom(from); } - bool MessageOfTricker::IsInitialized() const + bool MessageOfBombedBullet::IsInitialized() const { return true; } - void MessageOfTricker::InternalSwap(MessageOfTricker* other) + void MessageOfBombedBullet::InternalSwap(MessageOfBombedBullet* other) { using std::swap; _internal_metadata_.InternalSwap(&other->_internal_metadata_); - _impl_.buff_.InternalSwap(&other->_impl_.buff_); ::PROTOBUF_NAMESPACE_ID::internal::memswap< - PROTOBUF_FIELD_OFFSET(MessageOfTricker, _impl_.radius_) + sizeof(MessageOfTricker::_impl_.radius_) - PROTOBUF_FIELD_OFFSET(MessageOfTricker, _impl_.x_)>( - reinterpret_cast(&_impl_.x_), - reinterpret_cast(&other->_impl_.x_) + PROTOBUF_FIELD_OFFSET(MessageOfBombedBullet, _impl_.y_) + sizeof(MessageOfBombedBullet::_impl_.y_) - PROTOBUF_FIELD_OFFSET(MessageOfBombedBullet, _impl_.type_)>( + reinterpret_cast(&_impl_.type_), + reinterpret_cast(&other->_impl_.type_) ); } - ::PROTOBUF_NAMESPACE_ID::Metadata MessageOfTricker::GetMetadata() const + ::PROTOBUF_NAMESPACE_ID::Metadata MessageOfBombedBullet::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[1] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[3] ); } @@ -2259,7 +3154,7 @@ namespace protobuf ::PROTOBUF_NAMESPACE_ID::Metadata MessageOfProp::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[2] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[4] ); } @@ -2597,7 +3492,7 @@ namespace protobuf ::PROTOBUF_NAMESPACE_ID::Metadata MessageOfPickedProp::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[3] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[5] ); } @@ -2828,7 +3723,7 @@ namespace protobuf ::PROTOBUF_NAMESPACE_ID::Metadata MessageOfMap_Row::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[4] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[6] ); } @@ -3048,7 +3943,7 @@ namespace protobuf ::PROTOBUF_NAMESPACE_ID::Metadata MessageOfMap::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[5] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[7] ); } @@ -3435,7 +4330,7 @@ namespace protobuf ::PROTOBUF_NAMESPACE_ID::Metadata MessageToClient::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[6] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[8] ); } @@ -3715,7 +4610,7 @@ namespace protobuf ::PROTOBUF_NAMESPACE_ID::Metadata MoveRes::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[7] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[9] ); } @@ -3925,7 +4820,7 @@ namespace protobuf ::PROTOBUF_NAMESPACE_ID::Metadata BoolRes::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[8] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[10] ); } @@ -4221,7 +5116,7 @@ namespace protobuf ::PROTOBUF_NAMESPACE_ID::Metadata MsgRes::GetMetadata() const { return ::_pbi::AssignDescriptors( - &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[9] + &descriptor_table_Message2Clients_2eproto_getter, &descriptor_table_Message2Clients_2eproto_once, file_level_metadata_Message2Clients_2eproto[11] ); } @@ -4241,6 +5136,18 @@ PROTOBUF_NOINLINE ::protobuf::MessageOfTricker* return Arena::CreateMessageInternal<::protobuf::MessageOfTricker>(arena); } template<> +PROTOBUF_NOINLINE ::protobuf::MessageOfBullet* + Arena::CreateMaybeMessage<::protobuf::MessageOfBullet>(Arena* arena) +{ + return Arena::CreateMessageInternal<::protobuf::MessageOfBullet>(arena); +} +template<> +PROTOBUF_NOINLINE ::protobuf::MessageOfBombedBullet* + Arena::CreateMaybeMessage<::protobuf::MessageOfBombedBullet>(Arena* arena) +{ + return Arena::CreateMessageInternal<::protobuf::MessageOfBombedBullet>(arena); +} +template<> PROTOBUF_NOINLINE ::protobuf::MessageOfProp* Arena::CreateMaybeMessage<::protobuf::MessageOfProp>(Arena* arena) { diff --git a/CAPI/proto/Message2Clients.pb.h b/CAPI/proto/Message2Clients.pb.h index ed8a4c6..194cf16 100644 --- a/CAPI/proto/Message2Clients.pb.h +++ b/CAPI/proto/Message2Clients.pb.h @@ -52,6 +52,12 @@ namespace protobuf class BoolRes; struct BoolResDefaultTypeInternal; extern BoolResDefaultTypeInternal _BoolRes_default_instance_; + class MessageOfBombedBullet; + struct MessageOfBombedBulletDefaultTypeInternal; + extern MessageOfBombedBulletDefaultTypeInternal _MessageOfBombedBullet_default_instance_; + class MessageOfBullet; + struct MessageOfBulletDefaultTypeInternal; + extern MessageOfBulletDefaultTypeInternal _MessageOfBullet_default_instance_; class MessageOfMap; struct MessageOfMapDefaultTypeInternal; extern MessageOfMapDefaultTypeInternal _MessageOfMap_default_instance_; @@ -84,6 +90,10 @@ PROTOBUF_NAMESPACE_OPEN template<> ::protobuf::BoolRes* Arena::CreateMaybeMessage<::protobuf::BoolRes>(Arena*); template<> +::protobuf::MessageOfBombedBullet* Arena::CreateMaybeMessage<::protobuf::MessageOfBombedBullet>(Arena*); +template<> +::protobuf::MessageOfBullet* Arena::CreateMaybeMessage<::protobuf::MessageOfBullet>(Arena*); +template<> ::protobuf::MessageOfMap* Arena::CreateMaybeMessage<::protobuf::MessageOfMap>(Arena*); template<> ::protobuf::MessageOfMap_Row* Arena::CreateMaybeMessage<::protobuf::MessageOfMap_Row>(Arena*); @@ -850,21 +860,549 @@ namespace protobuf typedef void DestructorSkippable_; struct Impl_ { - ::PROTOBUF_NAMESPACE_ID::RepeatedField buff_; - mutable std::atomic _buff_cached_byte_size_; + ::PROTOBUF_NAMESPACE_ID::RepeatedField buff_; + mutable std::atomic _buff_cached_byte_size_; + int32_t x_; + int32_t y_; + int32_t speed_; + int32_t damage_; + double time_until_skill_available_; + int place_; + int prop_; + int64_t guid_; + int tricker_type_; + bool movable_; + int64_t player_id_; + int32_t view_range_; + int32_t radius_; + mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; + }; + union + { + Impl_ _impl_; + }; + friend struct ::TableStruct_Message2Clients_2eproto; + }; + // ------------------------------------------------------------------- + + class MessageOfBullet final : + public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:protobuf.MessageOfBullet) */ + { + public: + inline MessageOfBullet() : + MessageOfBullet(nullptr) + { + } + ~MessageOfBullet() override; + explicit PROTOBUF_CONSTEXPR MessageOfBullet(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); + + MessageOfBullet(const MessageOfBullet& from); + MessageOfBullet(MessageOfBullet&& from) noexcept + : + MessageOfBullet() + { + *this = ::std::move(from); + } + + inline MessageOfBullet& operator=(const MessageOfBullet& from) + { + CopyFrom(from); + return *this; + } + inline MessageOfBullet& operator=(MessageOfBullet&& from) noexcept + { + if (this == &from) + return *this; + if (GetOwningArena() == from.GetOwningArena() +#ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetOwningArena() != nullptr +#endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) + { + InternalSwap(&from); + } + else + { + CopyFrom(from); + } + return *this; + } + + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() + { + return GetDescriptor(); + } + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() + { + return default_instance().GetMetadata().descriptor; + } + static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() + { + return default_instance().GetMetadata().reflection; + } + static const MessageOfBullet& default_instance() + { + return *internal_default_instance(); + } + static inline const MessageOfBullet* internal_default_instance() + { + return reinterpret_cast( + &_MessageOfBullet_default_instance_ + ); + } + static constexpr int kIndexInFileMessages = + 2; + + friend void swap(MessageOfBullet& a, MessageOfBullet& b) + { + a.Swap(&b); + } + inline void Swap(MessageOfBullet* other) + { + if (other == this) + return; +#ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() != nullptr && + GetOwningArena() == other->GetOwningArena()) + { +#else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() == other->GetOwningArena()) + { +#endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } + else + { + ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(MessageOfBullet* other) + { + if (other == this) + return; + GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + MessageOfBullet* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final + { + return CreateMaybeMessage(arena); + } + using ::PROTOBUF_NAMESPACE_ID::Message::CopyFrom; + void CopyFrom(const MessageOfBullet& from); + using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; + void MergeFrom(const MessageOfBullet& from) + { + MessageOfBullet::MergeImpl(*this, from); + } + + private: + static void MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg); + + public: + PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; + bool IsInitialized() const final; + + size_t ByteSizeLong() const final; + const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; + uint8_t* _InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream + ) const final; + int GetCachedSize() const final + { + return _impl_._cached_size_.Get(); + } + + private: + void SharedCtor(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned); + void SharedDtor(); + void SetCachedSize(int size) const final; + void InternalSwap(MessageOfBullet* other); + + private: + friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; + static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() + { + return "protobuf.MessageOfBullet"; + } + + protected: + explicit MessageOfBullet(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned = false); + + public: + static const ClassData _class_data_; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData* GetClassData() const final; + + ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + enum : int + { + kTypeFieldNumber = 1, + kXFieldNumber = 2, + kFacingDirectionFieldNumber = 4, + kGuidFieldNumber = 5, + kYFieldNumber = 3, + kPlaceFieldNumber = 7, + kParentTeamIdFieldNumber = 6, + kBombRangeFieldNumber = 8, + }; + // .protobuf.BulletType type = 1; + void clear_type(); + ::protobuf::BulletType type() const; + void set_type(::protobuf::BulletType value); + + private: + ::protobuf::BulletType _internal_type() const; + void _internal_set_type(::protobuf::BulletType value); + + public: + // int32 x = 2; + void clear_x(); + int32_t x() const; + void set_x(int32_t value); + + private: + int32_t _internal_x() const; + void _internal_set_x(int32_t value); + + public: + // double facing_direction = 4; + void clear_facing_direction(); + double facing_direction() const; + void set_facing_direction(double value); + + private: + double _internal_facing_direction() const; + void _internal_set_facing_direction(double value); + + public: + // int64 guid = 5; + void clear_guid(); + int64_t guid() const; + void set_guid(int64_t value); + + private: + int64_t _internal_guid() const; + void _internal_set_guid(int64_t value); + + public: + // int32 y = 3; + void clear_y(); + int32_t y() const; + void set_y(int32_t value); + + private: + int32_t _internal_y() const; + void _internal_set_y(int32_t value); + + public: + // .protobuf.PlaceType place = 7; + void clear_place(); + ::protobuf::PlaceType place() const; + void set_place(::protobuf::PlaceType value); + + private: + ::protobuf::PlaceType _internal_place() const; + void _internal_set_place(::protobuf::PlaceType value); + + public: + // int64 parent_team_id = 6; + void clear_parent_team_id(); + int64_t parent_team_id() const; + void set_parent_team_id(int64_t value); + + private: + int64_t _internal_parent_team_id() const; + void _internal_set_parent_team_id(int64_t value); + + public: + // double bomb_range = 8; + void clear_bomb_range(); + double bomb_range() const; + void set_bomb_range(double value); + + private: + double _internal_bomb_range() const; + void _internal_set_bomb_range(double value); + + public: + // @@protoc_insertion_point(class_scope:protobuf.MessageOfBullet) + + private: + class _Internal; + + template + friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; + typedef void InternalArenaConstructable_; + typedef void DestructorSkippable_; + struct Impl_ + { + int type_; + int32_t x_; + double facing_direction_; + int64_t guid_; + int32_t y_; + int place_; + int64_t parent_team_id_; + double bomb_range_; + mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; + }; + union + { + Impl_ _impl_; + }; + friend struct ::TableStruct_Message2Clients_2eproto; + }; + // ------------------------------------------------------------------- + + class MessageOfBombedBullet final : + public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:protobuf.MessageOfBombedBullet) */ + { + public: + inline MessageOfBombedBullet() : + MessageOfBombedBullet(nullptr) + { + } + ~MessageOfBombedBullet() override; + explicit PROTOBUF_CONSTEXPR MessageOfBombedBullet(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); + + MessageOfBombedBullet(const MessageOfBombedBullet& from); + MessageOfBombedBullet(MessageOfBombedBullet&& from) noexcept + : + MessageOfBombedBullet() + { + *this = ::std::move(from); + } + + inline MessageOfBombedBullet& operator=(const MessageOfBombedBullet& from) + { + CopyFrom(from); + return *this; + } + inline MessageOfBombedBullet& operator=(MessageOfBombedBullet&& from) noexcept + { + if (this == &from) + return *this; + if (GetOwningArena() == from.GetOwningArena() +#ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetOwningArena() != nullptr +#endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) + { + InternalSwap(&from); + } + else + { + CopyFrom(from); + } + return *this; + } + + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() + { + return GetDescriptor(); + } + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() + { + return default_instance().GetMetadata().descriptor; + } + static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() + { + return default_instance().GetMetadata().reflection; + } + static const MessageOfBombedBullet& default_instance() + { + return *internal_default_instance(); + } + static inline const MessageOfBombedBullet* internal_default_instance() + { + return reinterpret_cast( + &_MessageOfBombedBullet_default_instance_ + ); + } + static constexpr int kIndexInFileMessages = + 3; + + friend void swap(MessageOfBombedBullet& a, MessageOfBombedBullet& b) + { + a.Swap(&b); + } + inline void Swap(MessageOfBombedBullet* other) + { + if (other == this) + return; +#ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() != nullptr && + GetOwningArena() == other->GetOwningArena()) + { +#else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() == other->GetOwningArena()) + { +#endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } + else + { + ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(MessageOfBombedBullet* other) + { + if (other == this) + return; + GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + MessageOfBombedBullet* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final + { + return CreateMaybeMessage(arena); + } + using ::PROTOBUF_NAMESPACE_ID::Message::CopyFrom; + void CopyFrom(const MessageOfBombedBullet& from); + using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; + void MergeFrom(const MessageOfBombedBullet& from) + { + MessageOfBombedBullet::MergeImpl(*this, from); + } + + private: + static void MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg); + + public: + PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; + bool IsInitialized() const final; + + size_t ByteSizeLong() const final; + const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; + uint8_t* _InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream + ) const final; + int GetCachedSize() const final + { + return _impl_._cached_size_.Get(); + } + + private: + void SharedCtor(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned); + void SharedDtor(); + void SetCachedSize(int size) const final; + void InternalSwap(MessageOfBombedBullet* other); + + private: + friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; + static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() + { + return "protobuf.MessageOfBombedBullet"; + } + + protected: + explicit MessageOfBombedBullet(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned = false); + + public: + static const ClassData _class_data_; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData* GetClassData() const final; + + ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + enum : int + { + kTypeFieldNumber = 1, + kXFieldNumber = 2, + kFacingDirectionFieldNumber = 4, + kMappingIdFieldNumber = 5, + kBombRangeFieldNumber = 6, + kYFieldNumber = 3, + }; + // .protobuf.BulletType type = 1; + void clear_type(); + ::protobuf::BulletType type() const; + void set_type(::protobuf::BulletType value); + + private: + ::protobuf::BulletType _internal_type() const; + void _internal_set_type(::protobuf::BulletType value); + + public: + // int32 x = 2; + void clear_x(); + int32_t x() const; + void set_x(int32_t value); + + private: + int32_t _internal_x() const; + void _internal_set_x(int32_t value); + + public: + // double facing_direction = 4; + void clear_facing_direction(); + double facing_direction() const; + void set_facing_direction(double value); + + private: + double _internal_facing_direction() const; + void _internal_set_facing_direction(double value); + + public: + // int64 mapping_id = 5; + void clear_mapping_id(); + int64_t mapping_id() const; + void set_mapping_id(int64_t value); + + private: + int64_t _internal_mapping_id() const; + void _internal_set_mapping_id(int64_t value); + + public: + // double bomb_range = 6; + void clear_bomb_range(); + double bomb_range() const; + void set_bomb_range(double value); + + private: + double _internal_bomb_range() const; + void _internal_set_bomb_range(double value); + + public: + // int32 y = 3; + void clear_y(); + int32_t y() const; + void set_y(int32_t value); + + private: + int32_t _internal_y() const; + void _internal_set_y(int32_t value); + + public: + // @@protoc_insertion_point(class_scope:protobuf.MessageOfBombedBullet) + + private: + class _Internal; + + template + friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; + typedef void InternalArenaConstructable_; + typedef void DestructorSkippable_; + struct Impl_ + { + int type_; int32_t x_; + double facing_direction_; + int64_t mapping_id_; + double bomb_range_; int32_t y_; - int32_t speed_; - int32_t damage_; - double time_until_skill_available_; - int place_; - int prop_; - int64_t guid_; - int tricker_type_; - bool movable_; - int64_t player_id_; - int32_t view_range_; - int32_t radius_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; }; union @@ -941,7 +1479,7 @@ namespace protobuf ); } static constexpr int kIndexInFileMessages = - 2; + 4; friend void swap(MessageOfProp& a, MessageOfProp& b) { @@ -1217,7 +1755,7 @@ namespace protobuf ); } static constexpr int kIndexInFileMessages = - 3; + 5; friend void swap(MessageOfPickedProp& a, MessageOfPickedProp& b) { @@ -1457,7 +1995,7 @@ namespace protobuf ); } static constexpr int kIndexInFileMessages = - 4; + 6; friend void swap(MessageOfMap_Row& a, MessageOfMap_Row& b) { @@ -1661,7 +2199,7 @@ namespace protobuf ); } static constexpr int kIndexInFileMessages = - 5; + 7; friend void swap(MessageOfMap& a, MessageOfMap& b) { @@ -1867,7 +2405,7 @@ namespace protobuf ); } static constexpr int kIndexInFileMessages = - 6; + 8; friend void swap(MessageToClient& a, MessageToClient& b) { @@ -2156,7 +2694,7 @@ namespace protobuf ); } static constexpr int kIndexInFileMessages = - 7; + 9; friend void swap(MoveRes& a, MoveRes& b) { @@ -2372,7 +2910,7 @@ namespace protobuf ); } static constexpr int kIndexInFileMessages = - 8; + 10; friend void swap(BoolRes& a, BoolRes& b) { @@ -2564,7 +3102,7 @@ namespace protobuf ); } static constexpr int kIndexInFileMessages = - 9; + 11; friend void swap(MsgRes& a, MsgRes& b) { @@ -3561,6 +4099,350 @@ namespace protobuf // ------------------------------------------------------------------- + // MessageOfBullet + + // .protobuf.BulletType type = 1; + inline void MessageOfBullet::clear_type() + { + _impl_.type_ = 0; + } + inline ::protobuf::BulletType MessageOfBullet::_internal_type() const + { + return static_cast<::protobuf::BulletType>(_impl_.type_); + } + inline ::protobuf::BulletType MessageOfBullet::type() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBullet.type) + return _internal_type(); + } + inline void MessageOfBullet::_internal_set_type(::protobuf::BulletType value) + { + _impl_.type_ = value; + } + inline void MessageOfBullet::set_type(::protobuf::BulletType value) + { + _internal_set_type(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBullet.type) + } + + // int32 x = 2; + inline void MessageOfBullet::clear_x() + { + _impl_.x_ = 0; + } + inline int32_t MessageOfBullet::_internal_x() const + { + return _impl_.x_; + } + inline int32_t MessageOfBullet::x() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBullet.x) + return _internal_x(); + } + inline void MessageOfBullet::_internal_set_x(int32_t value) + { + _impl_.x_ = value; + } + inline void MessageOfBullet::set_x(int32_t value) + { + _internal_set_x(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBullet.x) + } + + // int32 y = 3; + inline void MessageOfBullet::clear_y() + { + _impl_.y_ = 0; + } + inline int32_t MessageOfBullet::_internal_y() const + { + return _impl_.y_; + } + inline int32_t MessageOfBullet::y() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBullet.y) + return _internal_y(); + } + inline void MessageOfBullet::_internal_set_y(int32_t value) + { + _impl_.y_ = value; + } + inline void MessageOfBullet::set_y(int32_t value) + { + _internal_set_y(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBullet.y) + } + + // double facing_direction = 4; + inline void MessageOfBullet::clear_facing_direction() + { + _impl_.facing_direction_ = 0; + } + inline double MessageOfBullet::_internal_facing_direction() const + { + return _impl_.facing_direction_; + } + inline double MessageOfBullet::facing_direction() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBullet.facing_direction) + return _internal_facing_direction(); + } + inline void MessageOfBullet::_internal_set_facing_direction(double value) + { + _impl_.facing_direction_ = value; + } + inline void MessageOfBullet::set_facing_direction(double value) + { + _internal_set_facing_direction(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBullet.facing_direction) + } + + // int64 guid = 5; + inline void MessageOfBullet::clear_guid() + { + _impl_.guid_ = int64_t{0}; + } + inline int64_t MessageOfBullet::_internal_guid() const + { + return _impl_.guid_; + } + inline int64_t MessageOfBullet::guid() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBullet.guid) + return _internal_guid(); + } + inline void MessageOfBullet::_internal_set_guid(int64_t value) + { + _impl_.guid_ = value; + } + inline void MessageOfBullet::set_guid(int64_t value) + { + _internal_set_guid(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBullet.guid) + } + + // int64 parent_team_id = 6; + inline void MessageOfBullet::clear_parent_team_id() + { + _impl_.parent_team_id_ = int64_t{0}; + } + inline int64_t MessageOfBullet::_internal_parent_team_id() const + { + return _impl_.parent_team_id_; + } + inline int64_t MessageOfBullet::parent_team_id() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBullet.parent_team_id) + return _internal_parent_team_id(); + } + inline void MessageOfBullet::_internal_set_parent_team_id(int64_t value) + { + _impl_.parent_team_id_ = value; + } + inline void MessageOfBullet::set_parent_team_id(int64_t value) + { + _internal_set_parent_team_id(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBullet.parent_team_id) + } + + // .protobuf.PlaceType place = 7; + inline void MessageOfBullet::clear_place() + { + _impl_.place_ = 0; + } + inline ::protobuf::PlaceType MessageOfBullet::_internal_place() const + { + return static_cast<::protobuf::PlaceType>(_impl_.place_); + } + inline ::protobuf::PlaceType MessageOfBullet::place() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBullet.place) + return _internal_place(); + } + inline void MessageOfBullet::_internal_set_place(::protobuf::PlaceType value) + { + _impl_.place_ = value; + } + inline void MessageOfBullet::set_place(::protobuf::PlaceType value) + { + _internal_set_place(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBullet.place) + } + + // double bomb_range = 8; + inline void MessageOfBullet::clear_bomb_range() + { + _impl_.bomb_range_ = 0; + } + inline double MessageOfBullet::_internal_bomb_range() const + { + return _impl_.bomb_range_; + } + inline double MessageOfBullet::bomb_range() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBullet.bomb_range) + return _internal_bomb_range(); + } + inline void MessageOfBullet::_internal_set_bomb_range(double value) + { + _impl_.bomb_range_ = value; + } + inline void MessageOfBullet::set_bomb_range(double value) + { + _internal_set_bomb_range(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBullet.bomb_range) + } + + // ------------------------------------------------------------------- + + // MessageOfBombedBullet + + // .protobuf.BulletType type = 1; + inline void MessageOfBombedBullet::clear_type() + { + _impl_.type_ = 0; + } + inline ::protobuf::BulletType MessageOfBombedBullet::_internal_type() const + { + return static_cast<::protobuf::BulletType>(_impl_.type_); + } + inline ::protobuf::BulletType MessageOfBombedBullet::type() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBombedBullet.type) + return _internal_type(); + } + inline void MessageOfBombedBullet::_internal_set_type(::protobuf::BulletType value) + { + _impl_.type_ = value; + } + inline void MessageOfBombedBullet::set_type(::protobuf::BulletType value) + { + _internal_set_type(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBombedBullet.type) + } + + // int32 x = 2; + inline void MessageOfBombedBullet::clear_x() + { + _impl_.x_ = 0; + } + inline int32_t MessageOfBombedBullet::_internal_x() const + { + return _impl_.x_; + } + inline int32_t MessageOfBombedBullet::x() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBombedBullet.x) + return _internal_x(); + } + inline void MessageOfBombedBullet::_internal_set_x(int32_t value) + { + _impl_.x_ = value; + } + inline void MessageOfBombedBullet::set_x(int32_t value) + { + _internal_set_x(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBombedBullet.x) + } + + // int32 y = 3; + inline void MessageOfBombedBullet::clear_y() + { + _impl_.y_ = 0; + } + inline int32_t MessageOfBombedBullet::_internal_y() const + { + return _impl_.y_; + } + inline int32_t MessageOfBombedBullet::y() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBombedBullet.y) + return _internal_y(); + } + inline void MessageOfBombedBullet::_internal_set_y(int32_t value) + { + _impl_.y_ = value; + } + inline void MessageOfBombedBullet::set_y(int32_t value) + { + _internal_set_y(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBombedBullet.y) + } + + // double facing_direction = 4; + inline void MessageOfBombedBullet::clear_facing_direction() + { + _impl_.facing_direction_ = 0; + } + inline double MessageOfBombedBullet::_internal_facing_direction() const + { + return _impl_.facing_direction_; + } + inline double MessageOfBombedBullet::facing_direction() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBombedBullet.facing_direction) + return _internal_facing_direction(); + } + inline void MessageOfBombedBullet::_internal_set_facing_direction(double value) + { + _impl_.facing_direction_ = value; + } + inline void MessageOfBombedBullet::set_facing_direction(double value) + { + _internal_set_facing_direction(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBombedBullet.facing_direction) + } + + // int64 mapping_id = 5; + inline void MessageOfBombedBullet::clear_mapping_id() + { + _impl_.mapping_id_ = int64_t{0}; + } + inline int64_t MessageOfBombedBullet::_internal_mapping_id() const + { + return _impl_.mapping_id_; + } + inline int64_t MessageOfBombedBullet::mapping_id() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBombedBullet.mapping_id) + return _internal_mapping_id(); + } + inline void MessageOfBombedBullet::_internal_set_mapping_id(int64_t value) + { + _impl_.mapping_id_ = value; + } + inline void MessageOfBombedBullet::set_mapping_id(int64_t value) + { + _internal_set_mapping_id(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBombedBullet.mapping_id) + } + + // double bomb_range = 6; + inline void MessageOfBombedBullet::clear_bomb_range() + { + _impl_.bomb_range_ = 0; + } + inline double MessageOfBombedBullet::_internal_bomb_range() const + { + return _impl_.bomb_range_; + } + inline double MessageOfBombedBullet::bomb_range() const + { + // @@protoc_insertion_point(field_get:protobuf.MessageOfBombedBullet.bomb_range) + return _internal_bomb_range(); + } + inline void MessageOfBombedBullet::_internal_set_bomb_range(double value) + { + _impl_.bomb_range_ = value; + } + inline void MessageOfBombedBullet::set_bomb_range(double value) + { + _internal_set_bomb_range(value); + // @@protoc_insertion_point(field_set:protobuf.MessageOfBombedBullet.bomb_range) + } + + // ------------------------------------------------------------------- + // MessageOfProp // .protobuf.PropType type = 1; @@ -4514,6 +5396,10 @@ namespace protobuf // ------------------------------------------------------------------- + // ------------------------------------------------------------------- + + // ------------------------------------------------------------------- + // @@protoc_insertion_point(namespace_scope) } // namespace protobuf diff --git a/CAPI/proto/MessageType.pb.cc b/CAPI/proto/MessageType.pb.cc index 49804f3..09c8d23 100644 --- a/CAPI/proto/MessageType.pb.cc +++ b/CAPI/proto/MessageType.pb.cc @@ -23,43 +23,47 @@ namespace _pbi = _pb::internal; namespace protobuf { } // namespace protobuf -static const ::_pb::EnumDescriptor* file_level_enum_descriptors_MessageType_2eproto[10]; +static const ::_pb::EnumDescriptor* file_level_enum_descriptors_MessageType_2eproto[11]; static constexpr ::_pb::ServiceDescriptor const** file_level_service_descriptors_MessageType_2eproto = nullptr; const uint32_t TableStruct_MessageType_2eproto::offsets[1] = {}; static constexpr ::_pbi::MigrationSchema* schemas = nullptr; static constexpr ::_pb::Message* const* file_default_instances = nullptr; const char descriptor_table_protodef_MessageType_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = - "\n\021MessageType.proto\022\010protobuf*i\n\tPlaceTy" - "pe\022\023\n\017NULL_PLACE_TYPE\020\000\022\010\n\004LAND\020\001\022\010\n\004WAL" - "L\020\002\022\t\n\005GRASS\020\003\022\r\n\tCLASSROOM\020\004\022\010\n\004GATE\020\005\022" - "\017\n\013HIDDEN_GATE\020\006*8\n\tShapeType\022\023\n\017NULL_SH" - "APE_TYPE\020\000\022\n\n\006CIRCLE\020\001\022\n\n\006SQUARE\020\002*N\n\010Pr" - "opType\022\022\n\016NULL_PROP_TYPE\020\000\022\n\n\006PTYPE1\020\001\022\n" - "\n\006PTYPE2\020\002\022\n\n\006PTYPE3\020\003\022\n\n\006PTYPE4\020\004*f\n\017St" - "udentBuffType\022\023\n\017NULL_SBUFF_TYPE\020\000\022\016\n\nSB" - "UFFTYPE1\020\001\022\016\n\nSBUFFTYPE2\020\002\022\016\n\nSBUFFTYPE3" - "\020\003\022\016\n\nSBUFFTYPE4\020\004*^\n\014StudentState\022\017\n\013NU" - "LL_STATUS\020\000\022\010\n\004IDLE\020\001\022\014\n\010LEARNING\020\002\022\014\n\010A" - "DDICTED\020\003\022\010\n\004QUIT\020\004\022\r\n\tGRADUATED\020\005*f\n\017Tr" - "ickerBuffType\022\023\n\017NULL_TBUFF_TYPE\020\000\022\016\n\nTB" - "UFFTYPE1\020\001\022\016\n\nTBUFFTYPE2\020\002\022\016\n\nTBUFFTYPE3" - "\020\003\022\016\n\nTBUFFTYPE4\020\004*J\n\nPlayerType\022\024\n\020NULL" - "_PLAYER_TYPE\020\000\022\022\n\016STUDENT_PLAYER\020\001\022\022\n\016TR" - "ICKER_PLAYER\020\002*l\n\013StudentType\022\025\n\021NULL_ST" - "UDENT_TYPE\020\000\022\020\n\014STUDENTTYPE1\020\001\022\020\n\014STUDEN" - "TTYPE2\020\002\022\020\n\014STUDENTTYPE3\020\003\022\020\n\014STUDENTTYP" - "E4\020\004*l\n\013TrickerType\022\025\n\021NULL_TRICKER_TYPE" - "\020\000\022\020\n\014TRICKERTYPE1\020\001\022\020\n\014TRICKERTYPE2\020\002\022\020" - "\n\014TRICKERTYPE3\020\003\022\020\n\014TRICKERTYPE4\020\004*P\n\tGa" - "meState\022\023\n\017NULL_GAME_STATE\020\000\022\016\n\nGAME_STA" - "RT\020\001\022\020\n\014GAME_RUNNING\020\002\022\014\n\010GAME_END\020\003b\006pr" - "oto3"; + "\n\021MessageType.proto\022\010protobuf*{\n\nBulletT" + "ype\022\024\n\020NULL_BULLET_TYPE\020\000\022\017\n\013LINE_BULLET" + "\020\001\022\021\n\rCOMMON_BULLET\020\002\022\017\n\013FAST_BULLET\020\003\022\023" + "\n\017ORDINARY_BULLET\020\004\022\r\n\tATOM_BOMB\020\005*i\n\tPl" + "aceType\022\023\n\017NULL_PLACE_TYPE\020\000\022\010\n\004LAND\020\001\022\010" + "\n\004WALL\020\002\022\t\n\005GRASS\020\003\022\r\n\tCLASSROOM\020\004\022\010\n\004GA" + "TE\020\005\022\017\n\013HIDDEN_GATE\020\006*8\n\tShapeType\022\023\n\017NU" + "LL_SHAPE_TYPE\020\000\022\n\n\006CIRCLE\020\001\022\n\n\006SQUARE\020\002*" + "N\n\010PropType\022\022\n\016NULL_PROP_TYPE\020\000\022\n\n\006PTYPE" + "1\020\001\022\n\n\006PTYPE2\020\002\022\n\n\006PTYPE3\020\003\022\n\n\006PTYPE4\020\004*" + "f\n\017StudentBuffType\022\023\n\017NULL_SBUFF_TYPE\020\000\022" + "\016\n\nSBUFFTYPE1\020\001\022\016\n\nSBUFFTYPE2\020\002\022\016\n\nSBUFF" + "TYPE3\020\003\022\016\n\nSBUFFTYPE4\020\004*\205\001\n\014StudentState" + "\022\017\n\013NULL_STATUS\020\000\022\010\n\004IDLE\020\001\022\014\n\010LEARNING\020" + "\002\022\014\n\010ADDICTED\020\003\022\010\n\004QUIT\020\004\022\r\n\tGRADUATED\020\005" + "\022\013\n\007TREATED\020\006\022\013\n\007RESCUED\020\007\022\013\n\007STUNNED\020\010*" + "f\n\017TrickerBuffType\022\023\n\017NULL_TBUFF_TYPE\020\000\022" + "\016\n\nTBUFFTYPE1\020\001\022\016\n\nTBUFFTYPE2\020\002\022\016\n\nTBUFF" + "TYPE3\020\003\022\016\n\nTBUFFTYPE4\020\004*J\n\nPlayerType\022\024\n" + "\020NULL_PLAYER_TYPE\020\000\022\022\n\016STUDENT_PLAYER\020\001\022" + "\022\n\016TRICKER_PLAYER\020\002*l\n\013StudentType\022\025\n\021NU" + "LL_STUDENT_TYPE\020\000\022\020\n\014STUDENTTYPE1\020\001\022\020\n\014S" + "TUDENTTYPE2\020\002\022\020\n\014STUDENTTYPE3\020\003\022\020\n\014STUDE" + "NTTYPE4\020\004*l\n\013TrickerType\022\025\n\021NULL_TRICKER" + "_TYPE\020\000\022\020\n\014TRICKERTYPE1\020\001\022\020\n\014TRICKERTYPE" + "2\020\002\022\020\n\014TRICKERTYPE3\020\003\022\020\n\014TRICKERTYPE4\020\004*" + "P\n\tGameState\022\023\n\017NULL_GAME_STATE\020\000\022\016\n\nGAM" + "E_START\020\001\022\020\n\014GAME_RUNNING\020\002\022\014\n\010GAME_END\020" + "\003b\006proto3"; static ::_pbi::once_flag descriptor_table_MessageType_2eproto_once; const ::_pbi::DescriptorTable descriptor_table_MessageType_2eproto = { false, false, - 964, + 1129, descriptor_table_protodef_MessageType_2eproto, "MessageType.proto", &descriptor_table_MessageType_2eproto_once, @@ -82,11 +86,32 @@ PROTOBUF_ATTRIBUTE_WEAK const ::_pbi::DescriptorTable* descriptor_table_MessageT PROTOBUF_ATTRIBUTE_INIT_PRIORITY2 static ::_pbi::AddDescriptorsRunner dynamic_init_dummy_MessageType_2eproto(&descriptor_table_MessageType_2eproto); namespace protobuf { - const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* PlaceType_descriptor() + const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* BulletType_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); return file_level_enum_descriptors_MessageType_2eproto[0]; } + bool BulletType_IsValid(int value) + { + switch (value) + { + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + return true; + default: + return false; + } + } + + const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* PlaceType_descriptor() + { + ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); + return file_level_enum_descriptors_MessageType_2eproto[1]; + } bool PlaceType_IsValid(int value) { switch (value) @@ -107,7 +132,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ShapeType_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[1]; + return file_level_enum_descriptors_MessageType_2eproto[2]; } bool ShapeType_IsValid(int value) { @@ -125,7 +150,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* PropType_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[2]; + return file_level_enum_descriptors_MessageType_2eproto[3]; } bool PropType_IsValid(int value) { @@ -145,7 +170,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* StudentBuffType_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[3]; + return file_level_enum_descriptors_MessageType_2eproto[4]; } bool StudentBuffType_IsValid(int value) { @@ -165,7 +190,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* StudentState_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[4]; + return file_level_enum_descriptors_MessageType_2eproto[5]; } bool StudentState_IsValid(int value) { @@ -177,6 +202,9 @@ namespace protobuf case 3: case 4: case 5: + case 6: + case 7: + case 8: return true; default: return false; @@ -186,7 +214,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* TrickerBuffType_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[5]; + return file_level_enum_descriptors_MessageType_2eproto[6]; } bool TrickerBuffType_IsValid(int value) { @@ -206,7 +234,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* PlayerType_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[6]; + return file_level_enum_descriptors_MessageType_2eproto[7]; } bool PlayerType_IsValid(int value) { @@ -224,7 +252,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* StudentType_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[7]; + return file_level_enum_descriptors_MessageType_2eproto[8]; } bool StudentType_IsValid(int value) { @@ -244,7 +272,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* TrickerType_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[8]; + return file_level_enum_descriptors_MessageType_2eproto[9]; } bool TrickerType_IsValid(int value) { @@ -264,7 +292,7 @@ namespace protobuf const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* GameState_descriptor() { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_MessageType_2eproto); - return file_level_enum_descriptors_MessageType_2eproto[9]; + return file_level_enum_descriptors_MessageType_2eproto[10]; } bool GameState_IsValid(int value) { diff --git a/CAPI/proto/MessageType.pb.h b/CAPI/proto/MessageType.pb.h index 0b969f5..464988c 100644 --- a/CAPI/proto/MessageType.pb.h +++ b/CAPI/proto/MessageType.pb.h @@ -50,6 +50,39 @@ PROTOBUF_NAMESPACE_CLOSE namespace protobuf { + enum BulletType : int + { + NULL_BULLET_TYPE = 0, + LINE_BULLET = 1, + COMMON_BULLET = 2, + FAST_BULLET = 3, + ORDINARY_BULLET = 4, + ATOM_BOMB = 5, + BulletType_INT_MIN_SENTINEL_DO_NOT_USE_ = std::numeric_limits::min(), + BulletType_INT_MAX_SENTINEL_DO_NOT_USE_ = std::numeric_limits::max() + }; + bool BulletType_IsValid(int value); + constexpr BulletType BulletType_MIN = NULL_BULLET_TYPE; + constexpr BulletType BulletType_MAX = ATOM_BOMB; + constexpr int BulletType_ARRAYSIZE = BulletType_MAX + 1; + + const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* BulletType_descriptor(); + template + inline const std::string& BulletType_Name(T enum_t_value) + { + static_assert(::std::is_same::value || ::std::is_integral::value, "Incorrect type passed to function BulletType_Name."); + return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum( + BulletType_descriptor(), enum_t_value + ); + } + inline bool BulletType_Parse( + ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, BulletType* value + ) + { + return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum( + BulletType_descriptor(), name, value + ); + } enum PlaceType : int { NULL_PLACE_TYPE = 0, @@ -186,12 +219,15 @@ namespace protobuf ADDICTED = 3, QUIT = 4, GRADUATED = 5, + TREATED = 6, + RESCUED = 7, + STUNNED = 8, StudentState_INT_MIN_SENTINEL_DO_NOT_USE_ = std::numeric_limits::min(), StudentState_INT_MAX_SENTINEL_DO_NOT_USE_ = std::numeric_limits::max() }; bool StudentState_IsValid(int value); constexpr StudentState StudentState_MIN = NULL_STATUS; - constexpr StudentState StudentState_MAX = GRADUATED; + constexpr StudentState StudentState_MAX = STUNNED; constexpr int StudentState_ARRAYSIZE = StudentState_MAX + 1; const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* StudentState_descriptor(); @@ -388,6 +424,15 @@ namespace protobuf PROTOBUF_NAMESPACE_OPEN +template<> +struct is_proto_enum<::protobuf::BulletType> : ::std::true_type +{ +}; +template<> +inline const EnumDescriptor* GetEnumDescriptor<::protobuf::BulletType>() +{ + return ::protobuf::BulletType_descriptor(); +} template<> struct is_proto_enum<::protobuf::PlaceType> : ::std::true_type { diff --git a/dependency/proto/Message2Clients.proto b/dependency/proto/Message2Clients.proto index 4490f5d..3684edf 100755 --- a/dependency/proto/Message2Clients.proto +++ b/dependency/proto/Message2Clients.proto @@ -44,6 +44,28 @@ message MessageOfTricker repeated TrickerBuffType buff = 14; } +message MessageOfBullet +{ + BulletType type = 1; + int32 x = 2; + int32 y = 3; + double facing_direction = 4; + int64 guid = 5; + int64 parent_team_id = 6; + PlaceType place = 7; + double bomb_range = 8; +} + +message MessageOfBombedBullet //for Unity,直接继承自THUAI5 +{ + BulletType type = 1; + int32 x = 2; + int32 y = 3; + double facing_direction = 4; + int64 mapping_id = 5; + double bomb_range = 6; +} + message MessageOfProp // 可拾取道具的信息 { PropType type = 1; diff --git a/dependency/proto/MessageType.proto b/dependency/proto/MessageType.proto index 2019eb5..1c928f6 100755 --- a/dependency/proto/MessageType.proto +++ b/dependency/proto/MessageType.proto @@ -2,6 +2,16 @@ syntax = "proto3"; package protobuf; +enum BulletType +{ + NULL_BULLET_TYPE = 0; + LINE_BULLET = 1; + COMMON_BULLET = 2; + FAST_BULLET = 3; + ORDINARY_BULLET = 4; + ATOM_BOMB = 5; +} + enum PlaceType // 地图中的所有物件类型 { NULL_PLACE_TYPE = 0; @@ -51,6 +61,9 @@ enum StudentState ADDICTED = 3; // 血条归零后原地沉迷游戏 QUIT = 4; // 退学状态,相当于寄了 GRADUATED = 5; // 毕业状态,相当于逃脱了 + TREATED = 6; + RESCUED = 7; + STUNNED = 8; } enum TrickerBuffType // 屠夫可用的增益效果类型