engage/generated/app/
battleparam.rs1#[cfg(feature = "app-battleparam-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/battleparam/BattleParam_Kinds.md"))]
15 #[repr(C)]
16 #[derive(::core::clone::Clone, ::core::marker::Copy, ::core::fmt::Debug, ::core::cmp::PartialEq, ::core::cmp::Eq)]
17 pub struct BattleParam_Kinds {
18 pub value: i32,
19 }
20 impl ::unity::ClassIdentity for BattleParam_Kinds {
21 const NAME: &'static str = "BattleParam.Kinds";
22 const NAMESPACE: &'static str = "App";
23
24 fn class() -> ::unity::Class {
25 static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
26 *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
27 }
28 }
29 impl ::unity::IlType for BattleParam_Kinds {
30 fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
31 &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
32 }
33 }
34 impl BattleParam_Kinds {
35 pub fn value() -> Self {
36 Self { value: 0 }
37 }
38
39 pub fn ratio() -> Self {
40 Self { value: 1 }
41 }
42
43 pub fn num() -> Self {
44 Self { value: 2 }
45 }
46 }
47
48 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/app/battleparam/BattleParam.md"))]
49 #[::unity::class(namespace = "App", name = "BattleParam")]
50 #[parent(crate::system::object::Object)]
51 pub struct BattleParam {
52 #[static_field]
53 #[rename(name = "INVALID")]
54 pub invalid: f32,
55 #[static_field]
56 #[rename(name = "Mins")]
57 pub mins: ::unity::Array<f32>,
58 #[static_field]
59 #[rename(name = "Maxs")]
60 pub maxs: ::unity::Array<f32>,
61 #[static_field]
62 #[rename(name = "Clamps")]
63 pub clamps: ::unity::Array<f32>,
64 #[offset(16)]
65 #[rename(name = "Add")]
66 pub add: f32,
67 #[offset(20)]
68 #[rename(name = "Scale")]
69 pub scale: f32,
70 #[offset(24)]
71 #[rename(name = "Value")]
72 pub value: f32,
73 }
74}
75
76#[cfg(feature = "app-battleparam-types")]
77pub use __types::*;
78
79#[cfg(feature = "app-battleparam")]
80impl BattleParam {
81 #[doc = "`.cctor()` overload"]
82 pub fn cctor() -> () {
83 unsafe {
84 ::unity::il2cpp_call!((::unity::module_base()+0x1e8dd60usize)as*mut u8,();
85 )
86 }
87 }
88}
89
90#[cfg(feature = "app-battleparam")]
91pub trait IBattleParamMethods: IBattleParam {
92 #[doc = "`get_Kind()` overload"]
93 fn get_kind(self) -> crate::app::battleparam::BattleParam_Kinds {
94 unsafe {
95 let __receiver = <BattleParam as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
96 {
97 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
98 let __vi = *__vt.get(4usize).unwrap_or_else(|| {
99 panic!(
100 "unity: virtual slot {}
101 out of range (vtable len {}
102) on the runtime class behind {}
103 (method `{}
104`)",
105 4usize,
106 __vt.len(),
107 <BattleParam as ::unity::ClassIdentity>::NAME,
108 "get_Kind",
109 )
110 });
111 let __inner: extern "C" fn(BattleParam, ::unity::OptionalMethod) -> crate::app::battleparam::BattleParam_Kinds =
112 ::core::mem::transmute(__vi.method_ptr);
113 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
114 __inner(__receiver, __mi)
115 }
116 }
117 }
118 #[doc = "`get_Name()` overload"]
119 fn get_name(self) -> ::unity::Il2CppString {
120 unsafe {
121 let __receiver = <BattleParam as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
122 {
123 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
124 let __vi = *__vt.get(5usize).unwrap_or_else(|| {
125 panic!(
126 "unity: virtual slot {}
127 out of range (vtable len {}
128) on the runtime class behind {}
129 (method `{}
130`)",
131 5usize,
132 __vt.len(),
133 <BattleParam as ::unity::ClassIdentity>::NAME,
134 "get_Name",
135 )
136 });
137 let __inner: extern "C" fn(BattleParam, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__vi.method_ptr);
138 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
139 __inner(__receiver, __mi)
140 }
141 }
142 }
143 #[doc = "`GetResult(crate::app::battleinfoside::BattleInfoSide)` overload"]
144 fn get_result(self, side: impl ::core::convert::Into<crate::app::battleinfoside::BattleInfoSide>) -> f32 {
145 unsafe {
146 let __receiver = <BattleParam as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
147 ::unity::il2cpp_call!((::unity::module_base()+0x1e8da30usize)as*mut u8,f32;
148(BattleParam)__receiver,(crate::app::battleinfoside::BattleInfoSide)::core::convert::Into::into(side))
149 }
150 }
151 #[doc = "`Calculate(crate::app::battleinfoside::BattleInfoSide)` overload"]
152 fn calculate(self, side: impl ::core::convert::Into<crate::app::battleinfoside::BattleInfoSide>) -> f32 {
153 unsafe {
154 let __receiver = <BattleParam as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
155 {
156 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
157 let __vi = *__vt.get(6usize).unwrap_or_else(|| {
158 panic!(
159 "unity: virtual slot {}
160 out of range (vtable len {}
161) on the runtime class behind {}
162 (method `{}
163`)",
164 6usize,
165 __vt.len(),
166 <BattleParam as ::unity::ClassIdentity>::NAME,
167 "Calculate",
168 )
169 });
170 let __inner: extern "C" fn(BattleParam, crate::app::battleinfoside::BattleInfoSide, ::unity::OptionalMethod) -> f32 =
171 ::core::mem::transmute(__vi.method_ptr);
172 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
173 __inner(__receiver, ::core::convert::Into::into(side), __mi)
174 }
175 }
176 }
177 #[doc = "`.ctor()` overload"]
178 fn ctor(self) -> () {
179 unsafe {
180 let __receiver = <BattleParam as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
181 ::unity::il2cpp_call!((::unity::module_base()+0x1e8db70usize)as*mut u8,();
182(BattleParam)__receiver)
183 }
184 }
185 #[doc = "`.ctor(crate::app::battleparam::BattleParam)` overload"]
186 fn ctor_2(self, src: impl ::core::convert::Into<crate::app::battleparam::BattleParam>) -> () {
187 unsafe {
188 let __receiver = <BattleParam as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
189 ::unity::il2cpp_call!((::unity::module_base()+0x1e8dc10usize)as*mut u8,();
190(BattleParam)__receiver,(crate::app::battleparam::BattleParam)::core::convert::Into::into(src))
191 }
192 }
193 #[doc = "`Clear()` overload"]
194 fn clear(self) -> () {
195 unsafe {
196 let __receiver = <BattleParam as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
197 ::unity::il2cpp_call!((::unity::module_base()+0x1e8dcc0usize)as*mut u8,();
198(BattleParam)__receiver)
199 }
200 }
201 #[doc = "`Copy(crate::app::battleparam::BattleParam)` overload"]
202 fn copy(self, src: impl ::core::convert::Into<crate::app::battleparam::BattleParam>) -> () {
203 unsafe {
204 let __receiver = <BattleParam as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
205 ::unity::il2cpp_call!((::unity::module_base()+0x1e8dd40usize)as*mut u8,();
206(BattleParam)__receiver,(crate::app::battleparam::BattleParam)::core::convert::Into::into(src))
207 }
208 }
209}
210
211#[cfg(feature = "app-battleparam")]
212impl<__T: IBattleParam> IBattleParamMethods for __T {}
213
214#[cfg(feature = "app-battleparam")]
215impl BattleParam {
216 pub fn get_kind_method_info() -> &'static ::unity::il2cpp::MethodInfo {
217 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
218 }
219
220 pub fn get_name_method_info() -> &'static ::unity::il2cpp::MethodInfo {
221 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
222 }
223
224 pub fn get_result_method_info() -> &'static ::unity::il2cpp::MethodInfo {
225 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
226 }
227
228 pub fn calculate_method_info() -> &'static ::unity::il2cpp::MethodInfo {
229 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
230 }
231
232 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
233 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
234 }
235
236 pub fn ctor_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
237 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
238 }
239
240 pub fn clear_method_info() -> &'static ::unity::il2cpp::MethodInfo {
241 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
242 }
243
244 pub fn copy_method_info() -> &'static ::unity::il2cpp::MethodInfo {
245 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
246 }
247
248 pub fn cctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
249 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
250 }
251}
252
253#[cfg(feature = "app-battleparam")]
254impl BattleParam {
255 #[doc = "Direct (non-virtual) call to `BattleParam`'s own `get_Kind`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
256 pub unsafe fn get_kind(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::app::battleparam::BattleParam_Kinds {
257 let __mi = Self::get_kind_method_info();
258 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::app::battleparam::BattleParam_Kinds =
259 ::core::mem::transmute(__mi.method_ptr);
260 __inner(this.into(), ::core::option::Option::None)
261 }
262
263 #[doc = "Direct (non-virtual) call to `BattleParam`'s own `get_Name`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
264 pub unsafe fn get_name(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::Il2CppString {
265 let __mi = Self::get_name_method_info();
266 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__mi.method_ptr);
267 __inner(this.into(), ::core::option::Option::None)
268 }
269
270 #[doc = "Direct (non-virtual) call to `BattleParam`'s own `Calculate`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
271 pub unsafe fn calculate(this: impl ::core::convert::Into<::unity::IlInstance>, side: crate::app::battleinfoside::BattleInfoSide) -> f32 {
272 let __mi = Self::calculate_method_info();
273 let __inner: extern "C" fn(::unity::IlInstance, crate::app::battleinfoside::BattleInfoSide, ::unity::OptionalMethod) -> f32 =
274 ::core::mem::transmute(__mi.method_ptr);
275 __inner(this.into(), side, ::core::option::Option::None)
276 }
277}
278
279#[cfg(feature = "app-battleparam")]
280impl BattleParam {
281 #[doc = "`.ctor()` — no args"]
282 pub fn new() -> Self {
283 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
284 panic!(
285 "{}
286::{}
287 failed to instantiate",
288 ::core::stringify!(BattleParam),
289 ::core::stringify!(new),
290 )
291 });
292 <Self as IBattleParamMethods>::ctor(this);
293 this
294 }
295
296 #[doc = "`.ctor(crate::app::battleparam::BattleParam)` — overload selector"]
297 pub fn new_2(src: crate::app::battleparam::BattleParam) -> Self {
298 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
299 panic!(
300 "{}
301::{}
302 failed to instantiate",
303 ::core::stringify!(BattleParam),
304 ::core::stringify!(new_2),
305 )
306 });
307 <Self as IBattleParamMethods>::ctor_2(this, src);
308 this
309 }
310}
311
312#[cfg(feature = "app-battleparam")]
313#[doc(hidden)]
314pub mod prelude {
315 pub use super::{BattleParam, BattleParam_Kinds, IBattleParam, IBattleParamMethods};
316 #[cfg(feature = "system-object")]
317 pub use crate::system::object::IObjectMethods;
318 #[cfg(feature = "system-enum")]
319 pub use crate::system::r#enum::IEnumMethods;
320 #[cfg(feature = "system-valuetype")]
321 pub use crate::system::valuetype::IValueTypeMethods;
322 pub use crate::system::{object::IObject, r#enum::IEnum, valuetype::IValueType};
323}