Skip to content

Dueel/hypixel-plugin-message

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hypixel Plugin Message API

A self-contained API for using the Hypixel plugin messages API. Uses @lilithmod/unborn-mcproto (on NPM) for packet reading and writing, but is compatible with node-minecraft-protocol and any other library that exposes plugin messages as buffers as well.

All enums from https://github.com/HypixelDev/HypixelData are converted automatically into string representations. The only current exception is ServerType, which currently returns its raw string.

See the announcement thread for more information.

Adapted based on: https://github.com/HypixelDev/ModAPI

Currently up-to-date with ModAPI release 0.2.1

Installation

npx jsr add @lilith/hypixel-plugin-message
yarn dlx jsr add @lilith/hypixel-plugin-message
pnpm dlx jsr add @lilith/hypixel-plugin-message
bunx jsr add @lilith/hypixel-plugin-message

Usage

import { readClientboundPacket, writeServerboundPacket } from '@lilith/hypixel-plugin-message'

const request: Buffer = writeServerboundPacket('ping', { version: 1})

// Send buffer as plugin message with channel hypixel:ping

const response: Buffer // Received buffer from clientbound plugin message with channel hypixel:ping

const packet = readClientboundPacket('ping', buffer) // { version: 1, response: "pong" }

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 100.0%