Skip to main content

engage/generated/app/
language.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "app-language-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/language/Language_Voices.md"))]
15    #[repr(C)]
16    #[derive(::core::clone::Clone, ::core::marker::Copy, ::core::fmt::Debug, ::core::cmp::PartialEq, ::core::cmp::Eq)]
17    pub struct Language_Voices {
18        pub value: i32,
19    }
20    impl ::unity::ClassIdentity for Language_Voices {
21        const NAME: &'static str = "Language.Voices";
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 Language_Voices {
30        fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
31            &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
32        }
33    }
34    impl Language_Voices {
35        pub fn japanese() -> Self {
36            Self { value: 0 }
37        }
38
39        pub fn english() -> Self {
40            Self { value: 1 }
41        }
42
43        pub fn max() -> Self {
44            Self { value: 2 }
45        }
46    }
47
48    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/app/language/Language.md"))]
49    #[::unity::class(namespace = "App", name = "Language")]
50    #[parent(crate::system::object::Object)]
51    pub struct Language {
52        #[static_field]
53        #[rename(name = "s_Lang")]
54        pub s_lang: crate::app::language::Language_Langs,
55        #[static_field]
56        #[rename(name = "s_Voice")]
57        pub s_voice: crate::app::language::Language_Voices,
58        #[static_field]
59        #[rename(name = "s_LangChanged")]
60        pub s_lang_changed: crate::system::action::Action,
61        #[static_field]
62        #[rename(name = "s_CultureInfo")]
63        pub s_culture_info: ::unity::IlInstance,
64    }
65
66    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/app/language/Language_Langs.md"))]
67    #[repr(C)]
68    #[derive(::core::clone::Clone, ::core::marker::Copy, ::core::fmt::Debug, ::core::cmp::PartialEq, ::core::cmp::Eq)]
69    pub struct Language_Langs {
70        pub value: i32,
71    }
72    impl ::unity::ClassIdentity for Language_Langs {
73        const NAME: &'static str = "Language.Langs";
74        const NAMESPACE: &'static str = "App";
75
76        fn class() -> ::unity::Class {
77            static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
78            *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
79        }
80    }
81    impl ::unity::IlType for Language_Langs {
82        fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
83            &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
84        }
85    }
86    impl Language_Langs {
87        pub fn jp_japanese() -> Self {
88            Self { value: 0 }
89        }
90
91        pub fn us_english() -> Self {
92            Self { value: 1 }
93        }
94
95        pub fn us_french() -> Self {
96            Self { value: 2 }
97        }
98
99        pub fn us_spanish() -> Self {
100            Self { value: 3 }
101        }
102
103        pub fn eu_english() -> Self {
104            Self { value: 4 }
105        }
106
107        pub fn eu_french() -> Self {
108            Self { value: 5 }
109        }
110
111        pub fn eu_spanish() -> Self {
112            Self { value: 6 }
113        }
114
115        pub fn eu_german() -> Self {
116            Self { value: 7 }
117        }
118
119        pub fn eu_italian() -> Self {
120            Self { value: 8 }
121        }
122
123        pub fn cn_traditional() -> Self {
124            Self { value: 9 }
125        }
126
127        pub fn cn_simplified() -> Self {
128            Self { value: 10 }
129        }
130
131        pub fn kr_korean() -> Self {
132            Self { value: 11 }
133        }
134
135        pub fn max() -> Self {
136            Self { value: 12 }
137        }
138    }
139}
140
141#[cfg(feature = "app-language-types")]
142pub use __types::*;
143
144#[cfg(feature = "app-language")]
145impl Language {
146    #[doc = "`add_s_LangChanged(crate::system::action::Action)` overload"]
147    pub fn add_s_lang_changed(value: impl ::core::convert::Into<crate::system::action::Action>) -> () {
148        unsafe {
149            ::unity::il2cpp_call!((::unity::module_base()+0x1bdb290usize)as*mut u8,();
150(crate::system::action::Action)::core::convert::Into::into(value))
151        }
152    }
153
154    #[doc = "`remove_s_LangChanged(crate::system::action::Action)` overload"]
155    pub fn remove_s_lang_changed(value: impl ::core::convert::Into<crate::system::action::Action>) -> () {
156        unsafe {
157            ::unity::il2cpp_call!((::unity::module_base()+0x1bdb390usize)as*mut u8,();
158(crate::system::action::Action)::core::convert::Into::into(value))
159        }
160    }
161
162    #[doc = "`Initialize()` overload"]
163    pub fn initialize() -> () {
164        unsafe {
165            ::unity::il2cpp_call!((::unity::module_base()+0x1bdb490usize)as*mut u8,();
166            )
167        }
168    }
169
170    #[doc = "`SetLangAndVoiceFirst(crate::app::language::Language_Langs, crate::app::language::Language_Voices)` overload"]
171    pub fn set_lang_and_voice_first(
172        lang: impl ::core::convert::Into<crate::app::language::Language_Langs>,
173        voice: impl ::core::convert::Into<crate::app::language::Language_Voices>,
174    ) -> () {
175        unsafe {
176            ::unity::il2cpp_call!((::unity::module_base()+0x1bdbac0usize)as*mut u8,();
177(crate::app::language::Language_Langs)::core::convert::Into::into(lang),(crate::app::language::Language_Voices)::core::convert::Into::into(voice))
178        }
179    }
180
181    #[doc = "`GetLang()` overload"]
182    pub fn get_lang() -> crate::app::language::Language_Langs {
183        unsafe {
184            ::unity::il2cpp_call!((::unity::module_base()+0x1bdbc80usize)as*mut u8,crate::app::language::Language_Langs;
185            )
186        }
187    }
188
189    #[doc = "`add_LangChanged(crate::system::action::Action)` overload"]
190    pub fn add_lang_changed(value: impl ::core::convert::Into<crate::system::action::Action>) -> () {
191        unsafe {
192            ::unity::il2cpp_call!((::unity::module_base()+0x1bdbcf0usize)as*mut u8,();
193(crate::system::action::Action)::core::convert::Into::into(value))
194        }
195    }
196
197    #[doc = "`remove_LangChanged(crate::system::action::Action)` overload"]
198    pub fn remove_lang_changed(value: impl ::core::convert::Into<crate::system::action::Action>) -> () {
199        unsafe {
200            ::unity::il2cpp_call!((::unity::module_base()+0x1bdbd60usize)as*mut u8,();
201(crate::system::action::Action)::core::convert::Into::into(value))
202        }
203    }
204
205    #[doc = "`GetSortKey(crate::app::language::Language_Langs, crate::tm_pro::tmp_fontasset::TMP_FontAsset)` overload"]
206    pub fn get_sort_key(
207        lang: impl ::core::convert::Into<crate::app::language::Language_Langs>,
208        font: impl ::core::convert::Into<crate::tm_pro::tmp_fontasset::TMP_FontAsset>,
209    ) -> i32 {
210        unsafe {
211            ::unity::il2cpp_call!((::unity::module_base()+0x1bdbdd0usize)as*mut u8,i32;
212(crate::app::language::Language_Langs)::core::convert::Into::into(lang),(crate::tm_pro::tmp_fontasset::TMP_FontAsset)::core::convert::Into::into(font))
213        }
214    }
215
216    #[doc = "`SetLang(crate::app::language::Language_Langs)` overload"]
217    pub fn set_lang(lang: impl ::core::convert::Into<crate::app::language::Language_Langs>) -> () {
218        unsafe {
219            ::unity::il2cpp_call!((::unity::module_base()+0x1bdbbf0usize)as*mut u8,();
220(crate::app::language::Language_Langs)::core::convert::Into::into(lang))
221        }
222    }
223
224    #[doc = "`GetVoice()` overload"]
225    pub fn get_voice() -> crate::app::language::Language_Voices {
226        unsafe {
227            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc2b0usize)as*mut u8,crate::app::language::Language_Voices;
228            )
229        }
230    }
231
232    #[doc = "`SetVoice(crate::app::language::Language_Voices)` overload"]
233    pub fn set_voice(voice: impl ::core::convert::Into<crate::app::language::Language_Voices>) -> () {
234        unsafe {
235            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc320usize)as*mut u8,();
236(crate::app::language::Language_Voices)::core::convert::Into::into(voice))
237        }
238    }
239
240    #[doc = "`ReflectSetting()` overload"]
241    pub fn reflect_setting() -> () {
242        unsafe {
243            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc390usize)as*mut u8,();
244            )
245        }
246    }
247
248    #[doc = "`SaveSetting(crate::app::procinst::ProcInst)` overload"]
249    pub fn save_setting(parent: impl ::core::convert::Into<crate::app::procinst::ProcInst>) -> () {
250        unsafe {
251            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc580usize)as*mut u8,();
252(crate::app::procinst::ProcInst)::core::convert::Into::into(parent))
253        }
254    }
255
256    #[doc = "`GetLangName(crate::app::language::Language_Langs)` overload"]
257    pub fn get_lang_name(lang: impl ::core::convert::Into<crate::app::language::Language_Langs>) -> ::unity::Il2CppString {
258        unsafe {
259            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc5a0usize)as*mut u8, ::unity::Il2CppString;
260(crate::app::language::Language_Langs)::core::convert::Into::into(lang))
261        }
262    }
263
264    #[doc = "`GetVoiceName(crate::app::language::Language_Voices)` overload"]
265    pub fn get_voice_name(voice: impl ::core::convert::Into<crate::app::language::Language_Voices>) -> ::unity::Il2CppString {
266        unsafe {
267            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc6f0usize)as*mut u8, ::unity::Il2CppString;
268(crate::app::language::Language_Voices)::core::convert::Into::into(voice))
269        }
270    }
271
272    #[doc = "`IsTalkLayout2Lines(crate::app::language::Language_Langs)` overload"]
273    pub fn is_talk_layout2_lines(lang: impl ::core::convert::Into<crate::app::language::Language_Langs>) -> bool {
274        unsafe {
275            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc7c0usize)as*mut u8,bool;
276(crate::app::language::Language_Langs)::core::convert::Into::into(lang))
277        }
278    }
279
280    #[doc = "`GetLangDesired()` overload"]
281    pub fn get_lang_desired() -> ::unity::Il2CppString {
282        unsafe {
283            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc7d0usize)as*mut u8, ::unity::Il2CppString;
284            )
285        }
286    }
287
288    #[doc = "`.cctor()` overload"]
289    pub fn cctor() -> () {
290        unsafe {
291            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc990usize)as*mut u8,();
292            )
293        }
294    }
295}
296
297#[cfg(feature = "app-language")]
298pub trait ILanguageMethods: ILanguage {
299    #[doc = "`.ctor()` overload"]
300    fn ctor(self) -> () {
301        unsafe {
302            let __receiver = <Language as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
303            ::unity::il2cpp_call!((::unity::module_base()+0x1bdc980usize)as*mut u8,();
304(Language)__receiver)
305        }
306    }
307}
308
309#[cfg(feature = "app-language")]
310impl<__T: ILanguage> ILanguageMethods for __T {}
311
312#[cfg(feature = "app-language")]
313impl Language {
314    pub fn add_s_lang_changed_method_info() -> &'static ::unity::il2cpp::MethodInfo {
315        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
316    }
317
318    pub fn remove_s_lang_changed_method_info() -> &'static ::unity::il2cpp::MethodInfo {
319        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
320    }
321
322    pub fn initialize_method_info() -> &'static ::unity::il2cpp::MethodInfo {
323        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
324    }
325
326    pub fn set_lang_and_voice_first_method_info() -> &'static ::unity::il2cpp::MethodInfo {
327        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
328    }
329
330    pub fn get_lang_method_info() -> &'static ::unity::il2cpp::MethodInfo {
331        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
332    }
333
334    pub fn add_lang_changed_method_info() -> &'static ::unity::il2cpp::MethodInfo {
335        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
336    }
337
338    pub fn remove_lang_changed_method_info() -> &'static ::unity::il2cpp::MethodInfo {
339        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
340    }
341
342    pub fn get_sort_key_method_info() -> &'static ::unity::il2cpp::MethodInfo {
343        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
344    }
345
346    pub fn set_lang_method_info() -> &'static ::unity::il2cpp::MethodInfo {
347        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
348    }
349
350    pub fn get_voice_method_info() -> &'static ::unity::il2cpp::MethodInfo {
351        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[9]
352    }
353
354    pub fn set_voice_method_info() -> &'static ::unity::il2cpp::MethodInfo {
355        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[10]
356    }
357
358    pub fn reflect_setting_method_info() -> &'static ::unity::il2cpp::MethodInfo {
359        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[11]
360    }
361
362    pub fn save_setting_method_info() -> &'static ::unity::il2cpp::MethodInfo {
363        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[12]
364    }
365
366    pub fn get_lang_name_method_info() -> &'static ::unity::il2cpp::MethodInfo {
367        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[13]
368    }
369
370    pub fn get_voice_name_method_info() -> &'static ::unity::il2cpp::MethodInfo {
371        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[14]
372    }
373
374    pub fn is_talk_layout2_lines_method_info() -> &'static ::unity::il2cpp::MethodInfo {
375        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[15]
376    }
377
378    pub fn get_lang_desired_method_info() -> &'static ::unity::il2cpp::MethodInfo {
379        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[16]
380    }
381
382    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
383        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[19]
384    }
385
386    pub fn cctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
387        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[20]
388    }
389}
390
391#[cfg(feature = "app-language")]
392impl Language {
393    #[doc = "`.ctor()` — no args"]
394    pub fn new() -> Self {
395        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
396            panic!(
397                "{}
398::{}
399 failed to instantiate",
400                ::core::stringify!(Language),
401                ::core::stringify!(new),
402            )
403        });
404        <Self as ILanguageMethods>::ctor(this);
405        this
406    }
407}
408
409#[cfg(feature = "app-language")]
410#[doc(hidden)]
411pub mod prelude {
412    pub use super::{ILanguage, ILanguageMethods, Language, Language_Langs, Language_Voices};
413    #[cfg(feature = "system-object")]
414    pub use crate::system::object::IObjectMethods;
415    #[cfg(feature = "system-enum")]
416    pub use crate::system::r#enum::IEnumMethods;
417    #[cfg(feature = "system-valuetype")]
418    pub use crate::system::valuetype::IValueTypeMethods;
419    pub use crate::system::{object::IObject, r#enum::IEnum, valuetype::IValueType};
420}