// This file is generated by rust-protobuf 2.20.0. Do not edit
// @generated

// https://github.com/rust-lang/rust-clippy/issues/702
#![allow(unknown_lints)]
#![allow(clippy::all)]

#![allow(unused_attributes)]
#![rustfmt::skip]

#![allow(box_pointers)]
#![allow(dead_code)]
#![allow(missing_docs)]
#![allow(non_camel_case_types)]
#![allow(non_snake_case)]
#![allow(non_upper_case_globals)]
#![allow(trivial_casts)]
#![allow(unused_imports)]
#![allow(unused_results)]
//! Generated file from `s2clientprotocol/query.proto`

/// Generated files are compatible only with the same version
/// of protobuf runtime.
// const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_2_20_0;

#[derive(PartialEq,Clone,Default)]
pub struct RequestQuery {
    // message fields
    pub pathing: ::protobuf::RepeatedField<RequestQueryPathing>,
    pub abilities: ::protobuf::RepeatedField<RequestQueryAvailableAbilities>,
    pub placements: ::protobuf::RepeatedField<RequestQueryBuildingPlacement>,
    pub ignore_resource_requirements: ::std::option::Option<bool>,
    // special fields
    pub unknown_fields: ::protobuf::UnknownFields,
    pub cached_size: ::protobuf::CachedSize,
}

impl<'a> ::std::default::Default for &'a RequestQuery {
    fn default() -> &'a RequestQuery {
        <RequestQuery as ::protobuf::Message>::default_instance()
    }
}

impl RequestQuery {
    pub fn new() -> RequestQuery {
        ::std::default::Default::default()
    }

    // repeated .SC2APIProtocol.RequestQueryPathing pathing = 1;


    pub fn get_pathing(&self) -> &[RequestQueryPathing] {
        &self.pathing
    }
    pub fn clear_pathing(&mut self) {
        self.pathing.clear();
    }

    // Param is passed by value, moved
    pub fn set_pathing(&mut self, v: ::protobuf::RepeatedField<RequestQueryPathing>) {
        self.pathing = v;
    }

    // Mutable pointer to the field.
    pub fn mut_pathing(&mut self) -> &mut ::protobuf::RepeatedField<RequestQueryPathing> {
        &mut self.pathing
    }

    // Take field
    pub fn take_pathing(&mut self) -> ::protobuf::RepeatedField<RequestQueryPathing> {
        ::std::mem::replace(&mut self.pathing, ::protobuf::RepeatedField::new())
    }

    // repeated .SC2APIProtocol.RequestQueryAvailableAbilities abilities = 2;


    pub fn get_abilities(&self) -> &[RequestQueryAvailableAbilities] {
        &self.abilities
    }
    pub fn clear_abilities(&mut self) {
        self.abilities.clear();
    }

    // Param is passed by value, moved
    pub fn set_abilities(&mut self, v: ::protobuf::RepeatedField<RequestQueryAvailableAbilities>) {
        self.abilities = v;
    }

    // Mutable pointer to the field.
    pub fn mut_abilities(&mut self) -> &mut ::protobuf::RepeatedField<RequestQueryAvailableAbilities> {
        &mut self.abilities
    }

    // Take field
    pub fn take_abilities(&mut self) -> ::protobuf::RepeatedField<RequestQueryAvailableAbilities> {
        ::std::mem::replace(&mut self.abilities, ::protobuf::RepeatedField::new())
    }

    // repeated .SC2APIProtocol.RequestQueryBuildingPlacement placements = 3;


    pub fn get_placements(&self) -> &[RequestQueryBuildingPlacement] {
        &self.placements
    }
    pub fn clear_placements(&mut self) {
        self.placements.clear();
    }

    // Param is passed by value, moved
    pub fn set_placements(&mut self, v: ::protobuf::RepeatedField<RequestQueryBuildingPlacement>) {
        self.placements = v;
    }

    // Mutable pointer to the field.
    pub fn mut_placements(&mut self) -> &mut ::protobuf::RepeatedField<RequestQueryBuildingPlacement> {
        &mut self.placements
    }

    // Take field
    pub fn take_placements(&mut self) -> ::protobuf::RepeatedField<RequestQueryBuildingPlacement> {
        ::std::mem::replace(&mut self.placements, ::protobuf::RepeatedField::new())
    }

    // optional bool ignore_resource_requirements = 4;


    pub fn get_ignore_resource_requirements(&self) -> bool {
        self.ignore_resource_requirements.unwrap_or(false)
    }
    pub fn clear_ignore_resource_requirements(&mut self) {
        self.ignore_resource_requirements = ::std::option::Option::None;
    }

    pub fn has_ignore_resource_requirements(&self) -> bool {
        self.ignore_resource_requirements.is_some()
    }

    // Param is passed by value, moved
    pub fn set_ignore_resource_requirements(&mut self, v: bool) {
        self.ignore_resource_requirements = ::std::option::Option::Some(v);
    }
}

impl ::protobuf::Message for RequestQuery {
    fn is_initialized(&self) -> bool {
        for v in &self.pathing {
            if !v.is_initialized() {
                return false;
            }
        };
        for v in &self.abilities {
            if !v.is_initialized() {
                return false;
            }
        };
        for v in &self.placements {
            if !v.is_initialized() {
                return false;
            }
        };
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        while !is.eof()? {
            let (field_number, wire_type) = is.read_tag_unpack()?;
            match field_number {
                1 => {
                    ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.pathing)?;
                },
                2 => {
                    ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.abilities)?;
                },
                3 => {
                    ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.placements)?;
                },
                4 => {
                    if wire_type != ::protobuf::wire_format::WireTypeVarint {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    let tmp = is.read_bool()?;
                    self.ignore_resource_requirements = ::std::option::Option::Some(tmp);
                },
                _ => {
                    ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u32 {
        let mut my_size = 0;
        for value in &self.pathing {
            let len = value.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        };
        for value in &self.abilities {
            let len = value.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        };
        for value in &self.placements {
            let len = value.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        };
        if let Some(v) = self.ignore_resource_requirements {
            my_size += 2;
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
        self.cached_size.set(my_size);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        for v in &self.pathing {
            os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        };
        for v in &self.abilities {
            os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        };
        for v in &self.placements {
            os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        };
        if let Some(v) = self.ignore_resource_requirements {
            os.write_bool(4, v)?;
        }
        os.write_unknown_fields(self.get_unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn get_cached_size(&self) -> u32 {
        self.cached_size.get()
    }

    fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
        &self.unknown_fields
    }

    fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
        &mut self.unknown_fields
    }

    fn as_any(&self) -> &dyn (::std::any::Any) {
        self as &dyn (::std::any::Any)
    }
    fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
        self as &mut dyn (::std::any::Any)
    }
    fn into_any(self: ::std::boxed::Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
        self
    }

    fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
        Self::descriptor_static()
    }

    fn new() -> RequestQuery {
        RequestQuery::new()
    }

    fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::LazyV2::INIT;
        descriptor.get(|| {
            let mut fields = ::std::vec::Vec::new();
            fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<RequestQueryPathing>>(
                "pathing",
                |m: &RequestQuery| { &m.pathing },
                |m: &mut RequestQuery| { &mut m.pathing },
            ));
            fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<RequestQueryAvailableAbilities>>(
                "abilities",
                |m: &RequestQuery| { &m.abilities },
                |m: &mut RequestQuery| { &mut m.abilities },
            ));
            fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<RequestQueryBuildingPlacement>>(
                "placements",
                |m: &RequestQuery| { &m.placements },
                |m: &mut RequestQuery| { &mut m.placements },
            ));
            fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
                "ignore_resource_requirements",
                |m: &RequestQuery| { &m.ignore_resource_requirements },
                |m: &mut RequestQuery| { &mut m.ignore_resource_requirements },
            ));
            ::protobuf::reflect::MessageDescriptor::new_pb_name::<RequestQuery>(
                "RequestQuery",
                fields,
                file_descriptor_proto()
            )
        })
    }

    fn default_instance() -> &'static RequestQuery {
        static instance: ::protobuf::rt::LazyV2<RequestQuery> = ::protobuf::rt::LazyV2::INIT;
        instance.get(RequestQuery::new)
    }
}

