DdnetGameMsg

Enum DdnetGameMsg 

Source
pub enum DdnetGameMsg<'a> {
Show 38 variants SvMotd(SvMotd<'a>), SvBroadcast(SvBroadcast<'a>), SvChat(SvChat<'a>), SvKillMsg(SvKillMsg), SvSoundGlobal(SvSoundGlobal), SvTuneParams(SvTuneParams), Unused(Unused), SvReadyToEnter(SvReadyToEnter), SvWeaponPickup(SvWeaponPickup), SvEmoticon(SvEmoticon), SvVoteClearOptions(SvVoteClearOptions), SvVoteOptionListAdd(SvVoteOptionListAdd<'a>), SvVoteOptionAdd(SvVoteOptionAdd<'a>), SvVoteOptionRemove(SvVoteOptionRemove<'a>), SvVoteSet(SvVoteSet<'a>), SvVoteStatus(SvVoteStatus), ClSay(ClSay<'a>), ClSetTeam(ClSetTeam), ClSetSpectatorMode(ClSetSpectatorMode), ClStartInfo(ClStartInfo<'a>), ClChangeInfo(ClChangeInfo<'a>), ClKill(ClKill), ClEmoticon(ClEmoticon), ClVote(ClVote), ClCallVote(ClCallVote<'a>), ClIsDdnetLegacy(ClIsDdnetLegacy), SvDdraceTimeLegacy(SvDdraceTimeLegacy), SvRecordLegacy(SvRecordLegacy), Unused2(Unused2), SvTeamsStateLegacy(SvTeamsStateLegacy), ClShowOthersLegacy(ClShowOthersLegacy), SvMyOwnMessage(SvMyOwnMessage), ClShowDistance(ClShowDistance), ClShowOthers(ClShowOthers), SvTeamsState(SvTeamsState), SvDdraceTime(SvDdraceTime), SvRecord(SvRecord), SvKillMsgTeam(SvKillMsgTeam),
}

Variants§

§

