#[derive(serde::Serialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SidebarState {
#[prost(
enumeration = "super::proto::enums::ui_sidebar_mode::UiSidebarMode",
optional,
tag = "1"
)]
pub mode: ::core::option::Option<i32>,
#[prost(message, repeated, tag = "2")]
pub menu_items: ::prost::alloc::vec::Vec<MenuItem>,
#[prost(message, optional, tag = "3")]
pub build_selector: ::core::option::Option<BuildSelector>,
}
impl ::prost::Name for SidebarState {
const NAME: &'static str = "SidebarState";
const PACKAGE: &'static str = "DwarfControl";
fn full_name() -> ::prost::alloc::string::String {
"DwarfControl.SidebarState".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/DwarfControl.SidebarState".into()
}
}
#[derive(serde::Serialize)]
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct MenuItem {
#[prost(message, optional, tag = "1")]
pub building_type: ::core::option::Option<
super::remote_fortress_reader::BuildingType,
>,
#[prost(int32, optional, tag = "2")]
pub existing_count: ::core::option::Option<i32>,
#[prost(enumeration = "BuildCategory", optional, tag = "3")]
pub build_category: ::core::option::Option<i32>,
}
impl ::prost::Name for MenuItem {
const NAME: &'static str = "MenuItem";
const PACKAGE: &'static str = "DwarfControl";
fn full_name() -> ::prost::alloc::string::String {
"DwarfControl.MenuItem".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/DwarfControl.MenuItem".into()
}
}
#[derive(serde::Serialize)]
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct SidebarCommand {
#[prost(
enumeration = "super::proto::enums::ui_sidebar_mode::UiSidebarMode",
optional,
tag = "1"
)]
pub mode: ::core::option::Option<i32>,
#[prost(int32, optional, tag = "2")]
pub menu_index: ::core::option::Option<i32>,
#[prost(enumeration = "MenuAction", optional, tag = "3")]
pub action: ::core::option::Option<i32>,
#[prost(message, optional, tag = "4")]
pub selection_coord: ::core::option::Option<super::remote_fortress_reader::Coord>,
}
impl ::prost::Name for SidebarCommand {
const NAME: &'static str = "SidebarCommand";
const PACKAGE: &'static str = "DwarfControl";
fn full_name() -> ::prost::alloc::string::String {
"DwarfControl.SidebarCommand".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/DwarfControl.SidebarCommand".into()
}
}
#[derive(serde::Serialize)]
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct BuiildReqChoice {
#[prost(int32, optional, tag = "1")]
pub distance: ::core::option::Option<i32>,
#[prost(string, optional, tag = "2")]
pub name: ::core::option::Option<::prost::alloc::string::String>,
#[prost(int32, optional, tag = "3")]
pub num_candidates: ::core::option::Option<i32>,
#[prost(int32, optional, tag = "4")]
pub used_count: ::core::option::Option<i32>,
}
impl ::prost::Name for BuiildReqChoice {
const NAME: &'static str = "BuiildReqChoice";
const PACKAGE: &'static str = "DwarfControl";
fn full_name() -> ::prost::alloc::string::String {
"DwarfControl.BuiildReqChoice".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/DwarfControl.BuiildReqChoice".into()
}
}
#[derive(serde::Serialize)]
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct BuildItemReq {
#[prost(int32, optional, tag = "2")]
pub count_required: ::core::option::Option<i32>,
#[prost(int32, optional, tag = "3")]
pub count_max: ::core::option::Option<i32>,
#[prost(int32, optional, tag = "4")]
pub count_provided: ::core::option::Option<i32>,
}
impl ::prost::Name for BuildItemReq {
const NAME: &'static str = "BuildItemReq";
const PACKAGE: &'static str = "DwarfControl";
fn full_name() -> ::prost::alloc::string::String {
"DwarfControl.BuildItemReq".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/DwarfControl.BuildItemReq".into()
}
}
#[derive(serde::Serialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct BuildSelector {
#[prost(message, optional, tag = "1")]
pub building_type: ::core::option::Option<
super::remote_fortress_reader::BuildingType,
>,
#[prost(enumeration = "BuildSelectorStage", optional, tag = "2")]
pub stage: ::core::option::Option<i32>,
#[prost(message, repeated, tag = "3")]
pub choices: ::prost::alloc::vec::Vec<BuiildReqChoice>,
#[prost(int32, optional, tag = "4")]
pub sel_index: ::core::option::Option<i32>,
#[prost(message, repeated, tag = "5")]
pub requirements: ::prost::alloc::vec::Vec<BuildItemReq>,
#[prost(int32, optional, tag = "6")]
pub req_index: ::core::option::Option<i32>,
#[prost(string, repeated, tag = "7")]
pub errors: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
#[prost(int32, optional, tag = "8")]
pub radius_x_low: ::core::option::Option<i32>,
#[prost(int32, optional, tag = "9")]
pub radius_y_low: ::core::option::Option<i32>,
#[prost(int32, optional, tag = "10")]
pub radius_x_high: ::core::option::Option<i32>,
#[prost(int32, optional, tag = "11")]
pub radius_y_high: ::core::option::Option<i32>,
#[prost(message, optional, tag = "12")]
pub cursor: ::core::option::Option<super::remote_fortress_reader::Coord>,
#[prost(int32, repeated, packed = "false", tag = "13")]
pub tiles: ::prost::alloc::vec::Vec<i32>,
}
impl ::prost::Name for BuildSelector {
const NAME: &'static str = "BuildSelector";
const PACKAGE: &'static str = "DwarfControl";
fn full_name() -> ::prost::alloc::string::String {
"DwarfControl.BuildSelector".into()
}
fn type_url() -> ::prost::alloc::string::String {
"/DwarfControl.BuildSelector".into()
}
}
#[derive(serde::Serialize)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum BuildCategory {
NotCategory = 0,
SiegeEngines = 1,
Traps = 2,
Workshops = 3,
Furnaces = 4,
Constructions = 5,
MachineComponents = 6,
Track = 7,
}
impl BuildCategory {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::NotCategory => "NotCategory",
Self::SiegeEngines => "SiegeEngines",
Self::Traps => "Traps",
Self::Workshops => "Workshops",
Self::Furnaces => "Furnaces",
Self::Constructions => "Constructions",
Self::MachineComponents => "MachineComponents",
Self::Track => "Track",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"NotCategory" => Some(Self::NotCategory),
"SiegeEngines" => Some(Self::SiegeEngines),
"Traps" => Some(Self::Traps),
"Workshops" => Some(Self::Workshops),
"Furnaces" => Some(Self::Furnaces),
"Constructions" => Some(Self::Constructions),
"MachineComponents" => Some(Self::MachineComponents),
"Track" => Some(Self::Track),
_ => None,
}
}
}
#[derive(serde::Serialize)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum MenuAction {
MenuNone = 0,
MenuSelect = 1,
MenuCancel = 2,
MenuSelectAll = 3,
}
impl MenuAction {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::MenuNone => "MenuNone",
Self::MenuSelect => "MenuSelect",
Self::MenuCancel => "MenuCancel",
Self::MenuSelectAll => "MenuSelectAll",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"MenuNone" => Some(Self::MenuNone),
"MenuSelect" => Some(Self::MenuSelect),
"MenuCancel" => Some(Self::MenuCancel),
"MenuSelectAll" => Some(Self::MenuSelectAll),
_ => None,
}
}
}
#[derive(serde::Serialize)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum BuildSelectorStage {
StageNoMat = 0,
StagePlace = 1,
StageItemSelect = 2,
}
impl BuildSelectorStage {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::StageNoMat => "StageNoMat",
Self::StagePlace => "StagePlace",
Self::StageItemSelect => "StageItemSelect",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"StageNoMat" => Some(Self::StageNoMat),
"StagePlace" => Some(Self::StagePlace),
"StageItemSelect" => Some(Self::StageItemSelect),
_ => None,
}
}
}