engage/generated/root/
materialreplacer.rs1#[cfg(feature = "root-materialreplacer-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::{
9 system::{
10 object::{IObject, Object},
11 r#enum::{Enum, IEnum},
12 valuetype::{IValueType, ValueType},
13 },
14 unity_engine::{
15 behaviour::{Behaviour, IBehaviour},
16 component::{Component, IComponent},
17 monobehaviour::{IMonoBehaviour, MonoBehaviour},
18 object_2::{IObject_2, Object_2},
19 },
20 };
21
22 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/root/materialreplacer/MaterialReplacer_Mode.md"))]
23 #[repr(C)]
24 #[derive(::core::clone::Clone, ::core::marker::Copy, ::core::fmt::Debug, ::core::cmp::PartialEq, ::core::cmp::Eq)]
25 pub struct MaterialReplacer_Mode {
26 pub value: i32,
27 }
28 impl ::unity::ClassIdentity for MaterialReplacer_Mode {
29 const NAME: &'static str = "MaterialReplacer.Mode";
30 const NAMESPACE: &'static str = "";
31
32 fn class() -> ::unity::Class {
33 static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
34 *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
35 }
36 }
37 impl ::unity::IlType for MaterialReplacer_Mode {
38 fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
39 &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
40 }
41 }
42 impl MaterialReplacer_Mode {
43 pub fn bmap() -> Self {
44 Self { value: 0 }
45 }
46
47 pub fn combat() -> Self {
48 Self { value: 1 }
49 }
50 }
51
52 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/root/materialreplacer/MaterialReplacer.md"))]
53 #[::unity::class(namespace = "", name = "MaterialReplacer")]
54 #[parent(crate::unity_engine::monobehaviour::MonoBehaviour)]
55 pub struct MaterialReplacer {
56 #[offset(24)]
57 #[rename(name = "m_MaterialBmap")]
58 pub m_material_bmap: crate::unity_engine::material::Material,
59 #[offset(32)]
60 #[rename(name = "m_MaterialCombat")]
61 pub m_material_combat: crate::unity_engine::material::Material,
62 }
63}
64
65#[cfg(feature = "root-materialreplacer-types")]
66pub use __types::*;
67
68#[cfg(feature = "root-materialreplacer")]
69pub trait IMaterialReplacerMethods: IMaterialReplacer {
70 #[doc = "`Start()` overload"]
71 fn start(self) -> () {
72 unsafe {
73 let __receiver = <MaterialReplacer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
74 ::unity::il2cpp_call!((::unity::module_base()+0x25ca660usize)as*mut u8,();
75(MaterialReplacer)__receiver)
76 }
77 }
78 #[doc = "`Update()` overload"]
79 fn update(self) -> () {
80 unsafe {
81 let __receiver = <MaterialReplacer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
82 ::unity::il2cpp_call!((::unity::module_base()+0x25ca670usize)as*mut u8,();
83(MaterialReplacer)__receiver)
84 }
85 }
86 #[doc = "`UpdateMaterial(crate::root::materialreplacer::MaterialReplacer_Mode)` overload"]
87 fn update_material(self, mode: impl ::core::convert::Into<crate::root::materialreplacer::MaterialReplacer_Mode>) -> () {
88 unsafe {
89 let __receiver = <MaterialReplacer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
90 ::unity::il2cpp_call!((::unity::module_base()+0x25ca680usize)as*mut u8,();
91(MaterialReplacer)__receiver,(crate::root::materialreplacer::MaterialReplacer_Mode)::core::convert::Into::into(mode))
92 }
93 }
94 #[doc = "`.ctor()` overload"]
95 fn ctor(self) -> () {
96 unsafe {
97 let __receiver = <MaterialReplacer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
98 ::unity::il2cpp_call!((::unity::module_base()+0x25ca760usize)as*mut u8,();
99(MaterialReplacer)__receiver)
100 }
101 }
102}
103
104#[cfg(feature = "root-materialreplacer")]
105impl<__T: IMaterialReplacer> IMaterialReplacerMethods for __T {}
106
107#[cfg(feature = "root-materialreplacer")]
108impl MaterialReplacer {
109 pub fn start_method_info() -> &'static ::unity::il2cpp::MethodInfo {
110 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
111 }
112
113 pub fn update_method_info() -> &'static ::unity::il2cpp::MethodInfo {
114 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
115 }
116
117 pub fn update_material_method_info() -> &'static ::unity::il2cpp::MethodInfo {
118 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
119 }
120
121 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
122 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
123 }
124}
125
126#[cfg(feature = "root-materialreplacer")]
127impl MaterialReplacer {
128 #[doc = "`.ctor()` — no args"]
129 pub fn new() -> Self {
130 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
131 panic!(
132 "{}
133::{}
134 failed to instantiate",
135 ::core::stringify!(MaterialReplacer),
136 ::core::stringify!(new),
137 )
138 });
139 <Self as IMaterialReplacerMethods>::ctor(this);
140 this
141 }
142}
143
144#[cfg(feature = "root-materialreplacer")]
145#[doc(hidden)]
146pub mod prelude {
147 pub use super::{IMaterialReplacer, IMaterialReplacerMethods, MaterialReplacer, MaterialReplacer_Mode};
148 #[cfg(feature = "system-object")]
149 pub use crate::system::object::IObjectMethods;
150 #[cfg(feature = "system-enum")]
151 pub use crate::system::r#enum::IEnumMethods;
152 #[cfg(feature = "system-valuetype")]
153 pub use crate::system::valuetype::IValueTypeMethods;
154 #[cfg(feature = "unity_engine-behaviour")]
155 pub use crate::unity_engine::behaviour::IBehaviourMethods;
156 #[cfg(feature = "unity_engine-component")]
157 pub use crate::unity_engine::component::IComponentMethods;
158 #[cfg(feature = "unity_engine-monobehaviour")]
159 pub use crate::unity_engine::monobehaviour::IMonoBehaviourMethods;
160 #[cfg(feature = "unity_engine-object_2")]
161 pub use crate::unity_engine::object_2::IObject_2Methods;
162 pub use crate::{
163 system::{object::IObject, r#enum::IEnum, valuetype::IValueType},
164 unity_engine::{behaviour::IBehaviour, component::IComponent, monobehaviour::IMonoBehaviour, object_2::IObject_2},
165 };
166}