Skip to main content

engage/generated/combat/
editorprefs_float.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "combat-editorprefs_float-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/editorprefs_float/EditorPrefs_Float.md"))]
11    #[::unity::class(namespace = "Combat", name = "EditorPrefs_Float")]
12    #[parent(crate::system::object::Object)]
13    pub struct EditorPrefs_Float {
14        #[offset(16)]
15        #[rename(name = "key")]
16        pub key: ::unity::Il2CppString,
17        #[offset(24)]
18        #[rename(name = "defaultValue")]
19        pub default_value: f32,
20    }
21}
22
23#[cfg(feature = "combat-editorprefs_float-types")]
24pub use __types::*;
25
26#[cfg(feature = "combat-editorprefs_float")]
27pub trait IEditorPrefs_FloatMethods: IEditorPrefs_Float {
28    #[doc = "`.ctor(::unity::Il2CppString, f32)` overload"]
29    fn ctor(self, name: impl ::core::convert::Into<::unity::Il2CppString>, dv: impl ::core::convert::Into<f32>) -> () {
30        unsafe {
31            let __receiver = <EditorPrefs_Float as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
32            ::unity::il2cpp_call!((::unity::module_base()+0x22d6bf0usize)as*mut u8,();
33(EditorPrefs_Float)__receiver,(::unity::Il2CppString)::core::convert::Into::into(name),(f32)::core::convert::Into::into(dv))
34        }
35    }
36    #[doc = "`get_Value()` overload"]
37    fn get_value(self) -> f32 {
38        unsafe {
39            let __receiver = <EditorPrefs_Float as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
40            ::unity::il2cpp_call!((::unity::module_base()+0x22d6c40usize)as*mut u8,f32;
41(EditorPrefs_Float)__receiver)
42        }
43    }
44    #[doc = "`set_Value(f32)` overload"]
45    fn set_value(self, value: impl ::core::convert::Into<f32>) -> () {
46        unsafe {
47            let __receiver = <EditorPrefs_Float as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
48            ::unity::il2cpp_call!((::unity::module_base()+0x22d6c50usize)as*mut u8,();
49(EditorPrefs_Float)__receiver,(f32)::core::convert::Into::into(value))
50        }
51    }
52}
53
54#[cfg(feature = "combat-editorprefs_float")]
55impl<__T: IEditorPrefs_Float> IEditorPrefs_FloatMethods for __T {}
56
57#[cfg(feature = "combat-editorprefs_float")]
58impl EditorPrefs_Float {
59    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
60        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
61    }
62
63    pub fn get_value_method_info() -> &'static ::unity::il2cpp::MethodInfo {
64        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
65    }
66
67    pub fn set_value_method_info() -> &'static ::unity::il2cpp::MethodInfo {
68        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
69    }
70}
71
72#[cfg(feature = "combat-editorprefs_float")]
73impl EditorPrefs_Float {
74    #[doc = "`.ctor(::unity::Il2CppString, f32)` — overload selector"]
75    pub fn new(name: ::unity::Il2CppString, dv: f32) -> Self {
76        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
77            panic!(
78                "{}
79::{}
80 failed to instantiate",
81                ::core::stringify!(EditorPrefs_Float),
82                ::core::stringify!(new),
83            )
84        });
85        <Self as IEditorPrefs_FloatMethods>::ctor(this, name, dv);
86        this
87    }
88}
89
90#[cfg(feature = "combat-editorprefs_float")]
91#[doc(hidden)]
92pub mod prelude {
93    pub use super::{EditorPrefs_Float, IEditorPrefs_Float, IEditorPrefs_FloatMethods};
94    pub use crate::system::object::IObject;
95    #[cfg(feature = "system-object")]
96    pub use crate::system::object::IObjectMethods;
97}