Fix online/max players being reversed on minecraft legacy 1.6

This commit is contained in:
CosminPerRam 2022-12-29 16:37:42 +02:00
parent b09fa4ada5
commit 8c98433da9
2 changed files with 4 additions and 3 deletions

View file

@ -4,7 +4,8 @@ Who knows what the future holds...
# 0.0.7 - ??/??/2022
### Changes:
[Minecraft](https://www.minecraft.com) bedrock edition support.
Also added a `query_legacy_specific` method to the mc game queries.
Fix Minecraft legacy v1.6 max/online players count being reversed.
Added `query_legacy_specific` method to the Minecraft protocol.
### Breaking:
Removed `query_specific` from the mc protocol in favor of `query_java`, `query_legacy` and `query_legacy_specific`.

View file

@ -55,9 +55,9 @@ impl LegacyV1_6 {
.map_err(|_| GDError::PacketBad("Failed to parse to expected int.".to_string()))?;
let version_name = split[1].to_string();
let description = split[2].to_string();
let max_players = split[3].parse()
let online_players = split[3].parse()
.map_err(|_| GDError::PacketBad("Failed to parse to expected int.".to_string()))?;
let online_players = split[4].parse()
let max_players = split[4].parse()
.map_err(|_| GDError::PacketBad("Failed to parse to expected int.".to_string()))?;
Ok(Response {