mirror of
https://github.com/zyllian/classics.git
synced 2025-05-10 02:16:41 -07:00
This commit is contained in:
parent
bfb9d62f96
commit
614db37e38
4 changed files with 21 additions and 4 deletions
|
@ -85,6 +85,11 @@ impl PacketWriter {
|
|||
self.write_u8(b as u8)
|
||||
}
|
||||
|
||||
/// writes a bool to the packet
|
||||
fn write_bool(self, b: bool) -> Self {
|
||||
self.write_u8(if b { 1 } else { 0 })
|
||||
}
|
||||
|
||||
/// writes a u16 to the packet
|
||||
fn write_u16(self, sh: u16) -> Self {
|
||||
let mut s = self;
|
||||
|
@ -191,6 +196,11 @@ impl ExtBitmask {
|
|||
fn info(self) -> Option<ExtInfo> {
|
||||
// TODO: add entries as extensions are supported
|
||||
Some(match self {
|
||||
// this isn't actually used by the server at all, but it technically sort of implements it
|
||||
Self::HeldBlock => ExtInfo::new("HeldBlock".to_string(), 1, Self::HeldBlock),
|
||||
Self::EmoteFix => ExtInfo::new("EmoteFix".to_string(), 1, Self::EmoteFix),
|
||||
// TODO: render CP437 properly in server output
|
||||
Self::FullCP437 => ExtInfo::new("FullCP437".to_string(), 1, Self::FullCP437),
|
||||
Self::EnvWeatherType => {
|
||||
ExtInfo::new("EnvWeatherType".to_string(), 1, Self::EnvWeatherType)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue