init
This commit is contained in:
14
cmd/ping/ping.go
Normal file
14
cmd/ping/ping.go
Normal file
@ -0,0 +1,14 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
bot "github.com/Tnze/gomcbot"
|
||||
"log"
|
||||
)
|
||||
|
||||
func main() {
|
||||
resp, err := bot.PingAndList("play.miaoscraft.cn", 25565)
|
||||
if err != nil {
|
||||
log.Fatalf("ping and list server fail: %v", err)
|
||||
}
|
||||
log.Println("Status:" + resp)
|
||||
}
|
Reference in New Issue
Block a user