engage/generated/tm_pro/
tmp_sprite.rs1#[cfg(feature = "tm_pro-tmp_sprite-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::{
9 system::object::{IObject, Object},
10 tm_pro::tmp_textelement_legacy::{ITMP_TextElement_Legacy, TMP_TextElement_Legacy},
11 };
12
13 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/tm_pro/tmp_sprite/TMP_Sprite.md"))]
14 #[::unity::class(namespace = "TMPro", name = "TMP_Sprite")]
15 #[parent(crate::tm_pro::tmp_textelement_legacy::TMP_TextElement_Legacy)]
16 pub struct TMP_Sprite {
17 #[offset(56)]
18 #[rename(name = "name")]
19 pub name: ::unity::Il2CppString,
20 #[offset(64)]
21 #[rename(name = "hashCode")]
22 pub hash_code: i32,
23 #[offset(68)]
24 #[rename(name = "unicode")]
25 pub unicode: i32,
26 #[offset(72)]
27 #[rename(name = "pivot")]
28 pub pivot: crate::unity_engine::vector2::Vector2,
29 #[offset(80)]
30 #[rename(name = "sprite")]
31 pub sprite: crate::unity_engine::sprite::Sprite,
32 }
33}
34
35#[cfg(feature = "tm_pro-tmp_sprite-types")]
36pub use __types::*;
37
38#[cfg(feature = "tm_pro-tmp_sprite")]
39pub trait ITMP_SpriteMethods: ITMP_Sprite {
40 #[doc = "`.ctor()` overload"]
41 fn ctor(self) -> () {
42 unsafe {
43 let __receiver = <TMP_Sprite as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
44 ::unity::il2cpp_call!((::unity::module_base()+0x282b4f0usize)as*mut u8,();
45(TMP_Sprite)__receiver)
46 }
47 }
48}
49
50#[cfg(feature = "tm_pro-tmp_sprite")]
51impl<__T: ITMP_Sprite> ITMP_SpriteMethods for __T {}
52
53#[cfg(feature = "tm_pro-tmp_sprite")]
54impl TMP_Sprite {
55 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
56 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
57 }
58}
59
60#[cfg(feature = "tm_pro-tmp_sprite")]
61impl TMP_Sprite {
62 #[doc = "`.ctor()` — no args"]
63 pub fn new() -> Self {
64 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
65 panic!(
66 "{}
67::{}
68 failed to instantiate",
69 ::core::stringify!(TMP_Sprite),
70 ::core::stringify!(new),
71 )
72 });
73 <Self as ITMP_SpriteMethods>::ctor(this);
74 this
75 }
76}
77
78#[cfg(feature = "tm_pro-tmp_sprite")]
79#[doc(hidden)]
80pub mod prelude {
81 pub use super::{ITMP_Sprite, ITMP_SpriteMethods, TMP_Sprite};
82 #[cfg(feature = "system-object")]
83 pub use crate::system::object::IObjectMethods;
84 #[cfg(feature = "tm_pro-tmp_textelement_legacy")]
85 pub use crate::tm_pro::tmp_textelement_legacy::ITMP_TextElement_LegacyMethods;
86 pub use crate::{system::object::IObject, tm_pro::tmp_textelement_legacy::ITMP_TextElement_Legacy};
87}