pianoverse/README.md

28 lines
796 B
Markdown
Raw Normal View History

# pianoverse.net protodef's and client
This contains the protocol definitions for pianoverse.net. Reversed from using protobuf_inspector on the packets sent through server and client.
2024-07-16 20:54:30 +00:00
## Requirements
1. [Bun](https://bun.sh/docs/installation)
2024-07-16 20:54:30 +00:00
## Contact
Please contact me on Discord @fucksophie. I'm in the pianoverse discord. You can also find me [elsewhere](https://sad.ovh).
## Example
The general API is styled after MPP clients, which Pianoverse has quite a lot of similarities with.
2024-07-16 20:54:30 +00:00
```ts
import { Client } from "pianoverse"
const client = new Client("https://pianoverse.net");
client.on("open", () => {
client.setRoom("Lobby")
client.setProfile("My Bot!")
})
client.on("message", (user, content) => {
if(content == "!help") {
client.message("Hi :P")
}
})
```