impl ::protobuf::Clear for RequestQuery {
    fn clear(&mut self) {
        self.pathing.clear();
        self.abilities.clear();
        self.placements.clear();
        self.ignore_resource_requirements = ::std::option::Option::None;
        self.unknown_fields.clear();
    }
}

impl ::std::fmt::Debug for RequestQuery {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for RequestQuery {
    fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
        ::protobuf::reflect::ReflectValueRef::Message(self)
    }
}

#[derive(PartialEq,Clone,Default)]
pub struct ResponseQuery {
    // message fields
    pub pathing: ::protobuf::RepeatedField<ResponseQueryPathing>,
    pub abilities: ::protobuf::RepeatedField<ResponseQueryAvailableAbilities>,
    pub placements: ::protobuf::RepeatedField<ResponseQueryBuildingPlacement>,
    // special fields
    pub unknown_fields: ::protobuf::UnknownFields,
    pub cached_size: ::protobuf::CachedSize,
}

impl<'a> ::std::default::Default for &'a ResponseQuery {
    fn default() -> &'a ResponseQuery {
        <ResponseQuery as ::protobuf::Message>::default_instance()
    }
}

impl ResponseQuery {
    pub fn new() -> ResponseQuery {
        ::std::default::Default::default()
    }

    // repeated .SC2APIProtocol.ResponseQueryPathing pathing = 1;


    pub fn get_pathing(&self) -> &[ResponseQueryPathing] {
        &self.pathing
    }
    pub fn clear_pathing(&mut self) {
        self.pathing.clear();
    }

    // Param is passed by value, moved
    pub fn set_pathing(&mut self, v: ::protobuf::RepeatedField<ResponseQueryPathing>) {
        self.pathing = v;
    }

    // Mutable pointer to the field.
    pub fn mut_pathing(&mut self) -> &mut ::protobuf::RepeatedField<ResponseQueryPathing> {
        &mut self.pathing
    }

    // Take field
    pub fn take_pathing(&mut self) -> ::protobuf::RepeatedField<ResponseQueryPathing> {
        ::std::mem::replace(&mut self.pathing, ::protobuf::RepeatedField::new())
    }

    // repeated .SC2APIProtocol.ResponseQueryAvailableAbilities abilities = 2;


    pub fn get_abilities(&self) -> &[ResponseQueryAvailableAbilities] {
        &self.abilities
    }
    pub fn clear_abilities(&mut self) {
        self.abilities.clear();
    }

    // Param is passed by value, moved
    pub fn set_abilities(&mut self, v: ::protobuf::RepeatedField<ResponseQueryAvailableAbilities>) {
        self.abilities = v;
    }

    // Mutable pointer to the field.
    pub fn mut_abilities(&mut self) -> &mut ::protobuf::RepeatedField<ResponseQueryAvailableAbilities> {
        &mut self.abilities
    }

    // Take field
    pub fn take_abilities(&mut self) -> ::protobuf::RepeatedField<ResponseQueryAvailableAbilities> {
        ::std::mem::replace(&mut self.abilities, ::protobuf::RepeatedField::new())
    }

    // repeated .SC2APIProtocol.ResponseQueryBuildingPlacement placements = 3;


    pub fn get_placements(&self) -> &[ResponseQueryBuildingPlacement] {
        &self.placements
    }
    pub fn clear_placements(&mut self) {
        self.placements.clear();
    }

    // Param is passed by value, moved
    pub fn set_placements(&mut self, v: ::protobuf::RepeatedField<ResponseQueryBuildingPlacement>) {
        self.placements = v;
    }

    // Mutable pointer to the field.
    pub fn mut_placements(&mut self) -> &mut ::protobuf::RepeatedField<ResponseQueryBuildingPlacement> {
        &mut self.placements
    }

    // Take field
    pub fn take_placements(&mut self) -> ::protobuf::RepeatedField<ResponseQueryBuildingPlacement> {
        ::std::mem::replace(&mut self.placements, ::protobuf::RepeatedField::new())
    }
}

impl ::protobuf::Message for ResponseQuery {
    fn is_initialized(&self) -> bool {
        for v in &self.pathing {
            if !v.is_initialized() {
                return false;
            }
        };
        for v in &self.abilities {
            if !v.is_initialized() {
                return false;
            }
        };
        for v in &self.placements {
            if !v.is_initialized() {
                return false;
            }
        };
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        while !is.eof()? {
            let (field_number, wire_type) = is.read_tag_unpack()?;
            match field_number {
                1 => {
                    ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.pathing)?;
                },
                2 => {
                    ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.abilities)?;
                },
                3 => {
                    ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.placements)?;
                },
                _ => {
                    ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u32 {
        let mut my_size = 0;
        for value in &self.pathing {
            let len = value.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        };
        for value in &self.abilities {
            let len = value.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        };
        for value in &self.placements {
            let len = value.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        };
        my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
        self.cached_size.set(my_size);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        for v in &self.pathing {
            os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        };
        for v in &self.abilities {
            os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        };
        for v in &self.placements {
            os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        };
        os.write_unknown_fields(self.get_unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn get_cached_size(&self) -> u32 {
        self.cached_size.get()
    }

    fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
        &self.unknown_fields
    }

    fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
        &mut self.unknown_fields
    }

    fn as_any(&self) -> &dyn (::std::any::Any) {
        self as &dyn (::std::any::Any)
    }
    fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
        self as &mut dyn (::std::any::Any)
    }
    fn into_any(self: ::std::boxed::Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
        self
    }

    fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
        Self::descriptor_static()
    }

    fn new() -> ResponseQuery {
        ResponseQuery::new()
    }

    fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::LazyV2::INIT;
        descriptor.get(|| {
            let mut fields = ::std::vec::Vec::new();
            fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ResponseQueryPathing>>(
                "pathing",
                |m: &ResponseQuery| { &m.pathing },
                |m: &mut ResponseQuery| { &mut m.pathing },
            ));
            fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ResponseQueryAvailableAbilities>>(
                "abilities",
                |m: &ResponseQuery| { &m.abilities },
                |m: &mut ResponseQuery| { &mut m.abilities },
            ));
            fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ResponseQueryBuildingPlacement>>(
                "placements",
                |m: &ResponseQuery| { &m.placements },
                |m: &mut ResponseQuery| { &mut m.placements },
            ));
            ::protobuf::reflect::MessageDescriptor::new_pb_name::<ResponseQuery>(
                "ResponseQuery",
                fields,
                file_descriptor_proto()
            )
        })
    }

    fn default_instance() -> &'static ResponseQuery {
        static instance: ::protobuf::rt::LazyV2<ResponseQuery> = ::protobuf::rt::LazyV2::INIT;
        instance.get(ResponseQuery::new)
    }
}

impl ::protobuf::Clear for ResponseQuery {
    fn clear(&mut self) {
        self.pathing.clear();
        self.abilities.clear();
        self.placements.clear();
        self.unknown_fields.clear();
    }
}

impl ::std::fmt::Debug for ResponseQuery {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for ResponseQuery {
    fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
        ::protobuf::reflect::ReflectValueRef::Message(self)
    }
}

#[derive(PartialEq,Clone,Default)]
pub struct RequestQueryPathing {
    // message fields
    pub end_pos: ::protobuf::SingularPtrField<super::common::Point2D>,
    // message oneof groups
    pub start: ::std::option::Option<RequestQueryPathing_oneof_start>,
    // special fields
    pub unknown_fields: ::protobuf::UnknownFields,
    pub cached_size: ::protobuf::CachedSize,
}

impl<'a> ::std::default::Default for &'a RequestQueryPathing {
    fn default() -> &'a RequestQueryPathing {
        <RequestQueryPathing as ::protobuf::Message>::default_instance()
    }
}

#[derive(Clone,PartialEq,Debug)]
pub enum RequestQueryPathing_oneof_start {
    start_pos(super::common::Point2D),
    unit_tag(u64),
}

impl RequestQueryPathing {
    pub fn new() -> RequestQueryPathing {
        ::std::default::Default::default()
    }

    // optional .SC2APIProtocol.Point2D start_pos = 1;


    pub fn get_start_pos(&self) -> &super::common::Point2D {
        match self.start {
            ::std::option::Option::Some(RequestQueryPathing_oneof_start::start_pos(ref v)) => v,
            _ => <super::common::Point2D as ::protobuf::Message>::default_instance(),
        }
    }
    pub fn clear_start_pos(&mut self) {
        self.start = ::std::option::Option::None;
    }

    pub fn has_start_pos(&self) -> bool {
        match self.start {
            ::std::option::Option::Some(RequestQueryPathing_oneof_start::start_pos(..)) => true,
            _ => false,
        }
    }

    // Param is passed by value, moved
    pub fn set_start_pos(&mut self, v: super::common::Point2D) {
        self.start = ::std::option::Option::Some(RequestQueryPathing_oneof_start::start_pos(v))
    }

    // Mutable pointer to the field.
    pub fn mut_start_pos(&mut self) -> &mut super::common::Point2D {
        if let ::std::option::Option::Some(RequestQueryPathing_oneof_start::start_pos(_)) = self.start {
        } else {
            self.start = ::std::option::Option::Some(RequestQueryPathing_oneof_start::start_pos(super::common::Point2D::new()));
        }
        match self.start {
            ::std::option::Option::Some(RequestQueryPathing_oneof_start::start_pos(ref mut v)) => v,
            _ => panic!(),
        }
    }

    // Take field
    pub fn take_start_pos(&mut self) -> super::common::Point2D {
        if self.has_start_pos() {
            match self.start.take() {
                ::std::option::Option::Some(RequestQueryPathing_oneof_start::start_pos(v)) => v,
                _ => panic!(),
            }
        } else {
            super::common::Point2D::new()
        }
    }

    // optional uint64 unit_tag = 2;


    pub fn get_unit_tag(&self) -> u64 {
        match self.start {
            ::std::option::Option::Some(RequestQueryPathing_oneof_start::unit_tag(v)) => v,
            _ => 0,
        }
    }
    pub fn clear_unit_tag(&mut self) {
        self.start = ::std::option::Option::None;
    }

    pub fn has_unit_tag(&self) -> bool {
        match self.start {
            ::std::option::Option::Some(RequestQueryPathing_oneof_start::unit_tag(..)) => true,
            _ => false,
        }
    }

    // Param is passed by value, moved
    pub fn set_unit_tag(&mut self, v: u64) {
        self.start = ::std::option::Option::Some(RequestQueryPathing_oneof_start::unit_tag(v))
    }

    // optional .SC2APIProtocol.Point2D end_pos = 3;


    pub fn get_end_pos(&self) -> &super::common::Point2D {
        self.end_pos.as_ref().unwrap_or_else(|| <super::common::Point2D as ::protobuf::Message>::default_instance())
    }
    pub fn clear_end_pos(&mut self) {
        self.end_pos.clear();
    }

    pub fn has_end_pos(&self) -> bool {
        self.end_pos.is_some()
    }

    // Param is passed by value, moved
    pub fn set_end_pos(&mut self, v: super::common::Point2D) {
        self.end_pos = ::protobuf::SingularPtrField::some(v);
    }

    // Mutable pointer to the field.
    // If field is not initialized, it is initialized with default value first.
    pub fn mut_end_pos(&mut self) -> &mut super::common::Point2D {
        if self.end_pos.is_none() {
            self.end_pos.set_default();
        }
        self.end_pos.as_mut().unwrap()
    }

    // Take field
    pub fn take_end_pos(&mut self) -> super::common::Point2D {
        self.end_pos.take().unwrap_or_else(|| super::common::Point2D::new())
    }
}

