Skip to main content

engage/generated/app/
cannoninspector.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "app-cannoninspector-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8    use crate::{
9        app::{
10            mapinspector::{IMapInspector, MapInspector},
11            scriptutil::{IScriptUtil, ScriptUtil},
12        },
13        system::object::{IObject, Object},
14    };
15
16    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/app/cannoninspector/CannonInspector.md"))]
17    #[::unity::class(namespace = "App", name = "CannonInspector")]
18    #[parent(crate::app::mapinspector::MapInspector)]
19    pub struct CannonInspector {
20        #[static_field]
21        #[rename(name = "Version")]
22        pub version: i32,
23        #[offset(48)]
24        #[rename(name = "m_X")]
25        pub m_x: i32,
26        #[offset(52)]
27        #[rename(name = "m_Z")]
28        pub m_z: i32,
29        #[offset(56)]
30        #[rename(name = "m_MaxShells")]
31        pub m_max_shells: i32,
32        #[offset(64)]
33        #[rename(name = "m_KeyShells")]
34        pub m_key_shells: ::unity::Il2CppString,
35    }
36}
37
38#[cfg(feature = "app-cannoninspector-types")]
39pub use __types::*;
40
41#[cfg(feature = "app-cannoninspector")]
42pub trait ICannonInspectorMethods: ICannonInspector {
43    #[doc = "`.ctor(i32, i32, i32)` overload"]
44    fn ctor(self, x: impl ::core::convert::Into<i32>, z: impl ::core::convert::Into<i32>, max_shells: impl ::core::convert::Into<i32>) -> () {
45        unsafe {
46            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
47            ::unity::il2cpp_call!((::unity::module_base()+0x25bacf0usize)as*mut u8,();
48(CannonInspector)__receiver,(i32)::core::convert::Into::into(x),(i32)::core::convert::Into::into(z),(i32)::core::convert::Into::into(max_shells))
49        }
50    }
51    #[doc = "`IsEanble()` overload"]
52    fn is_eanble(self) -> bool {
53        unsafe {
54            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
55            {
56                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
57                let __vi = *__vt.get(5usize).unwrap_or_else(|| {
58                    panic!(
59                        "unity: virtual slot {}
60 out of range (vtable len {}
61) on the runtime class behind {}
62 (method `{}
63`)",
64                        5usize,
65                        __vt.len(),
66                        <CannonInspector as ::unity::ClassIdentity>::NAME,
67                        "IsEanble",
68                    )
69                });
70                let __inner: extern "C" fn(CannonInspector, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
71                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
72                __inner(__receiver, __mi)
73            }
74        }
75    }
76    #[doc = "`Completed()` overload"]
77    fn completed(self) -> () {
78        unsafe {
79            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
80            {
81                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
82                let __vi = *__vt.get(4usize).unwrap_or_else(|| {
83                    panic!(
84                        "unity: virtual slot {}
85 out of range (vtable len {}
86) on the runtime class behind {}
87 (method `{}
88`)",
89                        4usize,
90                        __vt.len(),
91                        <CannonInspector as ::unity::ClassIdentity>::NAME,
92                        "Completed",
93                    )
94                });
95                let __inner: extern "C" fn(CannonInspector, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
96                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
97                __inner(__receiver, __mi)
98            }
99        }
100    }
101    #[doc = "`get_X()` overload"]
102    fn get_x(self) -> i32 {
103        unsafe {
104            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
105            {
106                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
107                let __vi = *__vt.get(12usize).unwrap_or_else(|| {
108                    panic!(
109                        "unity: virtual slot {}
110 out of range (vtable len {}
111) on the runtime class behind {}
112 (method `{}
113`)",
114                        12usize,
115                        __vt.len(),
116                        <CannonInspector as ::unity::ClassIdentity>::NAME,
117                        "get_X",
118                    )
119                });
120                let __inner: extern "C" fn(CannonInspector, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__vi.method_ptr);
121                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
122                __inner(__receiver, __mi)
123            }
124        }
125    }
126    #[doc = "`get_Z()` overload"]
127    fn get_z(self) -> i32 {
128        unsafe {
129            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
130            {
131                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
132                let __vi = *__vt.get(13usize).unwrap_or_else(|| {
133                    panic!(
134                        "unity: virtual slot {}
135 out of range (vtable len {}
136) on the runtime class behind {}
137 (method `{}
138`)",
139                        13usize,
140                        __vt.len(),
141                        <CannonInspector as ::unity::ClassIdentity>::NAME,
142                        "get_Z",
143                    )
144                });
145                let __inner: extern "C" fn(CannonInspector, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__vi.method_ptr);
146                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
147                __inner(__receiver, __mi)
148            }
149        }
150    }
151    #[doc = "`GetMaxShells()` overload"]
152    fn get_max_shells(self) -> i32 {
153        unsafe {
154            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
155            ::unity::il2cpp_call!((::unity::module_base()+0x25bafe0usize)as*mut u8,i32;
156(CannonInspector)__receiver)
157        }
158    }
159    #[doc = "`SetShells(i32)` overload"]
160    fn set_shells(self, num: impl ::core::convert::Into<i32>) -> () {
161        unsafe {
162            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
163            ::unity::il2cpp_call!((::unity::module_base()+0x25baff0usize)as*mut u8,();
164(CannonInspector)__receiver,(i32)::core::convert::Into::into(num))
165        }
166    }
167    #[doc = "`GetShells()` overload"]
168    fn get_shells(self) -> i32 {
169        unsafe {
170            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
171            ::unity::il2cpp_call!((::unity::module_base()+0x25bb1c0usize)as*mut u8,i32;
172(CannonInspector)__receiver)
173        }
174    }
175    #[doc = "`DecreaseShell()` overload"]
176    fn decrease_shell(self) -> () {
177        unsafe {
178            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
179            ::unity::il2cpp_call!((::unity::module_base()+0x25bb2a0usize)as*mut u8,();
180(CannonInspector)__receiver)
181        }
182    }
183    #[doc = "`GetCannonSkill(bool)` overload"]
184    fn get_cannon_skill(self, is_force: impl ::core::convert::Into<bool>) -> crate::app::skilldata::SkillData {
185        unsafe {
186            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
187            ::unity::il2cpp_call!((::unity::module_base()+0x25bb2e0usize)as*mut u8,crate::app::skilldata::SkillData;
188(CannonInspector)__receiver,(bool)::core::convert::Into::into(is_force))
189        }
190    }
191    #[doc = "`IsTerrainFlag(crate::app::terraindata_2::TerrainData_Flags)` overload"]
192    fn is_terrain_flag(self, flags: impl ::core::convert::Into<crate::app::terraindata_2::TerrainData_Flags>) -> bool {
193        unsafe {
194            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
195            ::unity::il2cpp_call!((::unity::module_base()+0x25bb350usize)as*mut u8,bool;
196(CannonInspector)__receiver,(crate::app::terraindata_2::TerrainData_Flags)::core::convert::Into::into(flags))
197        }
198    }
199    #[doc = "`IsBowCannon()` overload"]
200    fn is_bow_cannon(self) -> bool {
201        unsafe {
202            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
203            ::unity::il2cpp_call!((::unity::module_base()+0x25bb3d0usize)as*mut u8,bool;
204(CannonInspector)__receiver)
205        }
206    }
207    #[doc = "`IsMagicCannon()` overload"]
208    fn is_magic_cannon(self) -> bool {
209        unsafe {
210            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
211            ::unity::il2cpp_call!((::unity::module_base()+0x25bb450usize)as*mut u8,bool;
212(CannonInspector)__receiver)
213        }
214    }
215    #[doc = "`IsFireCannon()` overload"]
216    fn is_fire_cannon(self) -> bool {
217        unsafe {
218            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
219            ::unity::il2cpp_call!((::unity::module_base()+0x25bb4d0usize)as*mut u8,bool;
220(CannonInspector)__receiver)
221        }
222    }
223    #[doc = "`GetTerrain()` overload"]
224    fn get_terrain(self) -> crate::app::terraindata_2::TerrainData_2 {
225        unsafe {
226            let __receiver = <CannonInspector as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
227            ::unity::il2cpp_call!((::unity::module_base()+0x25bae90usize)as*mut u8,crate::app::terraindata_2::TerrainData_2;
228(CannonInspector)__receiver)
229        }
230    }
231}
232
233#[cfg(feature = "app-cannoninspector")]
234impl<__T: ICannonInspector> ICannonInspectorMethods for __T {}
235
236#[cfg(feature = "app-cannoninspector")]
237impl CannonInspector {
238    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
239        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
240    }
241
242    pub fn is_eanble_method_info() -> &'static ::unity::il2cpp::MethodInfo {
243        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
244    }
245
246    pub fn completed_method_info() -> &'static ::unity::il2cpp::MethodInfo {
247        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
248    }
249
250    pub fn get_x_method_info() -> &'static ::unity::il2cpp::MethodInfo {
251        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
252    }
253
254    pub fn get_z_method_info() -> &'static ::unity::il2cpp::MethodInfo {
255        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
256    }
257
258    pub fn get_max_shells_method_info() -> &'static ::unity::il2cpp::MethodInfo {
259        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
260    }
261
262    pub fn set_shells_method_info() -> &'static ::unity::il2cpp::MethodInfo {
263        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
264    }
265
266    pub fn get_shells_method_info() -> &'static ::unity::il2cpp::MethodInfo {
267        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
268    }
269
270    pub fn decrease_shell_method_info() -> &'static ::unity::il2cpp::MethodInfo {
271        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
272    }
273
274    pub fn get_cannon_skill_method_info() -> &'static ::unity::il2cpp::MethodInfo {
275        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[9]
276    }
277
278    pub fn is_terrain_flag_method_info() -> &'static ::unity::il2cpp::MethodInfo {
279        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[10]
280    }
281
282    pub fn is_bow_cannon_method_info() -> &'static ::unity::il2cpp::MethodInfo {
283        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[11]
284    }
285
286    pub fn is_magic_cannon_method_info() -> &'static ::unity::il2cpp::MethodInfo {
287        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[12]
288    }
289
290    pub fn is_fire_cannon_method_info() -> &'static ::unity::il2cpp::MethodInfo {
291        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[13]
292    }
293
294    pub fn get_terrain_method_info() -> &'static ::unity::il2cpp::MethodInfo {
295        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[14]
296    }
297}
298
299#[cfg(feature = "app-cannoninspector")]
300impl CannonInspector {
301    #[doc = "Direct (non-virtual) call to `CannonInspector`'s own `IsEanble`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
302    pub unsafe fn is_eanble(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
303        let __mi = Self::is_eanble_method_info();
304        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
305        __inner(this.into(), ::core::option::Option::None)
306    }
307
308    #[doc = "Direct (non-virtual) call to `CannonInspector`'s own `Completed`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
309    pub unsafe fn completed(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
310        let __mi = Self::completed_method_info();
311        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
312        __inner(this.into(), ::core::option::Option::None)
313    }
314
315    #[doc = "Direct (non-virtual) call to `CannonInspector`'s own `get_X`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
316    pub unsafe fn get_x(this: impl ::core::convert::Into<::unity::IlInstance>) -> i32 {
317        let __mi = Self::get_x_method_info();
318        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__mi.method_ptr);
319        __inner(this.into(), ::core::option::Option::None)
320    }
321
322    #[doc = "Direct (non-virtual) call to `CannonInspector`'s own `get_Z`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
323    pub unsafe fn get_z(this: impl ::core::convert::Into<::unity::IlInstance>) -> i32 {
324        let __mi = Self::get_z_method_info();
325        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__mi.method_ptr);
326        __inner(this.into(), ::core::option::Option::None)
327    }
328}
329
330#[cfg(feature = "app-cannoninspector")]
331impl CannonInspector {
332    #[doc = "`.ctor(i32, i32, i32)` — overload selector"]
333    pub fn new(x: i32, z: i32, max_shells: i32) -> Self {
334        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
335            panic!(
336                "{}
337::{}
338 failed to instantiate",
339                ::core::stringify!(CannonInspector),
340                ::core::stringify!(new),
341            )
342        });
343        <Self as ICannonInspectorMethods>::ctor(this, x, z, max_shells);
344        this
345    }
346}
347
348#[cfg(feature = "app-cannoninspector")]
349#[doc(hidden)]
350pub mod prelude {
351    pub use super::{CannonInspector, ICannonInspector, ICannonInspectorMethods};
352    #[cfg(feature = "app-mapinspector")]
353    pub use crate::app::mapinspector::IMapInspectorMethods;
354    #[cfg(feature = "app-scriptutil")]
355    pub use crate::app::scriptutil::IScriptUtilMethods;
356    #[cfg(feature = "system-object")]
357    pub use crate::system::object::IObjectMethods;
358    pub use crate::{
359        app::{mapinspector::IMapInspector, scriptutil::IScriptUtil},
360        system::object::IObject,
361    };
362}