Skip to content

Commit

Permalink
Change references for transfer
Browse files Browse the repository at this point in the history
  • Loading branch information
dreamscached committed Oct 6, 2022
1 parent edebacf commit a9a07db
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 16 deletions.
6 changes: 3 additions & 3 deletions MIGRATING.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ will help you migrate your existing codebase to v2.
MineQuery v2 has its package named `minequery/v2` instead of `ping`. Import path has
also changed:

| v1 import | v2 import |
|----------------------------------------------|--------------------------------------------|
| `import "github.com/alteamc/minequery/ping"` | `import "github.com/alteamc/minequery/v2"` |
| v1 import | v2 import |
|---------------------------------------------------|-------------------------------------------------|
| `import "github.com/dreamscached/minequery/ping"` | `import "github.com/dreamscached/minequery/v2"` |

### New ping function signatures

Expand Down
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
<h1 align="center">📡 MineQuery</h1>
<h4 align="center">Minecraft Server List Ping library written in Go</h4>
<p align="center">
<a href="https://github.com/alteamc/minequery/blob/v2/go.mod">
<img alt="Go version badge" src="https://img.shields.io/github/go-mod/go-version/alteamc/minequery">
<a href="https://github.com/dreamscached/minequery/blob/v2/go.mod">
<img alt="Go version badge" src="https://img.shields.io/github/go-mod/go-version/dreamscached/minequery">
</a>
<a href="https://github.com/alteamc/minequery/releases/latest">
<img alt="Latest release badge" src="https://img.shields.io/github/v/release/alteamc/minequery">
<a href="https://github.com/dreamscached/minequery/releases/latest">
<img alt="Latest release badge" src="https://img.shields.io/github/v/release/dreamscached/minequery">
</a>
<a href="https://pkg.go.dev/github.com/alteamc/minequery/v2">
<img alt="Go reference badge" src="https://pkg.go.dev/badge/github.com/alteamc/minequery.svg">
<a href="https://pkg.go.dev/github.com/dreamscached/minequery/v2">
<img alt="Go reference badge" src="https://pkg.go.dev/badge/github.com/dreamscached/minequery.svg">
</a>
<a href="https://github.com/alteamc/minequery/blob/v2/LICENSE">
<img alt="License badge" src="https://img.shields.io/github/license/alteamc/minequery">
<a href="https://github.com/dreamscached/minequery/blob/v2/LICENSE">
<img alt="License badge" src="https://img.shields.io/github/license/dreamscached/minequery">
</a>
<br/>
<a href="https://github.com/alteamc/minequery#readme">
<a href="https://github.com/dreamscached/minequery#readme">
<img alt="Minecraft version support badge" src="https://img.shields.io/badge/minecraft%20version-Beta%201.8%20to%201.3%20%7C%201.4%20to%201.5%20%7C%201.6%20%7C%201.7%2B-brightgreen">
</a>
<a href="https://discord.gg/9ruheUG3Wg">
Expand Down Expand Up @@ -140,7 +140,7 @@ a convenient set of constants you can use &mdash; see `Ping17ProtocolVersion*` c
[3]: https://wiki.vg/Server_List_Ping#1.4_to_1.5
[4]: https://wiki.vg/Server_List_Ping#1.6
[5]: https://wiki.vg/Server_List_Ping#Current
[6]: https://github.com/alteamc/minequery/issues/25
[7]: https://pkg.go.dev/github.com/alteamc/minequery/v2
[6]: https://github.com/dreamscached/minequery/issues/25
[7]: https://pkg.go.dev/github.com/dreamscached/minequery/v2
[8]: #basic-usage
[9]: https://wiki.vg/Query
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/alteamc/minequery/v2
module github.com/dreamscached/minequery/v2

go 1.13

Expand Down
3 changes: 2 additions & 1 deletion ping_14.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ type Status14 struct {

// Ping14 pings 1.4 to 1.6 (exclusively) Minecraft servers (Notchian servers of more late versions also respond to
// this ping packet.)
//
//goland:noinspection GoUnusedExportedFunction
func Ping14(host string, port int) (*Status14, error) {
return defaultPinger.Ping14(host, port)
Expand Down Expand Up @@ -69,7 +70,7 @@ func (p *Pinger) ping14WritePingPacket(writer io.Writer) error {

func (p *Pinger) ping14ParseResponsePayload(payload []byte) (*Status14, error) {
// NOTE: Spigot 1.4 servers reply with 1.6 response format.
// See https://github.com/alteamc/minequery/issues/31 for details.
// See https://github.com/dreamscached/minequery/issues/31 for details.
// Check if data string begins with '§1\x00' (00 a7 00 31 00 00) and pass processing to 1.6 logic in this case.
if bytes.HasPrefix(payload, ping16ResponsePrefix) {
if p.UseStrict {
Expand Down

0 comments on commit a9a07db

Please sign in to comment.