impl ::protobuf::Message for RequestQueryPathing {
    fn is_initialized(&self) -> bool {
        if let Some(RequestQueryPathing_oneof_start::start_pos(ref v)) = self.start {
            if !v.is_initialized() {
                return false;
            }
        }
        for v in &self.end_pos {
            if !v.is_initialized() {
                return false;
            }
        };
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        while !is.eof()? {
            let (field_number, wire_type) = is.read_tag_unpack()?;
            match field_number {
                1 => {
                    if wire_type != ::protobuf::wire_format::WireTypeLengthDelimited {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    self.start = ::std::option::Option::Some(RequestQueryPathing_oneof_start::start_pos(is.read_message()?));
                },
                2 => {
                    if wire_type != ::protobuf::wire_format::WireTypeVarint {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    self.start = ::std::option::Option::Some(RequestQueryPathing_oneof_start::unit_tag(is.read_uint64()?));
                },
                3 => {
                    ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.end_pos)?;
                },
                _ => {
                    ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u32 {
        let mut my_size = 0;
        if let Some(ref v) = self.end_pos.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        }
        if let ::std::option::Option::Some(ref v) = self.start {
            match v {
                &RequestQueryPathing_oneof_start::start_pos(ref v) => {
                    let len = v.compute_size();
                    my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
                },
                &RequestQueryPathing_oneof_start::unit_tag(v) => {
                    my_size += ::protobuf::rt::value_size(2, v, ::protobuf::wire_format::WireTypeVarint);
                },
            };
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
        self.cached_size.set(my_size);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        if let Some(ref v) = self.end_pos.as_ref() {
            os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        }
        if let ::std::option::Option::Some(ref v) = self.start {
            match v {
                &RequestQueryPathing_oneof_start::start_pos(ref v) => {
                    os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
                    os.write_raw_varint32(v.get_cached_size())?;
                    v.write_to_with_cached_sizes(os)?;
                },
                &RequestQueryPathing_oneof_start::unit_tag(v) => {
                    os.write_uint64(2, v)?;
                },
            };
        }
        os.write_unknown_fields(self.get_unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn get_cached_size(&self) -> u32 {
        self.cached_size.get()
    }

    fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
        &self.unknown_fields
    }

    fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
        &mut self.unknown_fields
    }

    fn as_any(&self) -> &dyn (::std::any::Any) {
        self as &dyn (::std::any::Any)
    }
    fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
        self as &mut dyn (::std::any::Any)
    }
    fn into_any(self: ::std::boxed::Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
        self
    }

    fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
        Self::descriptor_static()
    }

    fn new() -> RequestQueryPathing {
        RequestQueryPathing::new()
    }

    fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::LazyV2::INIT;
        descriptor.get(|| {
            let mut fields = ::std::vec::Vec::new();
            fields.push(::protobuf::reflect::accessor::make_singular_message_accessor::<_, super::common::Point2D>(
                "start_pos",
                RequestQueryPathing::has_start_pos,
                RequestQueryPathing::get_start_pos,
            ));
            fields.push(::protobuf::reflect::accessor::make_singular_u64_accessor::<_>(
                "unit_tag",
                RequestQueryPathing::has_unit_tag,
                RequestQueryPathing::get_unit_tag,
            ));
            fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::common::Point2D>>(
                "end_pos",
                |m: &RequestQueryPathing| { &m.end_pos },
                |m: &mut RequestQueryPathing| { &mut m.end_pos },
            ));
            ::protobuf::reflect::MessageDescriptor::new_pb_name::<RequestQueryPathing>(
                "RequestQueryPathing",
                fields,
                file_descriptor_proto()
            )
        })
    }

    fn default_instance() -> &'static RequestQueryPathing {
        static instance: ::protobuf::rt::LazyV2<RequestQueryPathing> = ::protobuf::rt::LazyV2::INIT;
        instance.get(RequestQueryPathing::new)
    }
}

impl ::protobuf::Clear for RequestQueryPathing {
    fn clear(&mut self) {
        self.start = ::std::option::Option::None;
        self.start = ::std::option::Option::None;
        self.end_pos.clear();
        self.unknown_fields.clear();
    }
}

impl ::std::fmt::Debug for RequestQueryPathing {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for RequestQueryPathing {
    fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
        ::protobuf::reflect::ReflectValueRef::Message(self)
    }
}

#[derive(PartialEq,Clone,Default)]
pub struct ResponseQueryPathing {
    // message fields
    pub distance: ::std::option::Option<f32>,
    // special fields
    pub unknown_fields: ::protobuf::UnknownFields,
    pub cached_size: ::protobuf::CachedSize,
}

impl<'a> ::std::default::Default for &'a ResponseQueryPathing {
    fn default() -> &'a ResponseQueryPathing {
        <ResponseQueryPathing as ::protobuf::Message>::default_instance()
    }
}

impl ResponseQueryPathing {
    pub fn new() -> ResponseQueryPathing {
        ::std::default::Default::default()
    }

    // optional float distance = 1;


    pub fn get_distance(&self) -> f32 {
        self.distance.unwrap_or(0.)
    }
    pub fn clear_distance(&mut self) {
        self.distance = ::std::option::Option::None;
    }

    pub fn has_distance(&self) -> bool {
        self.distance.is_some()
    }

    // Param is passed by value, moved
    pub fn set_distance(&mut self, v: f32) {
        self.distance = ::std::option::Option::Some(v);
    }
}

impl ::protobuf::Message for ResponseQueryPathing {
    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        while !is.eof()? {
            let (field_number, wire_type) = is.read_tag_unpack()?;
            match field_number {
                1 => {
                    if wire_type != ::protobuf::wire_format::WireTypeFixed32 {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    let tmp = is.read_float()?;
                    self.distance = ::std::option::Option::Some(tmp);
                },
                _ => {
                    ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u32 {
        let mut my_size = 0;
        if let Some(v) = self.distance {
            my_size += 5;
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
        self.cached_size.set(my_size);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        if let Some(v) = self.distance {
            os.write_float(1, v)?;
        }
        os.write_unknown_fields(self.get_unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn get_cached_size(&self) -> u32 {
        self.cached_size.get()
    }

    fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
        &self.unknown_fields
    }

    fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
        &mut self.unknown_fields
    }

    fn as_any(&self) -> &dyn (::std::any::Any) {
        self as &dyn (::std::any::Any)
    }
    fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
        self as &mut dyn (::std::any::Any)
    }
    fn into_any(self: ::std::boxed::Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
        self
    }

    fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
        Self::descriptor_static()
    }

    fn new() -> ResponseQueryPathing {
        ResponseQueryPathing::new()
    }

    fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::LazyV2::INIT;
        descriptor.get(|| {
            let mut fields = ::std::vec::Vec::new();
            fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeFloat>(
                "distance",
                |m: &ResponseQueryPathing| { &m.distance },
                |m: &mut ResponseQueryPathing| { &mut m.distance },
            ));
            ::protobuf::reflect::MessageDescriptor::new_pb_name::<ResponseQueryPathing>(
                "ResponseQueryPathing",
                fields,
                file_descriptor_proto()
            )
        })
    }

    fn default_instance() -> &'static ResponseQueryPathing {
        static instance: ::protobuf::rt::LazyV2<ResponseQueryPathing> = ::protobuf::rt::LazyV2::INIT;
        instance.get(ResponseQueryPathing::new)
    }
}

