engage/generated/combat/
actiontransform.rs1#[cfg(feature = "combat-actiontransform-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::{
9 combat::{
10 actionbase::{ActionBase, IActionBase},
11 state::{IState, State},
12 },
13 system::{
14 object::{IObject, Object},
15 r#enum::{Enum, IEnum},
16 valuetype::{IValueType, ValueType},
17 },
18 };
19
20 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/combat/actiontransform/ActionTransform.md"))]
21 #[::unity::class(namespace = "Combat", name = "ActionTransform")]
22 #[parent(crate::combat::actionbase::ActionBase)]
23 pub struct ActionTransform {
24 #[offset(40)]
25 #[rename(name = "m_DoPlayer")]
26 pub m_do_player: bool,
27 #[offset(41)]
28 #[rename(name = "m_DoEnemy")]
29 pub m_do_enemy: bool,
30 #[offset(44)]
31 #[rename(name = "m_State")]
32 pub m_state: crate::combat::actiontransform::ActionTransform_State,
33 }
34
35 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/combat/actiontransform/ActionTransform_State.md"))]
36 #[repr(C)]
37 #[derive(::core::clone::Clone, ::core::marker::Copy, ::core::fmt::Debug, ::core::cmp::PartialEq, ::core::cmp::Eq)]
38 pub struct ActionTransform_State {
39 pub value: i32,
40 }
41 impl ::unity::ClassIdentity for ActionTransform_State {
42 const NAME: &'static str = "ActionTransform.State";
43 const NAMESPACE: &'static str = "Combat";
44
45 fn class() -> ::unity::Class {
46 static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
47 *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
48 }
49 }
50 impl ::unity::IlType for ActionTransform_State {
51 fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
52 &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
53 }
54 }
55 impl ActionTransform_State {
56 pub fn begin() -> Self {
57 Self { value: 0 }
58 }
59
60 pub fn transform() -> Self {
61 Self { value: 1 }
62 }
63
64 pub fn finish() -> Self {
65 Self { value: 2 }
66 }
67 }
68}
69
70#[cfg(feature = "combat-actiontransform-types")]
71pub use __types::*;
72
73#[cfg(feature = "combat-actiontransform")]
74pub trait IActionTransformMethods: IActionTransform {
75 #[doc = "`get_Name()` overload"]
76 fn get_name(self) -> ::unity::Il2CppString {
77 unsafe {
78 let __receiver = <ActionTransform as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
79 {
80 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
81 let __vi = *__vt.get(5usize).unwrap_or_else(|| {
82 panic!(
83 "unity: virtual slot {}
84 out of range (vtable len {}
85) on the runtime class behind {}
86 (method `{}
87`)",
88 5usize,
89 __vt.len(),
90 <ActionTransform as ::unity::ClassIdentity>::NAME,
91 "get_Name",
92 )
93 });
94 let __inner: extern "C" fn(ActionTransform, ::unity::OptionalMethod) -> ::unity::Il2CppString =
95 ::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 = "`.ctor(bool, bool)` overload"]
102 fn ctor(self, do_player: impl ::core::convert::Into<bool>, do_enemy: impl ::core::convert::Into<bool>) -> () {
103 unsafe {
104 let __receiver = <ActionTransform as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
105 ::unity::il2cpp_call!((::unity::module_base()+0x2bc9320usize)as*mut u8,();
106(ActionTransform)__receiver,(bool)::core::convert::Into::into(do_player),(bool)::core::convert::Into::into(do_enemy))
107 }
108 }
109 #[doc = "`OnUpdate()` overload"]
110 fn on_update(self) -> () {
111 unsafe {
112 let __receiver = <ActionTransform as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
113 {
114 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
115 let __vi = *__vt.get(7usize).unwrap_or_else(|| {
116 panic!(
117 "unity: virtual slot {}
118 out of range (vtable len {}
119) on the runtime class behind {}
120 (method `{}
121`)",
122 7usize,
123 __vt.len(),
124 <ActionTransform as ::unity::ClassIdentity>::NAME,
125 "OnUpdate",
126 )
127 });
128 let __inner: extern "C" fn(ActionTransform, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
129 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
130 __inner(__receiver, __mi)
131 }
132 }
133 }
134 #[doc = "`Dispose()` overload"]
135 fn dispose(self) -> () {
136 unsafe {
137 let __receiver = <ActionTransform as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
138 {
139 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
140 let __vi = *__vt.get(10usize).unwrap_or_else(|| {
141 panic!(
142 "unity: virtual slot {}
143 out of range (vtable len {}
144) on the runtime class behind {}
145 (method `{}
146`)",
147 10usize,
148 __vt.len(),
149 <ActionTransform as ::unity::ClassIdentity>::NAME,
150 "Dispose",
151 )
152 });
153 let __inner: extern "C" fn(ActionTransform, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
154 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
155 __inner(__receiver, __mi)
156 }
157 }
158 }
159 #[doc = "`Transform()` overload"]
160 fn transform(self) -> crate::system::collections::ienumerator::IEnumerator {
161 unsafe {
162 let __receiver = <ActionTransform as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
163 ::unity::il2cpp_call!((::unity::module_base()+0x2bc95d0usize)as*mut u8,crate::system::collections::ienumerator::IEnumerator;
164(ActionTransform)__receiver)
165 }
166 }
167}
168
169#[cfg(feature = "combat-actiontransform")]
170impl<__T: IActionTransform> IActionTransformMethods for __T {}
171
172#[cfg(feature = "combat-actiontransform")]
173impl ActionTransform {
174 pub fn get_name_method_info() -> &'static ::unity::il2cpp::MethodInfo {
175 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
176 }
177
178 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
179 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
180 }
181
182 pub fn on_update_method_info() -> &'static ::unity::il2cpp::MethodInfo {
183 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
184 }
185
186 pub fn dispose_method_info() -> &'static ::unity::il2cpp::MethodInfo {
187 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
188 }
189
190 pub fn transform_method_info() -> &'static ::unity::il2cpp::MethodInfo {
191 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
192 }
193}
194
195#[cfg(feature = "combat-actiontransform")]
196impl ActionTransform {
197 #[doc = "Direct (non-virtual) call to `ActionTransform`'s own `get_Name`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
198 pub unsafe fn get_name(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::Il2CppString {
199 let __mi = Self::get_name_method_info();
200 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__mi.method_ptr);
201 __inner(this.into(), ::core::option::Option::None)
202 }
203
204 #[doc = "Direct (non-virtual) call to `ActionTransform`'s own `OnUpdate`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
205 pub unsafe fn on_update(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
206 let __mi = Self::on_update_method_info();
207 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
208 __inner(this.into(), ::core::option::Option::None)
209 }
210
211 #[doc = "Direct (non-virtual) call to `ActionTransform`'s own `Dispose`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
212 pub unsafe fn dispose(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
213 let __mi = Self::dispose_method_info();
214 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
215 __inner(this.into(), ::core::option::Option::None)
216 }
217}
218
219#[cfg(feature = "combat-actiontransform")]
220impl ActionTransform {
221 #[doc = "`.ctor(bool, bool)` — overload selector"]
222 pub fn new(do_player: bool, do_enemy: bool) -> Self {
223 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
224 panic!(
225 "{}
226::{}
227 failed to instantiate",
228 ::core::stringify!(ActionTransform),
229 ::core::stringify!(new),
230 )
231 });
232 <Self as IActionTransformMethods>::ctor(this, do_player, do_enemy);
233 this
234 }
235}
236
237#[cfg(feature = "combat-actiontransform")]
238#[doc(hidden)]
239pub mod prelude {
240 pub use super::{ActionTransform, ActionTransform_State, IActionTransform, IActionTransformMethods};
241 #[cfg(feature = "combat-actionbase")]
242 pub use crate::combat::actionbase::IActionBaseMethods;
243 #[cfg(feature = "combat-state")]
244 pub use crate::combat::state::IStateMethods;
245 #[cfg(feature = "system-object")]
246 pub use crate::system::object::IObjectMethods;
247 #[cfg(feature = "system-enum")]
248 pub use crate::system::r#enum::IEnumMethods;
249 #[cfg(feature = "system-valuetype")]
250 pub use crate::system::valuetype::IValueTypeMethods;
251 pub use crate::{
252 combat::{actionbase::IActionBase, state::IState},
253 system::{object::IObject, r#enum::IEnum, valuetype::IValueType},
254 };
255}