Skip to content

Commit

Permalink
fix parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
jgniecki committed Apr 30, 2023
1 parent d24c6f2 commit d77f015
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/QueryBedrock.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,11 @@ protected function getStatus(): void

// TODO: What are the 2 bytes after the magic?
$data = \substr($data, 35);

$data = \explode(';', $data);
$offset = \count($data) - 13;
if ($offset < 0)
$offset = 0;

$info = [
'game_id' => $data[0] ?? null,
'hostname' => [],
Expand Down

0 comments on commit d77f015

Please sign in to comment.