impl ::protobuf::Clear for ResponseQueryPathing {
    fn clear(&mut self) {
        self.distance = ::std::option::Option::None;
        self.unknown_fields.clear();
    }
}

impl ::std::fmt::Debug for ResponseQueryPathing {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for ResponseQueryPathing {
    fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
        ::protobuf::reflect::ReflectValueRef::Message(self)
    }
}

#[derive(PartialEq,Clone,Default)]
pub struct RequestQueryAvailableAbilities {
    // message fields
    pub unit_tag: ::std::option::Option<u64>,
    // special fields
    pub unknown_fields: ::protobuf::UnknownFields,
    pub cached_size: ::protobuf::CachedSize,
}

impl<'a> ::std::default::Default for &'a RequestQueryAvailableAbilities {
    fn default() -> &'a RequestQueryAvailableAbilities {
        <RequestQueryAvailableAbilities as ::protobuf::Message>::default_instance()
    }
}

impl RequestQueryAvailableAbilities {
    pub fn new() -> RequestQueryAvailableAbilities {
        ::std::default::Default::default()
    }

    // optional uint64 unit_tag = 1;


    pub fn get_unit_tag(&self) -> u64 {
        self.unit_tag.unwrap_or(0)
    }
    pub fn clear_unit_tag(&mut self) {
        self.unit_tag = ::std::option::Option::None;
    }

    pub fn has_unit_tag(&self) -> bool {
        self.unit_tag.is_some()
    }

    // Param is passed by value, moved
    pub fn set_unit_tag(&mut self, v: u64) {
        self.unit_tag = ::std::option::Option::Some(v);
    }
}

impl ::protobuf::Message for RequestQueryAvailableAbilities {
    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        while !is.eof()? {
            let (field_number, wire_type) = is.read_tag_unpack()?;
            match field_number {
                1 => {
                    if wire_type != ::protobuf::wire_format::WireTypeVarint {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    let tmp = is.read_uint64()?;
                    self.unit_tag = ::std::option::Option::Some(tmp);
                },
                _ => {
                    ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u32 {
        let mut my_size = 0;
        if let Some(v) = self.unit_tag {
            my_size += ::protobuf::rt::value_size(1, v, ::protobuf::wire_format::WireTypeVarint);
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
        self.cached_size.set(my_size);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        if let Some(v) = self.unit_tag {
            os.write_uint64(1, v)?;
        }
        os.write_unknown_fields(self.get_unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn get_cached_size(&self) -> u32 {
        self.cached_size.get()
    }

    fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
        &self.unknown_fields
    }

    fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
        &mut self.unknown_fields
    }

    fn as_any(&self) -> &dyn (::std::any::Any) {
        self as &dyn (::std::any::Any)
    }
    fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
        self as &mut dyn (::std::any::Any)
    }
    fn into_any(self: ::std::boxed::Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
        self
    }

    fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
        Self::descriptor_static()
    }

    fn new() -> RequestQueryAvailableAbilities {
        RequestQueryAvailableAbilities::new()
    }

    fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::LazyV2::INIT;
        descriptor.get(|| {
            let mut fields = ::std::vec::Vec::new();
            fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
                "unit_tag",
                |m: &RequestQueryAvailableAbilities| { &m.unit_tag },
                |m: &mut RequestQueryAvailableAbilities| { &mut m.unit_tag },
            ));
            ::protobuf::reflect::MessageDescriptor::new_pb_name::<RequestQueryAvailableAbilities>(
                "RequestQueryAvailableAbilities",
                fields,
                file_descriptor_proto()
            )
        })
    }

    fn default_instance() -> &'static RequestQueryAvailableAbilities {
        static instance: ::protobuf::rt::LazyV2<RequestQueryAvailableAbilities> = ::protobuf::rt::LazyV2::INIT;
        instance.get(RequestQueryAvailableAbilities::new)
    }
}

impl ::protobuf::Clear for RequestQueryAvailableAbilities {
    fn clear(&mut self) {
        self.unit_tag = ::std::option::Option::None;
        self.unknown_fields.clear();
    }
}

impl ::std::fmt::Debug for RequestQueryAvailableAbilities {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for RequestQueryAvailableAbilities {
    fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
        ::protobuf::reflect::ReflectValueRef::Message(self)
    }
}

#[derive(PartialEq,Clone,Default)]
pub struct ResponseQueryAvailableAbilities {
    // message fields
    pub abilities: ::protobuf::RepeatedField<super::common::AvailableAbility>,
    pub unit_tag: ::std::option::Option<u64>,
    pub unit_type_id: ::std::option::Option<u32>,
    // special fields
    pub unknown_fields: ::protobuf::UnknownFields,
    pub cached_size: ::protobuf::CachedSize,
}

impl<'a> ::std::default::Default for &'a ResponseQueryAvailableAbilities {
    fn default() -> &'a ResponseQueryAvailableAbilities {
        <ResponseQueryAvailableAbilities as ::protobuf::Message>::default_instance()
    }
}

impl ResponseQueryAvailableAbilities {
    pub fn new() -> ResponseQueryAvailableAbilities {
        ::std::default::Default::default()
    }

    // repeated .SC2APIProtocol.AvailableAbility abilities = 1;


    pub fn get_abilities(&self) -> &[super::common::AvailableAbility] {
        &self.abilities
    }
    pub fn clear_abilities(&mut self) {
        self.abilities.clear();
    }

    // Param is passed by value, moved
    pub fn set_abilities(&mut self, v: ::protobuf::RepeatedField<super::common::AvailableAbility>) {
        self.abilities = v;
    }

    // Mutable pointer to the field.
    pub fn mut_abilities(&mut self) -> &mut ::protobuf::RepeatedField<super::common::AvailableAbility> {
        &mut self.abilities
    }

    // Take field
    pub fn take_abilities(&mut self) -> ::protobuf::RepeatedField<super::common::AvailableAbility> {
        ::std::mem::replace(&mut self.abilities, ::protobuf::RepeatedField::new())
    }

    // optional uint64 unit_tag = 2;


