Closed qwqtoday closed 4 months ago
Do you see data/packetid/generator/Main.java
?
It's a java program.
Basically, you should decompile the vanilla client or server (by using the MCP-Reborn project). Once you do so, you got a Gradle project opened in your IntelliJ IDEA IDE.
Now you copy the Main.java
into the Maven project. The project view looks like this:
Open the Main.java
in your IDE. Click the green triangle on the left of the main function (or the Main class). Your IDEA will run the program. If there is any compile error, fix the error.
The program dumps the Packet names into stdout and you should copy them into data/packetid/packetid.go
.
FInally, you should run go generate
to generate data/packetid/serverboundpacketid_string.go
and data/packetid/clientboundpacketid_string.go
.
If you didn't install the stringer
command, install it with go install golang.org/x/tools/cmd/stringer
.
Thanks, will try once I am back home
Also another question, do you mind if I include a ping handler in bot/basic in that pr? It is like keep alive but it responds to ping It sounds pretty basic to me so I implemented that in bot/basic instead of my bot
I don't care as long as you do it right.
I had done it. This is my pull request #277 Hopefully I did everything correct.
I am so close on updating go-mc to 1.20.4, I just need some help on the packet id thing, what is the correct way to update that?