engage/generated/combat/
fsm.rs1#[cfg(feature = "combat-fsm-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::system::object::{IObject, Object};
9
10 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/combat/fsm/FSM.md"))]
11 #[::unity::class(namespace = "Combat", name = "FSM")]
12 #[parent(crate::system::object::Object)]
13 pub struct FSM {
14 #[offset(16)]
15 #[rename(name = "StateList")]
16 pub state_list: crate::system::collections::generic::linkedlist_1::LinkedList_1<crate::combat::state::State>,
17 }
18}
19
20#[cfg(feature = "combat-fsm-types")]
21pub use __types::*;
22
23#[cfg(feature = "combat-fsm")]
24pub trait IFSMMethods: IFSM {
25 #[doc = "`get_CurrentState()` overload"]
26 fn get_current_state(self) -> crate::combat::state::State {
27 unsafe {
28 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
29 ::unity::il2cpp_call!((::unity::module_base()+0x2d46400usize)as*mut u8,crate::combat::state::State;
30(FSM)__receiver)
31 }
32 }
33 #[doc = "`.ctor()` overload"]
34 fn ctor(self) -> () {
35 unsafe {
36 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
37 ::unity::il2cpp_call!((::unity::module_base()+0x2d46470usize)as*mut u8,();
38(FSM)__receiver)
39 }
40 }
41 #[doc = "`Finalize()` overload"]
42 fn finalize(self) -> () {
43 unsafe {
44 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
45 {
46 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
47 let __vi = *__vt.get(1usize).unwrap_or_else(|| {
48 panic!(
49 "unity: virtual slot {}
50 out of range (vtable len {}
51) on the runtime class behind {}
52 (method `{}
53`)",
54 1usize,
55 __vt.len(),
56 <FSM as ::unity::ClassIdentity>::NAME,
57 "Finalize",
58 )
59 });
60 let __inner: extern "C" fn(FSM, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
61 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
62 __inner(__receiver, __mi)
63 }
64 }
65 }
66 #[doc = "`Dispose()` overload"]
67 fn dispose(self) -> () {
68 unsafe {
69 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
70 {
71 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
72 let __vi = *__vt.get(4usize).unwrap_or_else(|| {
73 panic!(
74 "unity: virtual slot {}
75 out of range (vtable len {}
76) on the runtime class behind {}
77 (method `{}
78`)",
79 4usize,
80 __vt.len(),
81 <FSM as ::unity::ClassIdentity>::NAME,
82 "Dispose",
83 )
84 });
85 let __inner: extern "C" fn(FSM, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
86 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
87 __inner(__receiver, __mi)
88 }
89 }
90 }
91 #[doc = "`Update()` overload"]
92 fn update(self) -> () {
93 unsafe {
94 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
95 ::unity::il2cpp_call!((::unity::module_base()+0x2d466b0usize)as*mut u8,();
96(FSM)__receiver)
97 }
98 }
99 #[doc = "`LateUpdate()` overload"]
100 fn late_update(self) -> () {
101 unsafe {
102 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
103 ::unity::il2cpp_call!((::unity::module_base()+0x2d469b0usize)as*mut u8,();
104(FSM)__receiver)
105 }
106 }
107 #[doc = "`UpdateCore(crate::system::action_1::Action_1<crate::combat::state::State>)` overload"]
108 fn update_core(self, update_func: impl ::core::convert::Into<crate::system::action_1::Action_1<crate::combat::state::State>>) -> () {
109 unsafe {
110 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
111 ::unity::il2cpp_call!((::unity::module_base()+0x2d467d0usize)as*mut u8,();
112(FSM)__receiver,(crate::system::action_1::Action_1<crate::combat::state::State>)::core::convert::Into::into(update_func))
113 }
114 }
115 #[doc = "`Add(crate::combat::state::State)` overload"]
116 fn add(self, state: impl ::core::convert::Into<crate::combat::state::State>) -> () {
117 unsafe {
118 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
119 ::unity::il2cpp_call!((::unity::module_base()+0x2d46ad0usize)as*mut u8,();
120(FSM)__receiver,(crate::combat::state::State)::core::convert::Into::into(state))
121 }
122 }
123 #[doc = "`AddFirst(crate::combat::state::State)` overload"]
124 fn add_first(self, state: impl ::core::convert::Into<crate::combat::state::State>) -> () {
125 unsafe {
126 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
127 ::unity::il2cpp_call!((::unity::module_base()+0x2d46b30usize)as*mut u8,();
128(FSM)__receiver,(crate::combat::state::State)::core::convert::Into::into(state))
129 }
130 }
131 #[doc = "`Clear()` overload"]
132 fn clear(self) -> () {
133 unsafe {
134 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
135 ::unity::il2cpp_call!((::unity::module_base()+0x2d46c30usize)as*mut u8,();
136(FSM)__receiver)
137 }
138 }
139 #[doc = "`get_DebuggerDisplay()` overload"]
140 fn get_debugger_display(self) -> ::unity::Il2CppString {
141 unsafe {
142 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
143 ::unity::il2cpp_call!((::unity::module_base()+0x2d46cf0usize)as*mut u8, ::unity::Il2CppString;
144(FSM)__receiver)
145 }
146 }
147 #[doc = "`ToString()` overload"]
148 fn to_string(self) -> ::unity::Il2CppString {
149 unsafe {
150 let __receiver = <FSM as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
151 {
152 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
153 let __vi = *__vt.get(3usize).unwrap_or_else(|| {
154 panic!(
155 "unity: virtual slot {}
156 out of range (vtable len {}
157) on the runtime class behind {}
158 (method `{}
159`)",
160 3usize,
161 __vt.len(),
162 <FSM as ::unity::ClassIdentity>::NAME,
163 "ToString",
164 )
165 });
166 let __inner: extern "C" fn(FSM, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__vi.method_ptr);
167 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
168 __inner(__receiver, __mi)
169 }
170 }
171 }
172}
173
174#[cfg(feature = "combat-fsm")]
175impl<__T: IFSM> IFSMMethods for __T {}
176
177#[cfg(feature = "combat-fsm")]
178impl FSM {
179 pub fn get_current_state_method_info() -> &'static ::unity::il2cpp::MethodInfo {
180 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
181 }
182
183 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
184 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
185 }
186
187 pub fn finalize_method_info() -> &'static ::unity::il2cpp::MethodInfo {
188 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
189 }
190
191 pub fn dispose_method_info() -> &'static ::unity::il2cpp::MethodInfo {
192 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
193 }
194
195 pub fn update_method_info() -> &'static ::unity::il2cpp::MethodInfo {
196 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
197 }
198
199 pub fn late_update_method_info() -> &'static ::unity::il2cpp::MethodInfo {
200 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
201 }
202
203 pub fn update_core_method_info() -> &'static ::unity::il2cpp::MethodInfo {
204 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
205 }
206
207 pub fn add_method_info() -> &'static ::unity::il2cpp::MethodInfo {
208 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
209 }
210
211 pub fn add_first_method_info() -> &'static ::unity::il2cpp::MethodInfo {
212 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
213 }
214
215 pub fn clear_method_info() -> &'static ::unity::il2cpp::MethodInfo {
216 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[9]
217 }
218
219 pub fn get_debugger_display_method_info() -> &'static ::unity::il2cpp::MethodInfo {
220 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[10]
221 }
222
223 pub fn to_string_method_info() -> &'static ::unity::il2cpp::MethodInfo {
224 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[11]
225 }
226}
227
228#[cfg(feature = "combat-fsm")]
229impl FSM {
230 #[doc = "Direct (non-virtual) call to `FSM`'s own `Finalize`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
231 pub unsafe fn finalize(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
232 let __mi = Self::finalize_method_info();
233 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
234 __inner(this.into(), ::core::option::Option::None)
235 }
236
237 #[doc = "Direct (non-virtual) call to `FSM`'s own `Dispose`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
238 pub unsafe fn dispose(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
239 let __mi = Self::dispose_method_info();
240 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
241 __inner(this.into(), ::core::option::Option::None)
242 }
243
244 #[doc = "Direct (non-virtual) call to `FSM`'s own `ToString`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
245 pub unsafe fn to_string(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::Il2CppString {
246 let __mi = Self::to_string_method_info();
247 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__mi.method_ptr);
248 __inner(this.into(), ::core::option::Option::None)
249 }
250}
251
252#[cfg(feature = "combat-fsm")]
253impl FSM {
254 #[doc = "`.ctor()` — no args"]
255 pub fn new() -> Self {
256 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
257 panic!(
258 "{}
259::{}
260 failed to instantiate",
261 ::core::stringify!(FSM),
262 ::core::stringify!(new),
263 )
264 });
265 <Self as IFSMMethods>::ctor(this);
266 this
267 }
268}
269
270#[cfg(feature = "combat-fsm")]
271#[doc(hidden)]
272pub mod prelude {
273 pub use super::{IFSMMethods, FSM, IFSM};
274 pub use crate::system::object::IObject;
275 #[cfg(feature = "system-object")]
276 pub use crate::system::object::IObjectMethods;
277}