    pub fn get_unit_tag(&self) -> u64 {
        self.unit_tag.unwrap_or(0)
    }
    pub fn clear_unit_tag(&mut self) {
        self.unit_tag = ::std::option::Option::None;
    }

    pub fn has_unit_tag(&self) -> bool {
        self.unit_tag.is_some()
    }

    // Param is passed by value, moved
    pub fn set_unit_tag(&mut self, v: u64) {
        self.unit_tag = ::std::option::Option::Some(v);
    }

    // optional uint32 unit_type_id = 3;


    pub fn get_unit_type_id(&self) -> u32 {
        self.unit_type_id.unwrap_or(0)
    }
    pub fn clear_unit_type_id(&mut self) {
        self.unit_type_id = ::std::option::Option::None;
    }

    pub fn has_unit_type_id(&self) -> bool {
        self.unit_type_id.is_some()
    }

    // Param is passed by value, moved
    pub fn set_unit_type_id(&mut self, v: u32) {
        self.unit_type_id = ::std::option::Option::Some(v);
    }
}

impl ::protobuf::Message for ResponseQueryAvailableAbilities {
    fn is_initialized(&self) -> bool {
        for v in &self.abilities {
            if !v.is_initialized() {
                return false;
            }
        };
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        while !is.eof()? {
            let (field_number, wire_type) = is.read_tag_unpack()?;
            match field_number {
                1 => {
                    ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.abilities)?;
                },
                2 => {
                    if wire_type != ::protobuf::wire_format::WireTypeVarint {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    let tmp = is.read_uint64()?;
                    self.unit_tag = ::std::option::Option::Some(tmp);
                },
                3 => {
                    if wire_type != ::protobuf::wire_format::WireTypeVarint {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    let tmp = is.read_uint32()?;
                    self.unit_type_id = ::std::option::Option::Some(tmp);
                },
                _ => {
                    ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u32 {
        let mut my_size = 0;
        for value in &self.abilities {
            let len = value.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        };
        if let Some(v) = self.unit_tag {
            my_size += ::protobuf::rt::value_size(2, v, ::protobuf::wire_format::WireTypeVarint);
        }
        if let Some(v) = self.unit_type_id {
            my_size += ::protobuf::rt::value_size(3, v, ::protobuf::wire_format::WireTypeVarint);
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
        self.cached_size.set(my_size);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        for v in &self.abilities {
            os.write_tag(1, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        };
        if let Some(v) = self.unit_tag {
            os.write_uint64(2, v)?;
        }
        if let Some(v) = self.unit_type_id {
            os.write_uint32(3, v)?;
        }
        os.write_unknown_fields(self.get_unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn get_cached_size(&self) -> u32 {
        self.cached_size.get()
    }

    fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
        &self.unknown_fields
    }

    fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
        &mut self.unknown_fields
    }

    fn as_any(&self) -> &dyn (::std::any::Any) {
        self as &dyn (::std::any::Any)
    }
    fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
        self as &mut dyn (::std::any::Any)
    }
    fn into_any(self: ::std::boxed::Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
        self
    }

    fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
        Self::descriptor_static()
    }

    fn new() -> ResponseQueryAvailableAbilities {
        ResponseQueryAvailableAbilities::new()
    }

    fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::LazyV2::INIT;
        descriptor.get(|| {
            let mut fields = ::std::vec::Vec::new();
            fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::common::AvailableAbility>>(
                "abilities",
                |m: &ResponseQueryAvailableAbilities| { &m.abilities },
                |m: &mut ResponseQueryAvailableAbilities| { &mut m.abilities },
            ));
            fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
                "unit_tag",
                |m: &ResponseQueryAvailableAbilities| { &m.unit_tag },
                |m: &mut ResponseQueryAvailableAbilities| { &mut m.unit_tag },
            ));
            fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint32>(
                "unit_type_id",
                |m: &ResponseQueryAvailableAbilities| { &m.unit_type_id },
                |m: &mut ResponseQueryAvailableAbilities| { &mut m.unit_type_id },
            ));
            ::protobuf::reflect::MessageDescriptor::new_pb_name::<ResponseQueryAvailableAbilities>(
                "ResponseQueryAvailableAbilities",
                fields,
                file_descriptor_proto()
            )
        })
    }

    fn default_instance() -> &'static ResponseQueryAvailableAbilities {
        static instance: ::protobuf::rt::LazyV2<ResponseQueryAvailableAbilities> = ::protobuf::rt::LazyV2::INIT;
        instance.get(ResponseQueryAvailableAbilities::new)
    }
}

impl ::protobuf::Clear for ResponseQueryAvailableAbilities {
    fn clear(&mut self) {
        self.abilities.clear();
        self.unit_tag = ::std::option::Option::None;
        self.unit_type_id = ::std::option::Option::None;
        self.unknown_fields.clear();
    }
}

impl ::std::fmt::Debug for ResponseQueryAvailableAbilities {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for ResponseQueryAvailableAbilities {
    fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
        ::protobuf::reflect::ReflectValueRef::Message(self)
    }
}

#[derive(PartialEq,Clone,Default)]
pub struct RequestQueryBuildingPlacement {
    // message fields
    pub ability_id: ::std::option::Option<i32>,
    pub target_pos: ::protobuf::SingularPtrField<super::common::Point2D>,
    pub placing_unit_tag: ::std::option::Option<u64>,
    // special fields
    pub unknown_fields: ::protobuf::UnknownFields,
    pub cached_size: ::protobuf::CachedSize,
}

impl<'a> ::std::default::Default for &'a RequestQueryBuildingPlacement {
    fn default() -> &'a RequestQueryBuildingPlacement {
        <RequestQueryBuildingPlacement as ::protobuf::Message>::default_instance()
    }
}

impl RequestQueryBuildingPlacement {
    pub fn new() -> RequestQueryBuildingPlacement {
        ::std::default::Default::default()
    }

    // optional int32 ability_id = 1;


    pub fn get_ability_id(&self) -> i32 {
        self.ability_id.unwrap_or(0)
    }
    pub fn clear_ability_id(&mut self) {
        self.ability_id = ::std::option::Option::None;
    }

    pub fn has_ability_id(&self) -> bool {
        self.ability_id.is_some()
    }

    // Param is passed by value, moved
    pub fn set_ability_id(&mut self, v: i32) {
        self.ability_id = ::std::option::Option::Some(v);
    }

    // optional .SC2APIProtocol.Point2D target_pos = 2;


    pub fn get_target_pos(&self) -> &super::common::Point2D {
        self.target_pos.as_ref().unwrap_or_else(|| <super::common::Point2D as ::protobuf::Message>::default_instance())
    }
    pub fn clear_target_pos(&mut self) {
        self.target_pos.clear();
    }

    pub fn has_target_pos(&self) -> bool {
        self.target_pos.is_some()
    }

