Skip to main content

engage/generated/app/
mapactor.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "app-mapactor-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8    use crate::system::{
9        object::{IObject, Object},
10        r#enum::{Enum, IEnum},
11        valuetype::{IValueType, ValueType},
12    };
13
14    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/app/mapactor/MapActor.md"))]
15    #[::unity::class(namespace = "App", name = "MapActor")]
16    #[parent(crate::system::object::Object)]
17    pub struct MapActor {
18        #[static_field]
19        #[rename(name = "MoveTime")]
20        pub move_time: f32,
21        #[static_field]
22        #[rename(name = "StickMargin")]
23        pub stick_margin: f32,
24    }
25
26    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/app/mapactor/MapActor_MoveResult.md"))]
27    #[repr(C)]
28    #[derive(::core::clone::Clone, ::core::marker::Copy, ::core::fmt::Debug, ::core::cmp::PartialEq, ::core::cmp::Eq)]
29    pub struct MapActor_MoveResult {
30        pub value: i32,
31    }
32    impl ::unity::ClassIdentity for MapActor_MoveResult {
33        const NAME: &'static str = "MapActor.MoveResult";
34        const NAMESPACE: &'static str = "App";
35
36        fn class() -> ::unity::Class {
37            static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
38            *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
39        }
40    }
41    impl ::unity::IlType for MapActor_MoveResult {
42        fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
43            &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
44        }
45    }
46    impl MapActor_MoveResult {
47        pub fn none() -> Self {
48            Self { value: 0 }
49        }
50
51        pub fn r#move() -> Self {
52            Self { value: 1 }
53        }
54
55        pub fn hit() -> Self {
56            Self { value: 2 }
57        }
58    }
59}
60
61#[cfg(feature = "app-mapactor-types")]
62pub use __types::*;
63
64#[cfg(feature = "app-mapactor")]
65impl MapActor {
66    #[doc = "`IsInvasion(i32, i32, i32, i32)` overload"]
67    pub fn is_invasion(
68        ox: impl ::core::convert::Into<i32>,
69        oz: impl ::core::convert::Into<i32>,
70        nx: impl ::core::convert::Into<i32>,
71        nz: impl ::core::convert::Into<i32>,
72    ) -> bool {
73        unsafe {
74            ::unity::il2cpp_call!((::unity::module_base()+0x1ef8930usize)as*mut u8,bool;
75(i32)::core::convert::Into::into(ox),(i32)::core::convert::Into::into(oz),(i32)::core::convert::Into::into(nx),(i32)::core::convert::Into::into(nz))
76        }
77    }
78
79    #[doc = "`IsDiagonallyDir(i32, i32, i32, i32)` overload"]
80    pub fn is_diagonally_dir(
81        ox: impl ::core::convert::Into<i32>,
82        oz: impl ::core::convert::Into<i32>,
83        nx: impl ::core::convert::Into<i32>,
84        nz: impl ::core::convert::Into<i32>,
85    ) -> bool {
86        unsafe {
87            ::unity::il2cpp_call!((::unity::module_base()+0x1ef8af0usize)as*mut u8,bool;
88(i32)::core::convert::Into::into(ox),(i32)::core::convert::Into::into(oz),(i32)::core::convert::Into::into(nx),(i32)::core::convert::Into::into(nz))
89        }
90    }
91
92    #[doc = "`IsConnect(i32, i32, crate::app::dir_2::Dir_Type)` overload"]
93    pub fn is_connect(
94        x: impl ::core::convert::Into<i32>,
95        z: impl ::core::convert::Into<i32>,
96        dir: impl ::core::convert::Into<crate::app::dir_2::Dir_Type>,
97    ) -> bool {
98        unsafe {
99            ::unity::il2cpp_call!((::unity::module_base()+0x1ef9120usize)as*mut u8,bool;
100(i32)::core::convert::Into::into(x),(i32)::core::convert::Into::into(z),(crate::app::dir_2::Dir_Type)::core::convert::Into::into(dir))
101        }
102    }
103
104    #[doc = "`Extrusion(crate::unity_engine::vector3::Vector3, f32)` overload"]
105    pub fn extrusion(
106        pos: impl ::core::convert::Into<crate::unity_engine::vector3::Vector3>,
107        radius: impl ::core::convert::Into<f32>,
108    ) -> crate::unity_engine::vector3::Vector3 {
109        unsafe {
110            ::unity::il2cpp_call!((::unity::module_base()+0x1efa000usize)as*mut u8,crate::unity_engine::vector3::Vector3;
111(crate::unity_engine::vector3::Vector3)::core::convert::Into::into(pos),(f32)::core::convert::Into::into(radius))
112        }
113    }
114
115    #[doc = "`TickMove(crate::app::unit::Unit)` overload"]
116    pub fn tick_move(unit: impl ::core::convert::Into<crate::app::unit::Unit>) -> crate::app::mapactor::MapActor_MoveResult {
117        unsafe {
118            ::unity::il2cpp_call!((::unity::module_base()+0x1efa620usize)as*mut u8,crate::app::mapactor::MapActor_MoveResult;
119(crate::app::unit::Unit)::core::convert::Into::into(unit))
120        }
121    }
122}
123
124#[cfg(feature = "app-mapactor")]
125pub trait IMapActorMethods: IMapActor {
126    #[doc = "`.ctor()` overload"]
127    fn ctor(self) -> () {
128        unsafe {
129            let __receiver = <MapActor as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
130            ::unity::il2cpp_call!((::unity::module_base()+0x1efb2a0usize)as*mut u8,();
131(MapActor)__receiver)
132        }
133    }
134}
135
136#[cfg(feature = "app-mapactor")]
137impl<__T: IMapActor> IMapActorMethods for __T {}
138
139#[cfg(feature = "app-mapactor")]
140impl MapActor {
141    pub fn is_invasion_method_info() -> &'static ::unity::il2cpp::MethodInfo {
142        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
143    }
144
145    pub fn is_diagonally_dir_method_info() -> &'static ::unity::il2cpp::MethodInfo {
146        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
147    }
148
149    pub fn is_connect_method_info() -> &'static ::unity::il2cpp::MethodInfo {
150        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
151    }
152
153    pub fn extrusion_method_info() -> &'static ::unity::il2cpp::MethodInfo {
154        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
155    }
156
157    pub fn tick_move_method_info() -> &'static ::unity::il2cpp::MethodInfo {
158        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
159    }
160
161    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
162        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
163    }
164}
165
166#[cfg(feature = "app-mapactor")]
167impl MapActor {
168    #[doc = "`.ctor()` — no args"]
169    pub fn new() -> Self {
170        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
171            panic!(
172                "{}
173::{}
174 failed to instantiate",
175                ::core::stringify!(MapActor),
176                ::core::stringify!(new),
177            )
178        });
179        <Self as IMapActorMethods>::ctor(this);
180        this
181    }
182}
183
184#[cfg(feature = "app-mapactor")]
185#[doc(hidden)]
186pub mod prelude {
187    pub use super::{IMapActor, IMapActorMethods, MapActor, MapActor_MoveResult};
188    #[cfg(feature = "system-object")]
189    pub use crate::system::object::IObjectMethods;
190    #[cfg(feature = "system-enum")]
191    pub use crate::system::r#enum::IEnumMethods;
192    #[cfg(feature = "system-valuetype")]
193    pub use crate::system::valuetype::IValueTypeMethods;
194    pub use crate::system::{object::IObject, r#enum::IEnum, valuetype::IValueType};
195}