SvMotd(SvMotd<'a>)

§

SvBroadcast(SvBroadcast<'a>)

§

SvChat(SvChat<'a>)

§

SvKillMsg(SvKillMsg)

§

SvSoundGlobal(SvSoundGlobal)

§

SvTuneParams(SvTuneParams)

§

Unused(Unused)

§

SvReadyToEnter(SvReadyToEnter)

§

SvWeaponPickup(SvWeaponPickup)

§

SvEmoticon(SvEmoticon)

§

SvVoteClearOptions(SvVoteClearOptions)

§

SvVoteOptionListAdd(SvVoteOptionListAdd<'a>)

§

SvVoteOptionAdd(SvVoteOptionAdd<'a>)

§

SvVoteOptionRemove(SvVoteOptionRemove<'a>)

§

SvVoteSet(SvVoteSet<'a>)

§

SvVoteStatus(SvVoteStatus)

§

ClSay(ClSay<'a>)

§

ClSetTeam(ClSetTeam)

§

ClSetSpectatorMode(ClSetSpectatorMode)

§

ClStartInfo(ClStartInfo<'a>)

§

ClChangeInfo(ClChangeInfo<'a>)

§

ClKill(ClKill)

§

ClEmoticon(ClEmoticon)

§

ClVote(ClVote)

§

ClCallVote(ClCallVote<'a>)

§

ClIsDdnetLegacy(ClIsDdnetLegacy)

§

SvDdraceTimeLegacy(SvDdraceTimeLegacy)

§

SvRecordLegacy(SvRecordLegacy)

§

Unused2(Unused2)

§

SvTeamsStateLegacy(SvTeamsStateLegacy)

§

ClShowOthersLegacy(ClShowOthersLegacy)

§

SvMyOwnMessage(SvMyOwnMessage)

§

ClShowDistance(ClShowDistance)

§

ClShowOthers(ClShowOthers)

§

SvTeamsState(SvTeamsState)

§

SvDdraceTime(SvDdraceTime)

§

SvRecord(SvRecord)

§

SvKillMsgTeam(SvKillMsgTeam)

Implementations§

Source§

impl<'a> Game<'a>

Source

pub fn decode<W>(warn: &mut W, p: &mut Unpacker<'a>) -> Result<Game<'a>, Error>
where W: Warn<Warning>,

Source

pub fn encode<'d, 's>( &self, p: Packer<'d, 's>, ) -> Result<&'d [u8], CapacityError>

Source§

impl<'a> Game<'a>

Source

pub fn decode_msg<W>( warn: &mut W, msg_id: MessageId, _p: &mut Unpacker<'a>, ) -> Result<Game<'a>, Error>
where W: Warn<Warning>,

Source

pub fn msg_id(&self) -> MessageId

Source

pub fn encode_msg<'d, 's>( &self, p: Packer<'d, 's>, ) -> Result<&'d [u8], CapacityError>

Trait Implementations§

Source§

impl<'a> Clone for Game<'a>

Source§

fn clone(&self) -> Game<'a>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<'a> Debug for Game<'a>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl<'a> From<ClCallVote<'a>> for Game<'a>

Source§

fn from(i: ClCallVote<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClChangeInfo<'a>> for Game<'a>

Source§

fn from(i: ClChangeInfo<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClEmoticon> for Game<'a>

Source§

fn from(i: ClEmoticon) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClIsDdnetLegacy> for Game<'a>

Source§

fn from(i: ClIsDdnetLegacy) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClKill> for Game<'a>

Source§

fn from(i: ClKill) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClSay<'a>> for Game<'a>

Source§

fn from(i: ClSay<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClSetSpectatorMode> for Game<'a>

Source§

fn from(i: ClSetSpectatorMode) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClSetTeam> for Game<'a>

Source§

fn from(i: ClSetTeam) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClShowDistance> for Game<'a>

Source§

fn from(i: ClShowDistance) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClShowOthers> for Game<'a>

Source§

fn from(i: ClShowOthers) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClShowOthersLegacy> for Game<'a>

Source§

fn from(i: ClShowOthersLegacy) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClStartInfo<'a>> for Game<'a>

Source§

fn from(i: ClStartInfo<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<ClVote> for Game<'a>

Source§

fn from(i: ClVote) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvBroadcast<'a>> for Game<'a>

Source§

fn from(i: SvBroadcast<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvChat<'a>> for Game<'a>

Source§

fn from(i: SvChat<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvDdraceTime> for Game<'a>

Source§

fn from(i: SvDdraceTime) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvDdraceTimeLegacy> for Game<'a>

Source§

fn from(i: SvDdraceTimeLegacy) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvEmoticon> for Game<'a>

Source§

fn from(i: SvEmoticon) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvKillMsg> for Game<'a>

Source§

fn from(i: SvKillMsg) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvKillMsgTeam> for Game<'a>

Source§

fn from(i: SvKillMsgTeam) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvMotd<'a>> for Game<'a>

Source§

fn from(i: SvMotd<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvMyOwnMessage> for Game<'a>

Source§

fn from(i: SvMyOwnMessage) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvReadyToEnter> for Game<'a>

Source§

fn from(i: SvReadyToEnter) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvRecord> for Game<'a>

Source§

fn from(i: SvRecord) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvRecordLegacy> for Game<'a>

Source§

fn from(i: SvRecordLegacy) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvSoundGlobal> for Game<'a>

Source§

fn from(i: SvSoundGlobal) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvTeamsState> for Game<'a>

Source§

fn from(i: SvTeamsState) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvTeamsStateLegacy> for Game<'a>

Source§

fn from(i: SvTeamsStateLegacy) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvTuneParams> for Game<'a>

Source§

fn from(i: SvTuneParams) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvVoteClearOptions> for Game<'a>

Source§

fn from(i: SvVoteClearOptions) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvVoteOptionAdd<'a>> for Game<'a>

Source§

fn from(i: SvVoteOptionAdd<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvVoteOptionListAdd<'a>> for Game<'a>

Source§

fn from(i: SvVoteOptionListAdd<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvVoteOptionRemove<'a>> for Game<'a>

Source§

fn from(i: SvVoteOptionRemove<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvVoteSet<'a>> for Game<'a>

Source§

fn from(i: SvVoteSet<'a>) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvVoteStatus> for Game<'a>

Source§

fn from(i: SvVoteStatus) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<SvWeaponPickup> for Game<'a>

Source§

fn from(i: SvWeaponPickup) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<Unused> for Game<'a>

Source§

fn from(i: Unused) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> From<Unused2> for Game<'a>

Source§

fn from(i: Unused2) -> Game<'a>

Converts to this type from the input type.
Source§

impl<'a> Message<'a> for Game<'a>

Source§

fn decode_msg<W>( warn: &mut W, id: SystemOrGame<MessageId, MessageId>, p: &mut Unpacker<'a>, ) -> Result<Game<'a>, Error>
where W: Warn<Warning>,

Source§

fn msg_id(&self) -> SystemOrGame<MessageId, MessageId>

Source§

fn encode_msg<'d, 's>( &self, p: Packer<'d, 's>, ) -> Result<&'d [u8], CapacityError>

Source§

impl<'a> Copy for Game<'a>

Auto Trait Implementations§

§

impl<'a> Freeze for Game<'a>

§

impl<'a> RefUnwindSafe for Game<'a>

§

impl<'a> Send for Game<'a>

§

impl<'a> Sync for Game<'a>

§

impl<'a> Unpin for Game<'a>

§

impl<'a> UnwindSafe for Game<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Az for T

Source§

fn az<Dst>(self) -> Dst
where T: Cast<Dst>,

Casts the value.
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<Src, Dst> CastFrom<Src> for Dst
where Src: Cast<Dst>,

Source§

fn cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<T> CheckedAs for T

Source§

fn checked_as<Dst>(self) -> Option<Dst>
where T: CheckedCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> CheckedCastFrom<Src> for Dst
where Src: CheckedCast<Dst>,

Source§

fn checked_cast_from(src: Src) -> Option<Dst>

Casts the value.
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<Src, Dst> LosslessTryInto<Dst> for Src
where Dst: LosslessTryFrom<Src>,

Source§

fn lossless_try_into(self) -> Option<Dst>

Performs the conversion.
Source§

impl<Src, Dst> LossyInto<Dst> for Src
where Dst: LossyFrom<Src>,

Source§

fn lossy_into(self) -> Dst

Performs the conversion.
Source§

impl<'a, T> MessageExt<'a> for T
where T: Message<'a>,

Source§

fn decode<W>(warn: &mut W, p: &mut Unpacker<'a>) -> Result<Self, Error>
where W: Warn<Warning>,

Source§

fn encode<'d, 's>(&self, p: Packer<'d, 's>) -> Result<&'d [u8], CapacityError>

Source§

impl<T> OverflowingAs for T

Source§

fn overflowing_as<Dst>(self) -> (Dst, bool)
where T: OverflowingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> OverflowingCastFrom<Src> for Dst
where Src: OverflowingCast<Dst>,

Source§

fn overflowing_cast_from(src: Src) -> (Dst, bool)

Casts the value.
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> SaturatingAs for T

Source§

fn saturating_as<Dst>(self) -> Dst
where T: SaturatingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> SaturatingCastFrom<Src> for Dst
where Src: SaturatingCast<Dst>,

Source§

fn saturating_cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

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

fn clone_into(&self, target: &mut T)

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

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> UnwrappedAs for T

Source§

fn unwrapped_as<Dst>(self) -> Dst
where T: UnwrappedCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> UnwrappedCastFrom<Src> for Dst
where Src: UnwrappedCast<Dst>,

Source§

fn unwrapped_cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<T> WrappingAs for T

Source§

fn wrapping_as<Dst>(self) -> Dst
where T: WrappingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> WrappingCastFrom<Src> for Dst
where Src: WrappingCast<Dst>,

Source§

fn wrapping_cast_from(src: Src) -> Dst

Casts the value.