    // Param is passed by value, moved
    pub fn set_target_pos(&mut self, v: super::common::Point2D) {
        self.target_pos = ::protobuf::SingularPtrField::some(v);
    }

    // Mutable pointer to the field.
    // If field is not initialized, it is initialized with default value first.
    pub fn mut_target_pos(&mut self) -> &mut super::common::Point2D {
        if self.target_pos.is_none() {
            self.target_pos.set_default();
        }
        self.target_pos.as_mut().unwrap()
    }

    // Take field
    pub fn take_target_pos(&mut self) -> super::common::Point2D {
        self.target_pos.take().unwrap_or_else(|| super::common::Point2D::new())
    }

    // optional uint64 placing_unit_tag = 3;


    pub fn get_placing_unit_tag(&self) -> u64 {
        self.placing_unit_tag.unwrap_or(0)
    }
    pub fn clear_placing_unit_tag(&mut self) {
        self.placing_unit_tag = ::std::option::Option::None;
    }

    pub fn has_placing_unit_tag(&self) -> bool {
        self.placing_unit_tag.is_some()
    }

    // Param is passed by value, moved
    pub fn set_placing_unit_tag(&mut self, v: u64) {
        self.placing_unit_tag = ::std::option::Option::Some(v);
    }
}

impl ::protobuf::Message for RequestQueryBuildingPlacement {
    fn is_initialized(&self) -> bool {
        for v in &self.target_pos {
            if !v.is_initialized() {
                return false;
            }
        };
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        while !is.eof()? {
            let (field_number, wire_type) = is.read_tag_unpack()?;
            match field_number {
                1 => {
                    if wire_type != ::protobuf::wire_format::WireTypeVarint {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    let tmp = is.read_int32()?;
                    self.ability_id = ::std::option::Option::Some(tmp);
                },
                2 => {
                    ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.target_pos)?;
                },
                3 => {
                    if wire_type != ::protobuf::wire_format::WireTypeVarint {
                        return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
                    }
                    let tmp = is.read_uint64()?;
                    self.placing_unit_tag = ::std::option::Option::Some(tmp);
                },
                _ => {
                    ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u32 {
        let mut my_size = 0;
        if let Some(v) = self.ability_id {
            my_size += ::protobuf::rt::value_size(1, v, ::protobuf::wire_format::WireTypeVarint);
        }
        if let Some(ref v) = self.target_pos.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
        }
        if let Some(v) = self.placing_unit_tag {
            my_size += ::protobuf::rt::value_size(3, v, ::protobuf::wire_format::WireTypeVarint);
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
        self.cached_size.set(my_size);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        if let Some(v) = self.ability_id {
            os.write_int32(1, v)?;
        }
        if let Some(ref v) = self.target_pos.as_ref() {
            os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
            os.write_raw_varint32(v.get_cached_size())?;
            v.write_to_with_cached_sizes(os)?;
        }
        if let Some(v) = self.placing_unit_tag {
            os.write_uint64(3, v)?;
        }
        os.write_unknown_fields(self.get_unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn get_cached_size(&self) -> u32 {
        self.cached_size.get()
    }

    fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
        &self.unknown_fields
    }

    fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
        &mut self.unknown_fields
    }

    fn as_any(&self) -> &dyn (::std::any::Any) {
        self as &dyn (::std::any::Any)
    }
    fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
        self as &mut dyn (::std::any::Any)
    }
    fn into_any(self: ::std::boxed::Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
        self
    }

    fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
        Self::descriptor_static()
    }

    fn new() -> RequestQueryBuildingPlacement {
        RequestQueryBuildingPlacement::new()
    }

    fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::LazyV2::INIT;
        descriptor.get(|| {
            let mut fields = ::std::vec::Vec::new();
            fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeInt32>(
                "ability_id",
                |m: &RequestQueryBuildingPlacement| { &m.ability_id },
                |m: &mut RequestQueryBuildingPlacement| { &mut m.ability_id },
            ));
            fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::common::Point2D>>(
                "target_pos",
                |m: &RequestQueryBuildingPlacement| { &m.target_pos },
                |m: &mut RequestQueryBuildingPlacement| { &mut m.target_pos },
            ));
            fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeUint64>(
                "placing_unit_tag",
                |m: &RequestQueryBuildingPlacement| { &m.placing_unit_tag },
                |m: &mut RequestQueryBuildingPlacement| { &mut m.placing_unit_tag },
            ));
            ::protobuf::reflect::MessageDescriptor::new_pb_name::<RequestQueryBuildingPlacement>(
                "RequestQueryBuildingPlacement",
                fields,
                file_descriptor_proto()
            )
        })
    }

    fn default_instance() -> &'static RequestQueryBuildingPlacement {
        static instance: ::protobuf::rt::LazyV2<RequestQueryBuildingPlacement> = ::protobuf::rt::LazyV2::INIT;
        instance.get(RequestQueryBuildingPlacement::new)
    }
}

impl ::protobuf::Clear for RequestQueryBuildingPlacement {
    fn clear(&mut self) {
        self.ability_id = ::std::option::Option::None;
        self.target_pos.clear();
        self.placing_unit_tag = ::std::option::Option::None;
        self.unknown_fields.clear();
    }
}

impl ::std::fmt::Debug for RequestQueryBuildingPlacement {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for RequestQueryBuildingPlacement {
    fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
        ::protobuf::reflect::ReflectValueRef::Message(self)
    }
}

#[derive(PartialEq,Clone,Default)]
pub struct ResponseQueryBuildingPlacement {
    // message fields
    pub result: ::std::option::Option<super::error::ActionResult>,
    // special fields
    pub unknown_fields: ::protobuf::UnknownFields,
    pub cached_size: ::protobuf::CachedSize,
}

impl<'a> ::std::default::Default for &'a ResponseQueryBuildingPlacement {
    fn default() -> &'a ResponseQueryBuildingPlacement {
        <ResponseQueryBuildingPlacement as ::protobuf::Message>::default_instance()
    }
}

impl ResponseQueryBuildingPlacement {
    pub fn new() -> ResponseQueryBuildingPlacement {
        ::std::default::Default::default()
    }

    // optional .SC2APIProtocol.ActionResult result = 1;


    pub fn get_result(&self) -> super::error::ActionResult {
        self.result.unwrap_or(super::error::ActionResult::Success)
    }
    pub fn clear_result(&mut self) {
        self.result = ::std::option::Option::None;
    }

    pub fn has_result(&self) -> bool {
        self.result.is_some()
    }

    // Param is passed by value, moved
    pub fn set_result(&mut self, v: super::error::ActionResult) {
        self.result = ::std::option::Option::Some(v);
    }
}

