private static void OnGuildTrack( NetState state, PacketReader pvSrc ) { Mobile from = state.Mobile; Guild guild = from.Guild as Guild; if ( guild != null ) { bool locations = pvSrc.ReadByte() != 0; Packets.GuildTrack packet = new Packets.GuildTrack( from, guild, locations ); if ( packet.UnderlyingStream.Length > ( locations ? 9 : 5 ) ) state.Send( packet ); } else state.Send( new Packets.GuildTrack() ); }
private static void OnGuildTrack(NetState state, PacketReader pvSrc) { Mobile from = state.Mobile; if (from.Guild is Guild guild) { bool locations = pvSrc.ReadByte() != 0; Packets.GuildTrack packet = new Packets.GuildTrack(from, guild, locations); if (packet.Stream.Length > (locations ? 9 : 5)) { state.Send(packet); } } else { state.Send(new Packets.GuildTrack()); } }
private static void OnGuildTrack(NetState state, PacketReader reader) { var from = state.Mobile; if (from.Guild is Guild guild) { var locations = reader.ReadByte() != 0; var packet = new Packets.GuildTrack(from, guild, locations); if (packet.Stream.Length > (locations ? 9 : 5)) { state.Send(packet); } } else { state.Send(new Packets.GuildTrack()); } }