Skip to main content

engage/generated/unity_engine/
animatorcontrollerparameter.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "unity_engine-animatorcontrollerparameter-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/unity_engine/animatorcontrollerparameter/AnimatorControllerParameter.md"))]
11    #[::unity::class(namespace = "UnityEngine", name = "AnimatorControllerParameter")]
12    #[parent(crate::system::object::Object)]
13    pub struct AnimatorControllerParameter {
14        #[offset(16)]
15        #[rename(name = "m_Name")]
16        pub m_name: ::unity::Il2CppString,
17        #[offset(24)]
18        #[rename(name = "m_Type")]
19        pub m_type: crate::unity_engine::animatorcontrollerparametertype::AnimatorControllerParameterType,
20        #[offset(28)]
21        #[rename(name = "m_DefaultFloat")]
22        pub m_default_float: f32,
23        #[offset(32)]
24        #[rename(name = "m_DefaultInt")]
25        pub m_default_int: i32,
26        #[offset(36)]
27        #[rename(name = "m_DefaultBool")]
28        pub m_default_bool: bool,
29    }
30}
31
32#[cfg(feature = "unity_engine-animatorcontrollerparameter-types")]
33pub use __types::*;
34
35#[cfg(feature = "unity_engine-animatorcontrollerparameter")]
36pub trait IAnimatorControllerParameterMethods: IAnimatorControllerParameter {
37    #[doc = "`get_name()` overload"]
38    fn get_name(self) -> ::unity::Il2CppString {
39        unsafe {
40            let __receiver =
41                <AnimatorControllerParameter as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
42            ::unity::il2cpp_call!((::unity::module_base()+0x3eb6d70usize)as*mut u8, ::unity::Il2CppString;
43(AnimatorControllerParameter)__receiver)
44        }
45    }
46    #[doc = "`Equals(crate::system::object::Object)` overload"]
47    fn equals(self, o: impl ::core::convert::Into<crate::system::object::Object>) -> bool {
48        unsafe {
49            let __receiver =
50                <AnimatorControllerParameter as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
51            {
52                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
53                let __vi = *__vt.get(0usize).unwrap_or_else(|| {
54                    panic!(
55                        "unity: virtual slot {}
56 out of range (vtable len {}
57) on the runtime class behind {}
58 (method `{}
59`)",
60                        0usize,
61                        __vt.len(),
62                        <AnimatorControllerParameter as ::unity::ClassIdentity>::NAME,
63                        "Equals",
64                    )
65                });
66                let __inner: extern "C" fn(AnimatorControllerParameter, crate::system::object::Object, ::unity::OptionalMethod) -> bool =
67                    ::core::mem::transmute(__vi.method_ptr);
68                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
69                __inner(__receiver, ::core::convert::Into::into(o), __mi)
70            }
71        }
72    }
73    #[doc = "`GetHashCode()` overload"]
74    fn get_hash_code(self) -> i32 {
75        unsafe {
76            let __receiver =
77                <AnimatorControllerParameter as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
78            {
79                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
80                let __vi = *__vt.get(2usize).unwrap_or_else(|| {
81                    panic!(
82                        "unity: virtual slot {}
83 out of range (vtable len {}
84) on the runtime class behind {}
85 (method `{}
86`)",
87                        2usize,
88                        __vt.len(),
89                        <AnimatorControllerParameter as ::unity::ClassIdentity>::NAME,
90                        "GetHashCode",
91                    )
92                });
93                let __inner: extern "C" fn(AnimatorControllerParameter, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__vi.method_ptr);
94                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
95                __inner(__receiver, __mi)
96            }
97        }
98    }
99    #[doc = "`.ctor()` overload"]
100    fn ctor(self) -> () {
101        unsafe {
102            let __receiver =
103                <AnimatorControllerParameter as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
104            ::unity::il2cpp_call!((::unity::module_base()+0x3eb6e90usize)as*mut u8,();
105(AnimatorControllerParameter)__receiver)
106        }
107    }
108}
109
110#[cfg(feature = "unity_engine-animatorcontrollerparameter")]
111impl<__T: IAnimatorControllerParameter> IAnimatorControllerParameterMethods for __T {}
112
113#[cfg(feature = "unity_engine-animatorcontrollerparameter")]
114impl AnimatorControllerParameter {
115    pub fn get_name_method_info() -> &'static ::unity::il2cpp::MethodInfo {
116        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
117    }
118
119    pub fn equals_method_info() -> &'static ::unity::il2cpp::MethodInfo {
120        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
121    }
122
123    pub fn get_hash_code_method_info() -> &'static ::unity::il2cpp::MethodInfo {
124        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
125    }
126
127    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
128        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
129    }
130}
131
132#[cfg(feature = "unity_engine-animatorcontrollerparameter")]
133impl AnimatorControllerParameter {
134    #[doc = "Direct (non-virtual) call to `AnimatorControllerParameter`'s own `Equals`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
135    pub unsafe fn equals(this: impl ::core::convert::Into<::unity::IlInstance>, o: crate::system::object::Object) -> bool {
136        let __mi = Self::equals_method_info();
137        let __inner: extern "C" fn(::unity::IlInstance, crate::system::object::Object, ::unity::OptionalMethod) -> bool =
138            ::core::mem::transmute(__mi.method_ptr);
139        __inner(this.into(), o, ::core::option::Option::None)
140    }
141
142    #[doc = "Direct (non-virtual) call to `AnimatorControllerParameter`'s own `GetHashCode`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
143    pub unsafe fn get_hash_code(this: impl ::core::convert::Into<::unity::IlInstance>) -> i32 {
144        let __mi = Self::get_hash_code_method_info();
145        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__mi.method_ptr);
146        __inner(this.into(), ::core::option::Option::None)
147    }
148}
149
150#[cfg(feature = "unity_engine-animatorcontrollerparameter")]
151impl AnimatorControllerParameter {
152    #[doc = "`.ctor()` — no args"]
153    pub fn new() -> Self {
154        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
155            panic!(
156                "{}
157::{}
158 failed to instantiate",
159                ::core::stringify!(AnimatorControllerParameter),
160                ::core::stringify!(new),
161            )
162        });
163        <Self as IAnimatorControllerParameterMethods>::ctor(this);
164        this
165    }
166}
167
168#[cfg(feature = "unity_engine-animatorcontrollerparameter")]
169#[doc(hidden)]
170pub mod prelude {
171    pub use super::{AnimatorControllerParameter, IAnimatorControllerParameter, IAnimatorControllerParameterMethods};
172    pub use crate::system::object::IObject;
173    #[cfg(feature = "system-object")]
174    pub use crate::system::object::IObjectMethods;
175}