pub enum GGRSEvent {
    Synchronizing {
        player_handle: PlayerHandle,
        total: u32,
        count: u32,
    },
    Synchronized {
        player_handle: PlayerHandle,
    },
    Disconnected {
        player_handle: PlayerHandle,
    },
    NetworkInterrupted {
        player_handle: PlayerHandle,
        disconnect_timeout: u128,
    },
    NetworkResumed {
        player_handle: PlayerHandle,
    },
    WaitRecommendation {
        skip_frames: u32,
    },
}
Expand description

Notifications that you can receive from the session. Handling them is up to the user.

Variants

Synchronizing

Fields

player_handle: PlayerHandle
total: u32
count: u32

The session made progress in synchronizing. After total roundtrips, the session are synchronized.

Synchronized

Fields

player_handle: PlayerHandle

The session is now synchronized with the remote client.

Disconnected

Fields

player_handle: PlayerHandle

The remote client has disconnected.

NetworkInterrupted

Fields

player_handle: PlayerHandle
disconnect_timeout: u128

The session has not received packets from the remote client for some time and will disconnect the remote in disconnect_timeout ms.

NetworkResumed

Fields

player_handle: PlayerHandle

Sent only after a NetworkInterrupted event, if communication with that player has resumed.

WaitRecommendation

Fields

skip_frames: u32

Sent out if GGRS recommends skipping a few frames to let clients catch up. If you receive this, consider waiting skip_frames number of frames.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.