Struct lotus_script::message::ButtonEvent
source · pub struct ButtonEvent {
pub id: String,
pub value: bool,
pub cockpit_index: u8,
}
Expand description
Represents a button press or release event in the cockpit.
Button events capture the state changes of buttons in different cockpit positions, tracking whether they are pressed or released.
Fields§
§id: String
Unique identifier for the button event
value: bool
Current state of the button (true = pressed, false = released)
cockpit_index: u8
Index identifying the cockpit position of this button
Trait Implementations§
source§impl Debug for ButtonEvent
impl Debug for ButtonEvent
source§impl<'de> Deserialize<'de> for ButtonEvent
impl<'de> Deserialize<'de> for ButtonEvent
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl MessageType for ButtonEvent
impl MessageType for ButtonEvent
source§const MESSAGE_META: MessageMeta = _
const MESSAGE_META: MessageMeta = _
The metadata for the message type.
Auto Trait Implementations§
impl Freeze for ButtonEvent
impl RefUnwindSafe for ButtonEvent
impl Send for ButtonEvent
impl Sync for ButtonEvent
impl Unpin for ButtonEvent
impl UnwindSafe for ButtonEvent
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more