Sandertv / gophertunnel

General purpose library for Minecraft Bedrock Edition software written in Go
MIT License
423 stars 97 forks source link

Joining featured servers (hive, cubecraft, etc) with Gophertunnel, resource packs do not load. #122

Closed LiEnby closed 2 years ago

LiEnby commented 2 years ago

im using the default main.go

[Connection]
  LocalAddress = "0.0.0.0:19132"
  RemoteAddress = "play.cubecraft.net:19132"

and joining the server it says "loading resources" for about a second, doesn't load anything and just goes straight into the game with none of the custom models or anything working correctly

JustTalDevelops commented 2 years ago

Hi there!

The issue you describe is actually intentional, since it's how listeners and dialers work on Gophertunnel. You assign the packs you want future connections to receive in the listener, however you can still pull the packs that the server sends to the client by accessing the conn.ResoucePacks() field in a *minecraft.Conn.

You can work around this functionality by dialing before starting the listener, then setting ResourcePacks in the ListenConfig to conn.ResoucePacks().