impl ::protobuf::Message for ResponseQueryBuildingPlacement {
    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        while !is.eof()? {
            let (field_number, wire_type) = is.read_tag_unpack()?;
            match field_number {
                1 => {
                    ::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.result, 1, &mut self.unknown_fields)?
                },
                _ => {
                    ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u32 {
        let mut my_size = 0;
        if let Some(v) = self.result {
            my_size += ::protobuf::rt::enum_size(1, v);
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
        self.cached_size.set(my_size);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::ProtobufResult<()> {
        if let Some(v) = self.result {
            os.write_enum(1, ::protobuf::ProtobufEnum::value(&v))?;
        }
        os.write_unknown_fields(self.get_unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn get_cached_size(&self) -> u32 {
        self.cached_size.get()
    }

    fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
        &self.unknown_fields
    }

    fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
        &mut self.unknown_fields
    }

    fn as_any(&self) -> &dyn (::std::any::Any) {
        self as &dyn (::std::any::Any)
    }
    fn as_any_mut(&mut self) -> &mut dyn (::std::any::Any) {
        self as &mut dyn (::std::any::Any)
    }
    fn into_any(self: ::std::boxed::Box<Self>) -> ::std::boxed::Box<dyn (::std::any::Any)> {
        self
    }

    fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
        Self::descriptor_static()
    }

    fn new() -> ResponseQueryBuildingPlacement {
        ResponseQueryBuildingPlacement::new()
    }

    fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::LazyV2<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::LazyV2::INIT;
        descriptor.get(|| {
            let mut fields = ::std::vec::Vec::new();
            fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<super::error::ActionResult>>(
                "result",
                |m: &ResponseQueryBuildingPlacement| { &m.result },
                |m: &mut ResponseQueryBuildingPlacement| { &mut m.result },
            ));
            ::protobuf::reflect::MessageDescriptor::new_pb_name::<ResponseQueryBuildingPlacement>(
                "ResponseQueryBuildingPlacement",
                fields,
                file_descriptor_proto()
            )
        })
    }

    fn default_instance() -> &'static ResponseQueryBuildingPlacement {
        static instance: ::protobuf::rt::LazyV2<ResponseQueryBuildingPlacement> = ::protobuf::rt::LazyV2::INIT;
        instance.get(ResponseQueryBuildingPlacement::new)
    }
}

impl ::protobuf::Clear for ResponseQueryBuildingPlacement {
    fn clear(&mut self) {
        self.result = ::std::option::Option::None;
        self.unknown_fields.clear();
    }
}

impl ::std::fmt::Debug for ResponseQueryBuildingPlacement {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for ResponseQueryBuildingPlacement {
    fn as_ref(&self) -> ::protobuf::reflect::ReflectValueRef {
        ::protobuf::reflect::ReflectValueRef::Message(self)
    }
}

static file_descriptor_proto_data: &'static [u8] = b"\
    \n\x1cs2clientprotocol/query.proto\x12\x0eSC2APIProtocol\x1a\x1ds2client\
    protocol/common.proto\x1a\x1cs2clientprotocol/error.proto\"\xac\x02\n\
    \x0cRequestQuery\x12=\n\x07pathing\x18\x01\x20\x03(\x0b2#.SC2APIProtocol\
    .RequestQueryPathingR\x07pathing\x12L\n\tabilities\x18\x02\x20\x03(\x0b2\
    ..SC2APIProtocol.RequestQueryAvailableAbilitiesR\tabilities\x12M\n\nplac\
    ements\x18\x03\x20\x03(\x0b2-.SC2APIProtocol.RequestQueryBuildingPlaceme\
    ntR\nplacements\x12@\n\x1cignore_resource_requirements\x18\x04\x20\x01(\
    \x08R\x1aignoreResourceRequirements\"\xee\x01\n\rResponseQuery\x12>\n\
    \x07pathing\x18\x01\x20\x03(\x0b2$.SC2APIProtocol.ResponseQueryPathingR\
    \x07pathing\x12M\n\tabilities\x18\x02\x20\x03(\x0b2/.SC2APIProtocol.Resp\
    onseQueryAvailableAbilitiesR\tabilities\x12N\n\nplacements\x18\x03\x20\
    \x03(\x0b2..SC2APIProtocol.ResponseQueryBuildingPlacementR\nplacements\"\
    \xa5\x01\n\x13RequestQueryPathing\x126\n\tstart_pos\x18\x01\x20\x01(\x0b\
    2\x17.SC2APIProtocol.Point2DH\0R\x08startPos\x12\x1b\n\x08unit_tag\x18\
    \x02\x20\x01(\x04H\0R\x07unitTag\x120\n\x07end_pos\x18\x03\x20\x01(\x0b2\
    \x17.SC2APIProtocol.Point2DR\x06endPosB\x07\n\x05start\"2\n\x14ResponseQ\
    ueryPathing\x12\x1a\n\x08distance\x18\x01\x20\x01(\x02R\x08distance\";\n\
    \x1eRequestQueryAvailableAbilities\x12\x19\n\x08unit_tag\x18\x01\x20\x01\
    (\x04R\x07unitTag\"\x9e\x01\n\x1fResponseQueryAvailableAbilities\x12>\n\
    \tabilities\x18\x01\x20\x03(\x0b2\x20.SC2APIProtocol.AvailableAbilityR\t\
    abilities\x12\x19\n\x08unit_tag\x18\x02\x20\x01(\x04R\x07unitTag\x12\x20\
    \n\x0cunit_type_id\x18\x03\x20\x01(\rR\nunitTypeId\"\xa0\x01\n\x1dReques\
    tQueryBuildingPlacement\x12\x1d\n\nability_id\x18\x01\x20\x01(\x05R\tabi\
    lityId\x126\n\ntarget_pos\x18\x02\x20\x01(\x0b2\x17.SC2APIProtocol.Point\
    2DR\ttargetPos\x12(\n\x10placing_unit_tag\x18\x03\x20\x01(\x04R\x0eplaci\
    ngUnitTag\"V\n\x1eResponseQueryBuildingPlacement\x124\n\x06result\x18\
    \x01\x20\x01(\x0e2\x1c.SC2APIProtocol.ActionResultR\x06result\
";

static file_descriptor_proto_lazy: ::protobuf::rt::LazyV2<::protobuf::descriptor::FileDescriptorProto> = ::protobuf::rt::LazyV2::INIT;

fn parse_descriptor_proto() -> ::protobuf::descriptor::FileDescriptorProto {
    ::protobuf::Message::parse_from_bytes(file_descriptor_proto_data).unwrap()
}

pub fn file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto {
    file_descriptor_proto_lazy.get(|| {
        parse_descriptor_proto()
    })
}
