Skip to main content

event

Attribute Macro event 

Source
#[event]
Expand description

Marks a struct as a protocol event (authoritative fact).

Derives Serialize, Deserialize, implements [Event] and [ProtocolMeta].

§Example

ⓘ
#[galeon_engine::event]
pub struct UnitDestroyed {
    pub unit_id: u64,
    pub destroyed_at: u64,
}