engage/generated/root/
debugtimer.rs1#[cfg(feature = "root-debugtimer-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::{
9 system::object::{IObject, Object},
10 unity_engine::{
11 behaviour::{Behaviour, IBehaviour},
12 component::{Component, IComponent},
13 monobehaviour::{IMonoBehaviour, MonoBehaviour},
14 object_2::{IObject_2, Object_2},
15 },
16 };
17
18 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/root/debugtimer/DebugTimer.md"))]
19 #[::unity::class(namespace = "", name = "DebugTimer")]
20 #[parent(crate::unity_engine::monobehaviour::MonoBehaviour)]
21 pub struct DebugTimer {
22 #[offset(24)]
23 #[rename(name = "m_StartTime")]
24 pub m_start_time: f32,
25 #[offset(28)]
26 #[rename(name = "m_EndTime")]
27 pub m_end_time: f32,
28 }
29}
30
31#[cfg(feature = "root-debugtimer-types")]
32pub use __types::*;
33
34#[cfg(feature = "root-debugtimer")]
35pub trait IDebugTimerMethods: IDebugTimer {
36 #[doc = "`OnGUI()` overload"]
37 fn on_gui(self) -> () {
38 unsafe {
39 let __receiver = <DebugTimer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
40 ::unity::il2cpp_call!((::unity::module_base()+0x2a10490usize)as*mut u8,();
41(DebugTimer)__receiver)
42 }
43 }
44 #[doc = "`Start()` overload"]
45 fn start(self) -> () {
46 unsafe {
47 let __receiver = <DebugTimer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
48 ::unity::il2cpp_call!((::unity::module_base()+0x2a106b0usize)as*mut u8,();
49(DebugTimer)__receiver)
50 }
51 }
52 #[doc = "`Reset(f32)` overload"]
53 fn reset(self, end_time: impl ::core::convert::Into<f32>) -> () {
54 unsafe {
55 let __receiver = <DebugTimer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
56 ::unity::il2cpp_call!((::unity::module_base()+0x2a10720usize)as*mut u8,();
57(DebugTimer)__receiver,(f32)::core::convert::Into::into(end_time))
58 }
59 }
60 #[doc = "`SetMax(f32)` overload"]
61 fn set_max(self, time: impl ::core::convert::Into<f32>) -> () {
62 unsafe {
63 let __receiver = <DebugTimer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
64 ::unity::il2cpp_call!((::unity::module_base()+0x2a107a0usize)as*mut u8,();
65(DebugTimer)__receiver,(f32)::core::convert::Into::into(time))
66 }
67 }
68 #[doc = "`.ctor()` overload"]
69 fn ctor(self) -> () {
70 unsafe {
71 let __receiver = <DebugTimer as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
72 ::unity::il2cpp_call!((::unity::module_base()+0x2a107b0usize)as*mut u8,();
73(DebugTimer)__receiver)
74 }
75 }
76}
77
78#[cfg(feature = "root-debugtimer")]
79impl<__T: IDebugTimer> IDebugTimerMethods for __T {}
80
81#[cfg(feature = "root-debugtimer")]
82impl DebugTimer {
83 pub fn on_gui_method_info() -> &'static ::unity::il2cpp::MethodInfo {
84 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
85 }
86
87 pub fn start_method_info() -> &'static ::unity::il2cpp::MethodInfo {
88 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
89 }
90
91 pub fn reset_method_info() -> &'static ::unity::il2cpp::MethodInfo {
92 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
93 }
94
95 pub fn set_max_method_info() -> &'static ::unity::il2cpp::MethodInfo {
96 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
97 }
98
99 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
100 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
101 }
102}
103
104#[cfg(feature = "root-debugtimer")]
105impl DebugTimer {
106 #[doc = "`.ctor()` — no args"]
107 pub fn new() -> Self {
108 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
109 panic!(
110 "{}
111::{}
112 failed to instantiate",
113 ::core::stringify!(DebugTimer),
114 ::core::stringify!(new),
115 )
116 });
117 <Self as IDebugTimerMethods>::ctor(this);
118 this
119 }
120}
121
122#[cfg(feature = "root-debugtimer")]
123#[doc(hidden)]
124pub mod prelude {
125 pub use super::{DebugTimer, IDebugTimer, IDebugTimerMethods};
126 #[cfg(feature = "system-object")]
127 pub use crate::system::object::IObjectMethods;
128 #[cfg(feature = "unity_engine-behaviour")]
129 pub use crate::unity_engine::behaviour::IBehaviourMethods;
130 #[cfg(feature = "unity_engine-component")]
131 pub use crate::unity_engine::component::IComponentMethods;
132 #[cfg(feature = "unity_engine-monobehaviour")]
133 pub use crate::unity_engine::monobehaviour::IMonoBehaviourMethods;
134 #[cfg(feature = "unity_engine-object_2")]
135 pub use crate::unity_engine::object_2::IObject_2Methods;
136 pub use crate::{
137 system::object::IObject,
138 unity_engine::{behaviour::IBehaviour, component::IComponent, monobehaviour::IMonoBehaviour, object_2::IObject_2},
139 };
140}